Lines Matching defs:ssl
34 import ssl
36 ssl = None
202 if ssl is not None and isinstance(sock, ssl.SSLSocket):
989 *, ssl=None, family=0,
1006 if server_hostname is not None and not ssl:
1007 raise ValueError('server_hostname is only meaningful with ssl')
1009 if server_hostname is None and ssl:
1022 'when using ssl without a host')
1025 if ssl_handshake_timeout is not None and not ssl:
1027 'ssl_handshake_timeout is only meaningful with ssl')
1029 if ssl_shutdown_timeout is not None and not ssl:
1031 'ssl_shutdown_timeout is only meaningful with ssl')
1113 sock, protocol_factory, ssl, server_hostname,
1125 self, sock, protocol_factory, ssl,
1134 if ssl:
1135 sslcontext = None if isinstance(ssl, bool) else ssl
1238 if ssl is None:
1239 raise RuntimeError('Python ssl module is not available')
1241 if not isinstance(sslcontext, ssl.SSLContext):
1243 f'sslcontext is expected to be an instance of ssl.SSLContext, '
1437 ssl=None,
1458 if isinstance(ssl, bool):
1459 raise TypeError('ssl argument must be an SSLContext or None')
1461 if ssl_handshake_timeout is not None and ssl is None:
1463 'ssl_handshake_timeout is only meaningful with ssl')
1465 if ssl_shutdown_timeout is not None and ssl is None:
1467 'ssl_shutdown_timeout is only meaningful with ssl')
1544 ssl, backlog, ssl_handshake_timeout,
1558 *, ssl=None,
1564 if ssl_handshake_timeout is not None and not ssl:
1566 'ssl_handshake_timeout is only meaningful with ssl')
1568 if ssl_shutdown_timeout is not None and not ssl:
1570 'ssl_shutdown_timeout is only meaningful with ssl')
1576 sock, protocol_factory, ssl, '', server_side=True,