We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 42d34a1 commit 4040091Copy full SHA for 4040091
tests/test_tcp.py
@@ -1621,11 +1621,10 @@ def test_ssl_connect_accepted_socket(self):
1621
if hasattr(ssl, 'PROTOCOL_TLS_SERVER'):
1622
server_proto = ssl.PROTOCOL_TLS_SERVER
1623
client_proto = ssl.PROTOCOL_TLS_CLIENT
1624
+ elif hasattr(ssl, 'PROTOCOL_TLS'):
1625
+ client_proto = server_proto = ssl.PROTOCOL_TLS
1626
else:
- if hasattr(ssl, 'PROTOCOL_TLS'):
- client_proto = server_proto = ssl.PROTOCOL_TLS
1627
- else:
1628
- client_proto = server_proto = ssl.PROTOCOL_SSLv23
+ client_proto = server_proto = ssl.PROTOCOL_SSLv23
1629
1630
server_context = ssl.SSLContext(server_proto)
1631
server_context.load_cert_chain(self.ONLYCERT, self.ONLYKEY)
0 commit comments