From b6517b9ce9b2d04f0152fa8884f8b23b75a29364 Mon Sep 17 00:00:00 2001 From: Nicolas KAROLAK <nicolas@karolak.fr> Date: Wed, 11 Apr 2018 16:13:00 +0200 Subject: [PATCH] test_ssl: fix ssl context protocol --- tests/test_ssl.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/test_ssl.py b/tests/test_ssl.py index 4da15ddb..9d46bd6e 100755 --- a/tests/test_ssl.py +++ b/tests/test_ssl.py @@ -50,7 +50,7 @@ for s, d in conf_servers: try: # further tests conn = ssl.create_connection((v, 443)) - context = ssl.SSLContext() + context = ssl.SSLContext(ssl.PROTOCOL_TLS) sock = context.wrap_socket(conn, server_hostname=v) cert = ssl.DER_cert_to_PEM_cert(sock.getpeercert(True)) x509 = OpenSSL.crypto.load_certificate(OpenSSL.crypto.FILETYPE_PEM, cert) -- GitLab