On this page
ssl.DefaultVerifyPaths
Prev: ssl.create_default_context | Up: ssl | Next: ssl.DER_cert_to_PEM_cert
Rel: ssl.AlertDescription, ssl.cert_time_to_seconds, ssl.CertificateError, ssl.create_connection
Ref: docs.python.org โ ssl.DefaultVerifyPaths
Tags: #public #python3 #stdlib #ssl
Import
import ssl
from ssl import DefaultVerifyPaths
Signature & Overview
ssl.DefaultVerifyPaths(cafile, capath, openssl_cafile_env, openssl_cafile, openssl_capath_env, openssl_capath)
DefaultVerifyPaths(cafile, capath, openssl_cafile_env, openssl_cafile, openssl_capath_env, openssl_capath)
Methods & Attributes
DefaultVerifyPaths.count(self, value, /)โ Return number of occurrences of value.DefaultVerifyPaths.index(self, value, start=0, stop=9223372036854775807, /)โ Return first index of value.
Usage
import ssl
paths = ssl.get_default_verify_paths()
assert isinstance(paths, ssl.DefaultVerifyPaths)
assert hasattr(paths, "cafile") and hasattr(paths, "capath")
Gotchas
- Diagnostic named tuple: Check
paths.openssl_cafile_env(SSL_CERT_FILE) when debugging corporate proxy or macOS certificate-store issues.
REPL Inspect
from ssl import DefaultVerifyPaths
help(DefaultVerifyPaths)
Linked from
Related notes
- tuts/python3/stdlib_module/ssl/create_default_context Linked here; links to this page; shared tags: #ssl, #stdlib
- tuts/python3/stdlib_module/ssl/DER_cert_to_PEM_cert Linked here; links to this page; shared tags: #ssl, #stdlib
- tuts/python3/stdlib_module/ssl Linked here; links to this page; shared tags: #stdlib
- tuts/python3/stdlib_module/ssl/AlertDescription Linked here; shared tags: #ssl, #stdlib
- tuts/python3/stdlib_module/ssl/cert_time_to_seconds Linked here; shared tags: #ssl, #stdlib
- tuts/python3/stdlib_module/ssl/CertificateError Linked here; shared tags: #ssl, #stdlib
- tuts/python3/stdlib_module/ssl/create_connection Linked here; shared tags: #ssl, #stdlib
- tuts/python3/stdlib_module/ssl/get_default_verify_paths shared tags: #ssl, #stdlib
- tuts/python3/stdlib_module/ssl/get_protocol_name shared tags: #ssl, #stdlib
- tuts/python3/stdlib_module/ssl/get_server_certificate shared tags: #ssl, #stdlib