(cls, protocol=None, *args, **kwargs)
| 428 | sslobject_class = None # SSLObject is assigned later. |
| 429 | |
| 430 | def __new__(cls, protocol=None, *args, **kwargs): |
| 431 | if protocol is None: |
| 432 | warnings.warn( |
| 433 | "ssl.SSLContext() without protocol argument is deprecated.", |
| 434 | category=DeprecationWarning, |
| 435 | stacklevel=2 |
| 436 | ) |
| 437 | protocol = PROTOCOL_TLS |
| 438 | self = _SSLContext.__new__(cls, protocol) |
| 439 | return self |
| 440 | |
| 441 | def _encode_hostname(self, hostname): |
| 442 | if hostname is None: |