-
Type:
New Feature
-
Resolution: Done
-
Priority:
Minor - P4
-
Affects Version/s: None
-
Component/s: None
-
None
-
None
-
None
-
None
-
None
-
None
-
None
-
None
See DRIVERS-320.
SNI support is only available in python's ssl module when SSLContext is available. Furthermore, SSLContext.wrap_socket will raise ValueError in some versions of python if the underlying OpenSSL version does not support SNI. The workaround is to check if ssl.HAS_SNI is True. The change to pool.py should look something like:
# global addition to pool.py
_HAVE_SNI = False
try:
import ssl
_HAVE_SNI = getattr(ssl, 'HAS_SNI', False)
except ImportError:
pass
# change in pool._configured_socket
if _HAVE_SNI:
sock = ssl_context.wrap_socket(sock, server_hostname=<hostname>)
else:
sock = ssl_context.wrap_socket(sock)
- is depended on by
-
DRIVERS-320 Add SNI Support
-
- Closed
-