From 607cee59143e45ee6febcdcc5bb717b8e5689fac Mon Sep 17 00:00:00 2001 From: CoolCat467 <52022020+CoolCat467@users.noreply.github.com> Date: Wed, 16 Aug 2023 05:23:24 -0500 Subject: [PATCH] SSL `wrap_socket` and `wrap_bio` accept `bytes` as well (#10590) --- stdlib/ssl.pyi | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/stdlib/ssl.pyi b/stdlib/ssl.pyi index dd7285196..1c49b130e 100644 --- a/stdlib/ssl.pyi +++ b/stdlib/ssl.pyi @@ -436,7 +436,7 @@ class SSLContext: server_side: bool = False, do_handshake_on_connect: bool = True, suppress_ragged_eofs: bool = True, - server_hostname: str | None = None, + server_hostname: str | bytes | None = None, session: SSLSession | None = None, ) -> SSLSocket: ... def wrap_bio( @@ -444,7 +444,7 @@ class SSLContext: incoming: MemoryBIO, outgoing: MemoryBIO, server_side: bool = False, - server_hostname: str | None = None, + server_hostname: str | bytes | None = None, session: SSLSession | None = None, ) -> SSLObject: ... def session_stats(self) -> dict[str, int]: ...