-
-
Notifications
You must be signed in to change notification settings - Fork 33.7k
bpo-36037: Fix test_ssl for strict OpenSSL policy #11940
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
|
cc @stratakis |
|
Tested it on a RHEL8 system and I confirm this PR actually fixes the tests. |
Fix test_ssl for strict OpenSSL configuration like RHEL8 strict crypto policy. Use older TLS version for minimum TLS version of the server SSL context if needed, to test TLS version older than default minimum TLS version.
|
I used git push --force to elaborate the commit message and NEWS entry: mention that the fix changes the minimum version. |
|
Hmm, I'll let @tiran comment on this. I really haven't kept up with the ssl testing infrastructure, nor with the ssl module itself. |
|
Oh macOS on Azure faild with: pythoninfo: Ah, that's pre-OpenSSL 1.1.1. I fixed my PR. |
|
I tested manually the PR on Debian Buster:
|
|
Thanks @vstinner for the PR 🌮🎉.. I'm working now to backport this PR to: 3.7. |
|
GH-11942 is a backport of this pull request to the 3.7 branch. |
Fix test_ssl for strict OpenSSL configuration like RHEL8 strict crypto policy. Use older TLS version for minimum TLS version of the server SSL context if needed, to test TLS version older than default minimum TLS version. (cherry picked from commit 3ef6344) Co-authored-by: Victor Stinner <[email protected]>
Fix test_ssl for strict OpenSSL configuration like RHEL8 strict crypto policy. Use older TLS version for minimum TLS version of the server SSL context if needed, to test TLS version older than default minimum TLS version. (cherry picked from commit 3ef6344) Co-authored-by: Victor Stinner <[email protected]>
| if (min_version is not None | ||
| # SSLContext.minimum_version is only available on recent OpenSSL | ||
| # (setter added in OpenSSL 1.1.0, getter added in OpenSSL 1.1.1) | ||
| and hasattr(server_context, 'minimum_version') |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
style nit (not worth another PR, just leave it), I'd have indented these lines to match the column of min_version after your opening ( above.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
He he, I expected that someone would complain about that 😁 Feel free to change it if you want.
Fix test_ssl for strict OpenSSL configuration like RHEL8 strict
crypto policy.
https://bugs.python.org/issue36037