kopia lustrzana https://github.com/micropython/micropython-lib
urllib.urequest: Add server_hostname param to ussl.wrap_socket() call.
rodzic
98502a223a
commit
633f030d6f
|
@ -25,7 +25,7 @@ def urlopen(url, data=None, method="GET"):
|
|||
s = usocket.socket()
|
||||
s.connect(addr)
|
||||
if proto == "https:":
|
||||
s = ussl.wrap_socket(s)
|
||||
s = ussl.wrap_socket(s, server_hostname=host)
|
||||
|
||||
s.write(method)
|
||||
s.write(b" /")
|
||||
|
|
Ładowanie…
Reference in New Issue