MCPcopy Create free account
hub / github.com/apache/thrift / _init_context

Method _init_context

lib/py/src/transport/TSSLSocket.py:61–69  ·  view source on GitHub ↗
(self, ssl_version)

Source from the content-addressed store, hash-verified

59 ssl.PROTOCOL_TLSv1
60
61 def _init_context(self, ssl_version):
62 if self._has_ssl_context:
63 self._context = ssl.SSLContext(ssl_version)
64 if self._context.protocol == ssl.PROTOCOL_SSLv23:
65 self._context.options |= ssl.OP_NO_SSLv2
66 self._context.options |= ssl.OP_NO_SSLv3
67 else:
68 self._context = None
69 self._ssl_version = ssl_version
70
71 @property
72 def _should_verify(self):

Callers 1

__init__Method · 0.95

Calls 1

SSLContextMethod · 0.80

Tested by

no test coverage detected