| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
1 parent 5819cfa commit 9d01717
2 files changed
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -922,7 +922,7 @@ def PEM_cert_to_DER_cert(pem_cert_string): | |||
| 922 | 922 | d = pem_cert_string.strip()[len(PEM_HEADER):-len(PEM_FOOTER)] | |
| 923 | 923 | return base64.decodebytes(d.encode('ASCII', 'strict')) | |
| 924 | 924 | ||
| 925 | - def get_server_certificate(addr, ssl_version=PROTOCOL_SSLv3, ca_certs=None): | ||
| 925 | + def get_server_certificate(addr, ssl_version=PROTOCOL_SSLv23, ca_certs=None): | ||
| 926 | 926 | """Retrieve the certificate from the server at the specified address, | |
| 927 | 927 | and return it as a PEM-encoded string. | |
| 928 | 928 | If 'ca_certs' is specified, validate the server cert against it. | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -44,6 +44,11 @@ Core and Builtins | |||
| 44 | 44 | Library | |
| 45 | 45 | ------- | |
| 46 | 46 | ||
| 47 | + - Issue #20896, #22935: The :func:`ssl.get_server_certificate` function now | ||
| 48 | + uses the :data:`~ssl.PROTOCOL_SSLv23` protocol by default, not | ||
| 49 | + :data:`~ssl.PROTOCOL_SSLv3`, for maximum compatibility and support platforms | ||
| 50 | + where :data:`~ssl.PROTOCOL_SSLv3` support is disabled. | ||
| 51 | + | ||
| 47 | 52 | - Issue #23111: In the ftplib, make ssl.PROTOCOL_SSLv23 the default protocol | |
| 48 | 53 | version. | |
| 49 | 54 | ||
| Back | FazBrowse Home | New Git URL |
0 commit comments