Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 9 additions & 0 deletions python-stdlib/ssl/ssl.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ class SSLContext:
def __init__(self, *args):
self._context = tls.SSLContext(*args)
self._context.verify_mode = CERT_NONE
self._context.ecdsa_sign_callback = None

@property
def verify_mode(self):
Expand All @@ -15,6 +16,14 @@ def verify_mode(self):
def verify_mode(self, val):
self._context.verify_mode = val

@property
def ecdsa_sign_callback(self):
return self._context.ecdsa_sign_callback

@ecdsa_sign_callback.setter
def ecdsa_sign_callback(self, val):
self._context.ecdsa_sign_callback = val

def load_cert_chain(self, certfile, keyfile):
if isinstance(certfile, str):
with open(certfile, "rb") as f:
Expand Down
Loading