lib-python/2.7/test/test_ssl.py::unmodified
test_ssl: testing with 'OpenSSL 3.0.21 9 Jun 2026' (3, 0, 0, 21, 0)
under Linux ('AlmaLinux', '8.10', 'Cerulean Leopard')
HAS_SNI = True
OP_ALL = 0x80000050
OP_NO_TLSv1_1 = 0x10000000
test__create_stdlib_context (test.test_ssl.ContextTests) ... ok
test__https_verify_certificates (test.test_ssl.ContextTests) ... ok
test__https_verify_envvar (test.test_ssl.ContextTests) ... ok
test_cert_store_stats (test.test_ssl.ContextTests) ... ok
test_check_hostname (test.test_ssl.ContextTests) ... ok
test_ciphers (test.test_ssl.ContextTests) ... ok
test_constructor (test.test_ssl.ContextTests) ... ok
test_create_default_context (test.test_ssl.ContextTests) ... ok
test_get_ca_certs (test.test_ssl.ContextTests) ... ok
test_load_cert_chain (test.test_ssl.ContextTests) ... ok
test_load_default_certs (test.test_ssl.ContextTests) ... ok
test_load_default_certs_env (test.test_ssl.ContextTests) ... ok
test_load_default_certs_env_windows (test.test_ssl.ContextTests) ... skipped 'Windows specific'
test_load_dh_params (test.test_ssl.ContextTests) ... ok
test_load_verify_cadata (test.test_ssl.ContextTests) ... ERROR
test_load_verify_locations (test.test_ssl.ContextTests) ... ok
test_protocol (test.test_ssl.ContextTests) ... ok
test_session_stats (test.test_ssl.ContextTests) ... ok
test_set_default_verify_paths (test.test_ssl.ContextTests) ... ok
test_set_ecdh_curve (test.test_ssl.ContextTests) ... ok
test_sni_callback (test.test_ssl.ContextTests) ... ok
test_sni_callback_refcycle (test.test_ssl.ContextTests) ... ok
test_verify_flags (test.test_ssl.ContextTests) ... ok
test_verify_mode (test.test_ssl.ContextTests) ... ok
test_sslwrap_simple (test.test_ssl.BasicTests) ... ok
test_DER_to_PEM (test.test_ssl.BasicSocketTests) ... ok
test_asn1object (test.test_ssl.BasicSocketTests) ... ok
test_cert_time_to_seconds (test.test_ssl.BasicSocketTests) ... ok
test_cert_time_to_seconds_locale (test.test_ssl.BasicSocketTests) ... skipped 'locale-specific month name needs to be different from C locale'
test_cert_time_to_seconds_timezone (test.test_ssl.BasicSocketTests) ... skipped 'local time needs to be different from UTC'
test_constants (test.test_ssl.BasicSocketTests) ... ok
test_empty_cert (test.test_ssl.BasicSocketTests)
Wrapping with an empty cert file ... ok
test_enum_certificates (test.test_ssl.BasicSocketTests) ... skipped 'Windows specific'
test_enum_crls (test.test_ssl.BasicSocketTests) ... skipped 'Windows specific'
test_errors (test.test_ssl.BasicSocketTests) ... ok
test_get_default_verify_paths (test.test_ssl.BasicSocketTests) ... ok
test_malformed_cert (test.test_ssl.BasicSocketTests)
Wrapping with a badly formatted certificate (syntax error) ... ok
test_malformed_key (test.test_ssl.BasicSocketTests)
Wrapping with a badly formatted key (syntax error) ... ok
test_match_hostname (test.test_ssl.BasicSocketTests) ... ok
test_openssl_version (test.test_ssl.BasicSocketTests) ... ok
test_parse_all_sans (test.test_ssl.BasicSocketTests) ... ok
test_parse_cert (test.test_ssl.BasicSocketTests) ...
{'issuer': ((('countryName', 'XY'),),
(('localityName', 'Castle Anthrax'),),
(('organizationName', 'Python Software Foundation'),),
(('commonName', 'localhost'),)),
'notAfter': 'Aug 26 14:23:15 2028 GMT',
'notBefore': 'Aug 29 14:23:15 2018 GMT',
'serialNumber': '98A7CF88C74A32ED',
'subject': ((('countryName', 'XY'),),
(('localityName', 'Castle Anthrax'),),
(('organizationName', 'Python Software Foundation'),),
(('commonName', 'localhost'),)),
'subjectAltName': (('DNS', 'localhost'),),
'version': 3}
{'OCSP': ('http://ocsp.verisign.com',),
'caIssuers': ('http://SVRIntl-G3-aia.verisign.com/SVRIntlG3.cer',),
'crlDistributionPoints': ('http://SVRIntl-G3-crl.verisign.com/SVRIntlG3.crl',),
'issuer': ((('countryName', 'US'),),
(('organizationName', 'VeriSign, Inc.'),),
(('organizationalUnitName', 'VeriSign Trust Network'),),
(('organizationalUnitName',
'Terms of use at https://www.verisign.com/rpa (c)10'),),
(('commonName', 'VeriSign Class 3 International Server CA - G3'),)),
'notAfter': 'Sep 20 23:59:59 2012 GMT',
'notBefore': 'Sep 21 00:00:00 2011 GMT',
'serialNumber': '2EE6EA7640A075CEE5005F4D7C79549A',
'subject': ((('countryName', 'FI'),),
(('stateOrProvinceName', 'Espoo'),),
(('localityName', 'Espoo'),),
(('organizationName', 'Nokia'),),
(('organizationalUnitName', 'BI'),),
(('commonName', 'projects.developer.nokia.com'),)),
'subjectAltName': (('DNS', 'projects.developer.nokia.com'),
('DNS', 'projects.forum.nokia.com')),
'version': 3}
ok
test_parse_cert_CVE_2013_4238 (test.test_ssl.BasicSocketTests) ...
{'issuer': ((('countryName', 'US'),),
(('stateOrProvinceName', 'Oregon'),),
(('localityName', 'Beaverton'),),
(('organizationName', 'Python Software Foundation'),),
(('organizationalUnitName', 'Python Core Development'),),
(('commonName', 'null.python.org\x00example.org'),),
(('emailAddress', 'python-dev@python.org'),)),
'notAfter': 'Aug 7 13:12:52 2013 GMT',
'notBefore': 'Aug 7 13:11:52 2013 GMT',
'serialNumber': '00',
'subject': ((('countryName', 'US'),),
(('stateOrProvinceName', 'Oregon'),),
(('localityName', 'Beaverton'),),
(('organizationName', 'Python Software Foundation'),),
(('organizationalUnitName', 'Python Core Development'),),
(('commonName', 'null.python.org\x00example.org'),),
(('emailAddress', 'python-dev@python.org'),)),
'subjectAltName': (('DNS', 'altnull.python.org\x00example.com'),
('email', 'null@python.org\x00user@example.org'),
('URI', 'http://null.python.org\x00http://example.org'),
('IP Address', '192.0.2.1'),
('IP Address', '2001:DB8:0:0:0:0:0:1\n')),
'version': 3}
ok
test_parse_cert_CVE_2019_5010 (test.test_ssl.BasicSocketTests) ...
{'issuer': ((('countryName', 'UK'),), (('commonName', 'cody-ca'),)),
'notAfter': 'Jun 14 18:00:58 2028 GMT',
'notBefore': 'Jun 18 18:00:58 2018 GMT',
'serialNumber': '02',
'subject': ((('countryName', 'UK'),),
(('commonName', 'codenomicon-vm-2.test.lal.cisco.com'),)),
'subjectAltName': (('DNS', 'codenomicon-vm-2.test.lal.cisco.com'),),
'version': 3}
ok
test_purpose_enum (test.test_ssl.BasicSocketTests) ... ok
test_random (test.test_ssl.BasicSocketTests) ...
RAND_status is 1 (sufficient randomness)
ok
test_refcycle (test.test_ssl.BasicSocketTests) ... skipped 'implementation detail specific to cpython'
test_server_side (test.test_ssl.BasicSocketTests) ... ok
test_timeout (test.test_ssl.BasicSocketTests) ... ok
test_tls_unique_channel_binding (test.test_ssl.BasicSocketTests) ... ok
test_unknown_channel_binding (test.test_ssl.BasicSocketTests) ... ok
test_unsupported_dtls (test.test_ssl.BasicSocketTests) ... ok
test_wrapped_unconnected (test.test_ssl.BasicSocketTests) ... ok
test_lib_reason (test.test_ssl.SSLErrorTests) ... ok
test_str (test.test_ssl.SSLErrorTests) ... ok
test_subclass (test.test_ssl.SSLErrorTests) ... ok
test_ciphers (test.test_ssl.NetworkedTests) ... ok
test_connect (test.test_ssl.NetworkedTests) ... ok
test_connect_cadata (test.test_ssl.NetworkedTests) ... ERROR
test_connect_capath (test.test_ssl.NetworkedTests) ... ok
test_connect_ex (test.test_ssl.NetworkedTests) ... ok
test_connect_ex_error (test.test_ssl.NetworkedTests) ... ok
test_connect_with_context (test.test_ssl.NetworkedTests) ... ok
test_context_setget (test.test_ssl.NetworkedTests) ... ok
test_get_ca_certs_capath (test.test_ssl.NetworkedTests) ... ok
test_get_server_certificate (test.test_ssl.NetworkedTests) ... [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed
Verified certificate for self-signed.pythontest.net:443 is
-----BEGIN CERTIFICATE-----
MIIF9zCCA9+gAwIBAgIUH98b4Fw/DyugC9cV7VK7ZODzHsIwDQYJKoZIhvcNAQEL
BQAwgYoxCzAJBgNVBAYTAlhZMRcwFQYDVQQIDA5DYXN0bGUgQW50aHJheDEYMBYG
A1UEBwwPQXJndW1lbnQgQ2xpbmljMSMwIQYDVQQKDBpQeXRob24gU29mdHdhcmUg
Rm91bmRhdGlvbjEjMCEGA1UEAwwac2VsZi1zaWduZWQucHl0aG9udGVz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i+0BsV9zUwDiBaHzAPBgNVHRMBAf8EBTADAQH/MA0GCSqGSIb3
DQEBCwUAA4ICAQCR+7a7N/m+WLkxPPIA/CB4MOr2Uf8ixTv435Nyv6rXOun0+lTP
ExSZ0uYQ+L0WylItI3cQHULldDueD+s8TGzxf5woaLKf6tqyr0NYhKs+UeNEzDnN
9PHQIhX0SZw3XyXGUgPNBfRCg2ZDdtMMdOU4XlQN/IN/9hbYTrueyY7eXq9hmtI9
1srftAMqr9SR1JP7aHI6DVgrEsZVMTDnfT8WmLSGLlY1HmGfdEn1Ip5sbo9uSkiH
AEPgPfjYIvR5LqTOMn4KsrlZyBbFIDh9Sl99M1kZzgH6zUGVLCDg1y6Cms69fx/e
W1HoIeVkY4b4TY7Bk7JsqyNhIuqu7ARaxkdaZWhYaA2YyknwANdFfNpfH+elCLIk
BUt5S3f4i7DaUePTvKukCZiCq4Oyln7RcOn5If73wCeLB/ZM9Ei1HforyLWP1CN8
XLfpHaoeoPSWIveI0XHUl65LsPN2UbMbul/F23hwl+h8+BLmyAS680Yhn4zEN6Ku
B7Po90HoFa1Du3bmx4jsN73UkT/dwMTi6K072FbipnC1904oGlWmLwvAHvrtxxmL
Pl3pvEaZIu8wa/PNF6Y7J7VIewikIJq6Ta6FrWeFfzMWOj2qA1ZZi6fUaDSNYvuV
J5quYKCc/O+I/yDDf8wyBbZ/gvUXzUHTMYGG+bFrn1p7XDbYYeEJ6R/xEg==
-----END CERTIFICATE-----
[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed
Verified certificate for ipv6.google.com:443 is
-----BEGIN CERTIFICATE-----
MIIDezCCAmOgAwIBAgIRALPputykWbtMh/hlwFUh6bUwDQYJKoZIhvcNAQELBQAw
TzEyMDAGA1UECxMpTm8gU05JIHByb3ZpZGVkIC0gcGxlYXNlIGZpeCB5b3VyIGNs
aWVudC4xGTAXBgNVBAMTEGludmFsaWQyLmludmFsaWQwHhcNMjYwNjI5MDk0MzIy
WhcNMjYwOTIxMDk0Mz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ex (test.test_ssl.NetworkedTests) ... ok
test_non_blocking_handshake (test.test_ssl.NetworkedTests) ...
Needed 2 calls to do_handshake() to establish session.
ok
test_timeout_connect_ex (test.test_ssl.NetworkedTests) ... ok
test_alpn_protocols (test.test_ssl.ThreadedTests) ... server: new connection from ('127.0.0.1', 32778)
server: connection cipher is now ('ECDHE-RSA-AES256-GCM-SHA384', 'TLSv1.2', 256)
server: selected protocol is now None
client: sending 'FOO\n'...
client: read 'foo\n'
client: sending 'FOO\n'...
client: read 'foo\n'
client: sending 'FOO\n'...
client: read 'foo\n'
client: closing connection.
server: new connection from ('127.0.0.1', 37080)
server: connection cipher is now ('ECDHE-RSA-AES256-GCM-SHA384', 'TLSv1.2', 256)
server: selected protocol is now None
client: sending 'FOO\n'...
client: read 'foo\n'
client: sending 'FOO\n'...
client: read 'foo\n'
client: sending 'FOO\n'...
client: read 'foo\n'
client: closing connection.
server: new connection from ('127.0.0.1', 41806)
server: connection cipher is now ('ECDHE-RSA-AES256-GCM-SHA384', 'TLSv1.2', 256)
server: selected protocol is now None
client: sending 'FOO\n'...
client: read 'foo\n'
client: sending 'FOO\n'...
client: read 'foo\n'
client: sending 'FOO\n'...
client: read 'foo\n'
client: closing connection.
server: new connection from ('127.0.0.1', 56496)
server: connection cipher is now ('ECDHE-RSA-AES256-GCM-SHA384', 'TLSv1.2', 256)
server: selected protocol is now None
client: sending 'FOO\n'...
client: read 'foo\n'
client: sending 'FOO\n'...
client: read 'foo\n'
client: sending 'FOO\n'...
client: read 'foo\n'
client: closing connection.
ok
test_asyncore_server (test.test_ssl.ThreadedTests)
Check the example asyncore integration. ...
server: new connection from 127.0.0.1:54832
client: sending 'FOO\n'...
server: read 'FOO\n' from client
client: read 'foo\n'
client: closing connection.
client: connection closed.
cleanup: stopping server.
cleanup: joining server thread.
server: read 'over\n' from client
server: closed connection <ssl.SSLSocket object at 0xf43c0490>
server: read '' from client
cleanup: successfully joined.
ok
test_check_hostname (test.test_ssl.ThreadedTests) ...
server: new connection from ('127.0.0.1', 45836)
server: connection cipher is now ('TLS_AES_256_GCM_SHA384', 'TLSv1.3', 256)
server: selected protocol is now None
Test server failure:
Traceback (most recent call last):
File "/buildbot/slave/pypy-c-jit-linux-x86-32/build/lib-python/2.7/test/test_ssl.py", line 1871, in run
msg = self.read()
File "/buildbot/slave/pypy-c-jit-linux-x86-32/build/lib-python/2.7/test/test_ssl.py", line 1848, in read
return self.sslconn.read()
File "/buildbot/slave/pypy-c-jit-linux-x86-32/build/lib-python/2.7/ssl.py", line 639, in read
v = self._sslobj.read(len)
File "/buildbot/slave/pypy-c-jit-linux-x86-32/build/lib_pypy/_cffi_ssl/_stdssl/__init__.py", line 556, in read
return self._read_no_buf(length)
File "/buildbot/slave/pypy-c-jit-linux-x86-32/build/lib_pypy/_cffi_ssl/_stdssl/__init__.py", line 602, in _read_no_buf
raise pyssl_error(self, count)
SSLError: Connection reset by peer
server: new connection from ('127.0.0.1', 60554)
server: connection cipher is now ('TLS_AES_256_GCM_SHA384', 'TLSv1.3', 256)
server: selected protocol is now None
Test server failure:
Traceback (most recent call last):
File "/buildbot/slave/pypy-c-jit-linux-x86-32/build/lib-python/2.7/test/test_ssl.py", line 1871, in run
msg = self.read()
File "/buildbot/slave/pypy-c-jit-linux-x86-32/build/lib-python/2.7/test/test_ssl.py", line 1848, in read
return self.sslconn.read()
File "/buildbot/slave/pypy-c-jit-linux-x86-32/build/lib-python/2.7/ssl.py", line 639, in read
v = self._sslobj.read(len)
File "/buildbot/slave/pypy-c-jit-linux-x86-32/build/lib_pypy/_cffi_ssl/_stdssl/__init__.py", line 556, in read
return self._read_no_buf(length)
File "/buildbot/slave/pypy-c-jit-linux-x86-32/build/lib_pypy/_cffi_ssl/_stdssl/__init__.py", line 602, in _read_no_buf
raise pyssl_error(self, count)
SSLError: Connection reset by peer
ok
test_compression (test.test_ssl.ThreadedTests) ... server: new connection from ('127.0.0.1', 48012)
client: sending 'FOO\n'...
server: connection cipher is now ('TLS_AES_256_GCM_SHA384', 'TLSv1.3', 256)
server: selected protocol is now None
client: read 'foo\n'
client: sending 'FOO\n'...
client: read 'foo\n'
client: sending 'FOO\n'...
client: read 'foo\n'
client: closing connection.
got compression: None
ok
test_compression_disabled (test.test_ssl.ThreadedTests) ... server: new connection from ('127.0.0.1', 59478)
client: sending 'FOO\n'...
server: connection cipher is now ('TLS_AES_256_GCM_SHA384', 'TLSv1.3', 256)
server: selected protocol is now None
client: read 'foo\n'
client: sending 'FOO\n'...
client: read 'foo\n'
client: sending 'FOO\n'...
client: read 'foo\n'
client: closing connection.
ok
test_crl_check (test.test_ssl.ThreadedTests) ...
server: new connection from ('127.0.0.1', 40162)
server: connection cipher is now ('TLS_AES_256_GCM_SHA384', 'TLSv1.3', 256)
server: selected protocol is now None
Test server failure:
Traceback (most recent call last):
File "/buildbot/slave/pypy-c-jit-linux-x86-32/build/lib-python/2.7/test/test_ssl.py", line 1871, in run
msg = self.read()
File "/buildbot/slave/pypy-c-jit-linux-x86-32/build/lib-python/2.7/test/test_ssl.py", line 1848, in read
return self.sslconn.read()
File "/buildbot/slave/pypy-c-jit-linux-x86-32/build/lib-python/2.7/ssl.py", line 639, in read
v = self._sslobj.read(len)
File "/buildbot/slave/pypy-c-jit-linux-x86-32/build/lib_pypy/_cffi_ssl/_stdssl/__init__.py", line 556, in read
return self._read_no_buf(length)
File "/buildbot/slave/pypy-c-jit-linux-x86-32/build/lib_pypy/_cffi_ssl/_stdssl/__init__.py", line 602, in _read_no_buf
raise pyssl_error(self, count)
SSLError: Connection reset by peer
server: new connection from ('127.0.0.1', 50392)
server: bad connection attempt from ('127.0.0.1', 50392):
Traceback (most recent call last):
File "/buildbot/slave/pypy-c-jit-linux-x86-32/build/lib-python/2.7/test/test_ssl.py", line 1791, in wrap_conn
self.sock, server_side=True)
File "/buildbot/slave/pypy-c-jit-linux-x86-32/build/lib-python/2.7/ssl.py", line 369, in wrap_socket
_context=self)
File "/buildbot/slave/pypy-c-jit-linux-x86-32/build/lib-python/2.7/ssl.py", line 597, in __init__
self.do_handshake()
File "/buildbot/slave/pypy-c-jit-linux-x86-32/build/lib-python/2.7/ssl.py", line 826, in do_handshake
self._sslobj.do_handshake()
File "/buildbot/slave/pypy-c-jit-linux-x86-32/build/lib_pypy/_cffi_ssl/_stdssl/__init__.py", line 473, in do_handshake
raise pyssl_error(self, ret)
SSLError: [SSL: TLSV1_ALERT_UNKNOWN_CA] tlsv1 alert unknown ca
server: new connection from ('127.0.0.1', 46228)
server: connection cipher is now ('TLS_AES_256_GCM_SHA384', 'TLSv1.3', 256)
server: selected protocol is now None
Test server failure:
Traceback (most recent call last):
File "/buildbot/slave/pypy-c-jit-linux-x86-32/build/lib-python/2.7/test/test_ssl.py", line 1871, in run
msg = self.read()
File "/buildbot/slave/pypy-c-jit-linux-x86-32/build/lib-python/2.7/test/test_ssl.py", line 1848, in read
return self.sslconn.read()
File "/buildbot/slave/pypy-c-jit-linux-x86-32/build/lib-python/2.7/ssl.py", line 639, in read
v = self._sslobj.read(len)
File "/buildbot/slave/pypy-c-jit-linux-x86-32/build/lib_pypy/_cffi_ssl/_stdssl/__init__.py", line 556, in read
return self._read_no_buf(length)
File "/buildbot/slave/pypy-c-jit-linux-x86-32/build/lib_pypy/_cffi_ssl/_stdssl/__init__.py", line 602, in _read_no_buf
raise pyssl_error(self, count)
SSLError: Connection reset by peer
ok
test_default_ecdh_curve (test.test_ssl.ThreadedTests) ... server: new connection from ('127.0.0.1', 33868)
server: connection cipher is now ('ECDHE-RSA-AES256-GCM-SHA384', 'TLSv1.2', 256)
server: selected protocol is now None
ok
test_dh_params (test.test_ssl.ThreadedTests) ... server: new connection from ('127.0.0.1', 46134)
client: sending 'FOO\n'...
server: connection cipher is now ('DHE-RSA-AES256-GCM-SHA384', 'TLSv1.2', 256)
server: selected protocol is now None
client: read 'foo\n'
client: sending 'FOO\n'...
client: read 'foo\n'
client: sending 'FOO\n'...
client: read 'foo\n'
client: closing connection.
ok
test_do_handshake_enotconn (test.test_ssl.ThreadedTests) ... ok
test_echo (test.test_ssl.ThreadedTests)
Basic test of an SSL client connecting to a server ...
server: new connection from ('127.0.0.1', 40116)
client: sending 'FOO\n'...
server: connection cipher is now ('TLS_AES_256_GCM_SHA384', 'TLSv1.3', 256)
server: selected protocol is now None
client: read 'foo\n'
client: sending 'FOO\n'...
client: read 'foo\n'
client: sending 'FOO\n'...
client: read 'foo\n'
client: closing connection.
server: new connection from ('127.0.0.1', 46806)
server: connection cipher is now ('ECDHE-RSA-AES256-GCM-SHA384', 'TLSv1.2', 256)
server: selected protocol is now None
client: sending 'FOO\n'...
client: read 'foo\n'
client: sending 'FOO\n'...
client: read 'foo\n'
client: sending 'FOO\n'...
client: read 'foo\n'
client: closing connection.
ok
test_getpeercert (test.test_ssl.ThreadedTests) ...
{'issuer': ((('countryName', 'XY'),),
(('localityName', 'Castle Anthrax'),),
(('organizationName', 'Python Software Foundation'),),
(('commonName', 'localhost'),)),
'notAfter': 'Aug 26 14:23:15 2028 GMT',
'notBefore': 'Aug 29 14:23:15 2018 GMT',
'serialNumber': '98A7CF88C74A32ED',
'subject': ((('countryName', 'XY'),),
(('localityName', 'Castle Anthrax'),),
(('organizationName', 'Python Software Foundation'),),
(('commonName', 'localhost'),)),
'subjectAltName': (('DNS', 'localhost'),),
'version': 3}
Connection cipher is ('TLS_AES_256_GCM_SHA384', 'TLSv1.3', 256).
ok
test_getpeercert_enotconn (test.test_ssl.ThreadedTests) ... ok
test_handshake_timeout (test.test_ssl.ThreadedTests) ... ok
test_no_shared_ciphers (test.test_ssl.ThreadedTests) ... server: new connection from ('127.0.0.1', 48306)
server: bad connection attempt from ('127.0.0.1', 48306):
Traceback (most recent call last):
File "/buildbot/slave/pypy-c-jit-linux-x86-32/build/lib-python/2.7/test/test_ssl.py", line 1791, in wrap_conn
self.sock, server_side=True)
File "/buildbot/slave/pypy-c-jit-linux-x86-32/build/lib-python/2.7/ssl.py", line 369, in wrap_socket
_context=self)
File "/buildbot/slave/pypy-c-jit-linux-x86-32/build/lib-python/2.7/ssl.py", line 597, in __init__
self.do_handshake()
File "/buildbot/slave/pypy-c-jit-linux-x86-32/build/lib-python/2.7/ssl.py", line 826, in do_handshake
self._sslobj.do_handshake()
File "/buildbot/slave/pypy-c-jit-linux-x86-32/build/lib_pypy/_cffi_ssl/_stdssl/__init__.py", line 473, in do_handshake
raise pyssl_error(self, ret)
SSLError: [SSL: NO_SHARED_CIPHER] no shared cipher
ok
test_npn_protocols (test.test_ssl.ThreadedTests) ... server: new connection from ('127.0.0.1', 53766)
server: connection cipher is now ('ECDHE-RSA-AES256-GCM-SHA384', 'TLSv1.2', 256)
server: selected protocol is now http/1.1
client: sending 'FOO\n'...
client: read 'foo\n'
client: sending 'FOO\n'...
client: read 'foo\n'
client: sending 'FOO\n'...
client: read 'foo\n'
client: closing connection.
server: new connection from ('127.0.0.1', 50008)
server: connection cipher is now ('ECDHE-RSA-AES256-GCM-SHA384', 'TLSv1.2', 256)
server: selected protocol is now http/1.1
client: sending 'FOO\n'...
client: read 'foo\n'
client: sending 'FOO\n'...
client: read 'foo\n'
client: sending 'FOO\n'...
client: read 'foo\n'
client: closing connection.
server: new connection from ('127.0.0.1', 44396)
server: connection cipher is now ('ECDHE-RSA-AES256-GCM-SHA384', 'TLSv1.2', 256)
server: selected protocol is now spdy/2
client: sending 'FOO\n'...
client: read 'foo\n'
client: sending 'FOO\n'...
client: read 'foo\n'
client: sending 'FOO\n'...
client: read 'foo\n'
client: closing connection.
server: new connection from ('127.0.0.1', 38120)
server: connection cipher is now ('ECDHE-RSA-AES256-GCM-SHA384', 'TLSv1.2', 256)
server: selected protocol is now abc
client: sending 'FOO\n'...
client: read 'foo\n'
client: sending 'FOO\n'...
client: read 'foo\n'
client: sending 'FOO\n'...
client: read 'foo\n'
client: closing connection.
ok
test_protocol_sslv2 (test.test_ssl.ThreadedTests)
Connecting to an SSLv2 server with various client options ... skipped 'OpenSSL is compiled without SSLv2 support'
test_protocol_sslv23 (test.test_ssl.ThreadedTests)
Connecting to an SSLv23 server with various client options ... skipped 'OpenSSL 3 effectively disables TLS < 1.2'
test_protocol_sslv3 (test.test_ssl.ThreadedTests)
Connecting to an SSLv3 server with various client options ... skipped 'OpenSSL is compiled without SSLv3 support'
test_protocol_tlsv1 (test.test_ssl.ThreadedTests)
Connecting to a TLSv1 server with various client options ... skipped 'OpenSSL 3 effectively disables TLS < 1.2'
test_protocol_tlsv1_1 (test.test_ssl.ThreadedTests)
Connecting to a TLSv1.1 server with various client options. ... skipped 'OpenSSL 3 effectively disables TLS < 1.2'
test_protocol_tlsv1_2 (test.test_ssl.ThreadedTests)
Connecting to a TLSv1.2 server with various client options. ...
PROTOCOL_TLSv1_2->PROTOCOL_TLSv1_2 CERT_NONE
{PROTOCOL_TLS->PROTOCOL_TLSv1_2} CERT_NONE
PROTOCOL_TLSv1_2->PROTOCOL_TLS CERT_NONE
{PROTOCOL_TLSv1->PROTOCOL_TLSv1_2} CERT_NONE
{PROTOCOL_TLSv1_2->PROTOCOL_TLSv1} CERT_NONE
{PROTOCOL_TLSv1_1->PROTOCOL_TLSv1_2} CERT_NONE
{PROTOCOL_TLSv1_2->PROTOCOL_TLSv1_1} CERT_NONE
ok
test_read_write_after_close_raises_valuerror (test.test_ssl.ThreadedTests) ... ok
test_recv_send (test.test_ssl.ThreadedTests)
Test recv(), send() and friends. ...
server: new connection from ('127.0.0.1', 49560)
server: connection cipher is now ('TLS_AES_256_GCM_SHA384', 'TLSv1.3', 256)
server: selected protocol is now None
ok
test_recv_zero (test.test_ssl.ThreadedTests) ... server: new connection from ('127.0.0.1', 58196)
server: connection cipher is now ('TLS_AES_256_GCM_SHA384', 'TLSv1.3', 256)
server: selected protocol is now None
ok
test_rude_shutdown (test.test_ssl.ThreadedTests)
A brutal shutdown of an SSL server should raise an OSError ... ok
test_selected_alpn_protocol (test.test_ssl.ThreadedTests) ... server: new connection from ('127.0.0.1', 45342)
client: sending 'FOO\n'...
server: connection cipher is now ('TLS_AES_256_GCM_SHA384', 'TLSv1.3', 256)
server: selected protocol is now None
client: read 'foo\n'
client: sending 'FOO\n'...
client: read 'foo\n'
client: sending 'FOO\n'...
client: read 'foo\n'
client: closing connection.
ok
test_selected_alpn_protocol_if_server_uses_alpn (test.test_ssl.ThreadedTests) ... server: new connection from ('127.0.0.1', 34388)
client: sending 'FOO\n'...
server: connection cipher is now ('TLS_AES_256_GCM_SHA384', 'TLSv1.3', 256)
server: selected protocol is now None
client: read 'foo\n'
client: sending 'FOO\n'...
client: read 'foo\n'
client: sending 'FOO\n'...
client: read 'foo\n'
client: closing connection.
ok
test_selected_npn_protocol (test.test_ssl.ThreadedTests) ... server: new connection from ('127.0.0.1', 34704)
client: sending 'FOO\n'...
server: connection cipher is now ('TLS_AES_256_GCM_SHA384', 'TLSv1.3', 256)
server: selected protocol is now None
client: read 'foo\n'
client: sending 'FOO\n'...
client: read 'foo\n'
client: sending 'FOO\n'...
client: read 'foo\n'
client: closing connection.
ok
test_server_accept (test.test_ssl.ThreadedTests) ... ok
test_sni_callback (test.test_ssl.ThreadedTests) ... server: new connection from ('127.0.0.1', 56860)
server: connection cipher is now ('TLS_AES_256_GCM_SHA384', 'TLSv1.3', 256)
server: selected protocol is now None
server: new connection from ('127.0.0.1', 51282)
server: connection cipher is now ('TLS_AES_256_GCM_SHA384', 'TLSv1.3', 256)
server: selected protocol is now None
server: new connection from ('127.0.0.1', 32894)
server: connection cipher is now ('TLS_AES_256_GCM_SHA384', 'TLSv1.3', 256)
server: selected protocol is now None
ok
test_sni_callback_alert (test.test_ssl.ThreadedTests) ... ok
test_sni_callback_raising (test.test_ssl.ThreadedTests) ... ok
test_sni_callback_wrong_return_type (test.test_ssl.ThreadedTests) ... ok
test_socketserver (test.test_ssl.ThreadedTests)
Using a SocketServer to create and manage SSL connections. ...
server (('127.0.0.1', 43167):43167 ('TLS_AES_256_GCM_SHA384', 'TLSv1.3', 256)):
[23/Jul/2026 22:35:10] "GET /keycert.pem HTTP/1.1" 200 -
client: read 4058 bytes from remote server '<HTTPSServerThread <HTTPSServer localhost.localdomain:43167>>'
stopping HTTPS server
joining HTTPS thread
ok
test_starttls (test.test_ssl.ThreadedTests)
Switching from clear text to encrypted and back again. ...
server: new connection from ('127.0.0.1', 34586)
client: sending 'msg 1'...
server: read 'msg 1' (unencrypted), sending back 'msg 1' (unencrypted)...
client: read 'msg 1' from server
client: sending 'MSG 2'...
server: read 'MSG 2' (unencrypted), sending back 'msg 2' (unencrypted)...
client: read 'msg 2' from server
client: sending 'STARTTLS'...
server: read STARTTLS from client, sending OK...
client: read 'ok' from server, starting TLS...
client: sending 'MSG 3'...
server: connection cipher is now ('TLS_AES_256_GCM_SHA384', 'TLSv1.3', 256)
server: selected protocol is now None
server: read 'MSG 3' (encrypted), sending back 'msg 3' (encrypted)...
client: read 'msg 3' from server
client: sending 'msg 4'...
server: read 'msg 4' (encrypted), sending back 'msg 4' (encrypted)...
client: read 'msg 4' from server
client: sending 'ENDTLS'...
server: read ENDTLS from client, sending OK...
client: read 'ok' from server, ending TLS...
server: connection is now unencrypted...
client: sending 'msg 5'...
server: read 'msg 5' (unencrypted), sending back 'msg 5' (unencrypted)...
client: read 'msg 5' from server
client: sending 'msg 6'...
server: read 'msg 6' (unencrypted), sending back 'msg 6' (unencrypted)...
client: read 'msg 6' from server
client: closing connection.
server: client closed connection
ok
test_tls1_3 (test.test_ssl.ThreadedTests) ... server: new connection from ('127.0.0.1', 39990)
server: connection cipher is now ('TLS_AES_256_GCM_SHA384', 'TLSv1.3', 256)
server: selected protocol is now None
ok
test_tls_unique_channel_binding (test.test_ssl.ThreadedTests)
Test tls-unique channel binding. ...
server: new connection from ('127.0.0.1', 37686)
got channel binding data: " \xfad\xb0*\x85\xcb\xd2\x89\xe4\x8a'\xc0sm\x8a\xd1\xac\xd0'\xf4\x18\x96]{\xfa9\xa2\xafPv\xa9\xbe\x1da\xd0&\x12N\x92\xf0\xee\xd4C\x93q\xe5!"
server: connection cipher is now ('TLS_AES_256_GCM_SHA384', 'TLSv1.3', 256)
server: selected protocol is now None
server: new connection from ('127.0.0.1', 37700)
got another channel binding data: '\xb43\x06\x93\x1b\xb9\x08\xaf\x19sO!7\xc6\x7f\t\xbapzB\x9c=\xfd5C\xea\xa2\xc2\x1di^\x1f\\`x\xb8\x9c\xfc8\x18\xac\x157\x8a\x05\xc2v\xa5'
server: connection cipher is now ('TLS_AES_256_GCM_SHA384', 'TLSv1.3', 256)
server: selected protocol is now None
ok
test_version_basic (test.test_ssl.ThreadedTests) ... ok
test_wrong_cert (test.test_ssl.ThreadedTests)
Connecting when the server rejects the client's certificate ...
SSLError is SSLError(1, '[SSL: TLSV1_ALERT_INTERNAL_ERROR] tlsv1 alert internal error')
ok
======================================================================
ERROR: test_load_verify_cadata (test.test_ssl.ContextTests)
----------------------------------------------------------------------
Traceback (most recent call last):
File "/buildbot/slave/pypy-c-jit-linux-x86-32/build/lib-python/2.7/test/test_ssl.py", line 1086, in test_load_verify_cadata
ctx.load_verify_locations(cadata=cacert_der)
File "/buildbot/slave/pypy-c-jit-linux-x86-32/build/lib_pypy/_cffi_ssl/_stdssl/__init__.py", line 1339, in load_verify_locations
self._add_ca_certs(buf, len(buf), ca_file_type)
File "/buildbot/slave/pypy-c-jit-linux-x86-32/build/lib_pypy/_cffi_ssl/_stdssl/__init__.py", line 1412, in _add_ca_certs
raise ssl_error(None)
SSLError: [ASN1: NOT_ENOUGH_DATA] not enough data
======================================================================
ERROR: test_connect_cadata (test.test_ssl.NetworkedTests)
----------------------------------------------------------------------
Traceback (most recent call last):
File "/buildbot/slave/pypy-c-jit-linux-x86-32/build/lib-python/2.7/test/test_ssl.py", line 1639, in test_connect_cadata
ctx.load_verify_locations(cadata=der)
File "/buildbot/slave/pypy-c-jit-linux-x86-32/build/lib_pypy/_cffi_ssl/_stdssl/__init__.py", line 1339, in load_verify_locations
self._add_ca_certs(buf, len(buf), ca_file_type)
File "/buildbot/slave/pypy-c-jit-linux-x86-32/build/lib_pypy/_cffi_ssl/_stdssl/__init__.py", line 1412, in _add_ca_certs
raise ssl_error(None)
SSLError: [ASN1: NOT_ENOUGH_DATA] not enough data
----------------------------------------------------------------------
Ran 109 tests in 8.078s
FAILED (errors=2, skipped=11)
Traceback (most recent call last):
File "/buildbot/slave/pypy-c-jit-linux-x86-32/build/pypy/tool/pytest/run-script/regrverbose.py", line 14, in <module>
indirect_test()
File "/buildbot/slave/pypy-c-jit-linux-x86-32/build/lib-python/2.7/test/test_ssl.py", line 3373, in test_main
support.run_unittest(*tests)
File "/buildbot/slave/pypy-c-jit-linux-x86-32/build/lib-python/2.7/test/support/__init__.py", line 1687, in run_unittest
_run_suite(suite)
File "/buildbot/slave/pypy-c-jit-linux-x86-32/build/lib-python/2.7/test/support/__init__.py", line 1578, in _run_suite
raise TestFailed(err)
TestFailed: multiple errors occurred
builder: pypy-c-jit-linux-x86-32 build #8404+
test: lib-python/2.7/test/test_ssl.py::unmodified