Commit 158ccf26 authored by Jason Madden's avatar Jason Madden

Implement verify_client_post_handshake; appveyor has TLS 1.3 now so those tests are running there.

parent 271e5865
......@@ -16,6 +16,8 @@
- Improve the way joining the main thread works on Python 3.
- Implement ``SSLSocket.verify_client_post_handshake()`` when available.
1.5a1 (2019-05-02)
==================
......
......@@ -678,6 +678,11 @@ class SSLSocket(socket):
return None
return self._sslobj.tls_unique_cb()
def verify_client_post_handshake(self):
# Only present in 3.7.1+; an attributeerror is alright
if self._sslobj:
return self._sslobj.verify_client_post_handshake()
raise ValueError("No SSL wrapper around " + str(self))
# Python does not support forward declaration of types
SSLContext.sslsocket_class = SSLSocket
......
......@@ -351,6 +351,15 @@ RUN_ALONE = [
'test__example_webproxy.py',
]
if APPVEYOR:
# Strange failures sometimes, but only on Python 3.7, reporting
# "ConnectionAbortedError: [WinError 10053] An established
# connection was aborted by the software in your host machine"
# when we've done no such thing. Try running not in parallel
RUN_ALONE += [
'test__ssl.py',
'test__server.py',
]
if APPVEYOR or TRAVIS:
......
......@@ -29,12 +29,13 @@ class Thread(_Thread):
def __init__(self, **kwargs):
target = kwargs.pop('target')
caller = getcurrent()
@wraps(target)
def errors_are_fatal(*args, **kwargs):
try:
return target(*args, **kwargs)
except: # pylint:disable=bare-except
getcurrent().parent.throw(*sys.exc_info())
caller.throw(*sys.exc_info())
_Thread.__init__(self, target=errors_are_fatal, **kwargs)
self.start()
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment