mirror of
https://github.com/Grasscutters/mitmproxy.git
synced 2024-11-23 00:01:36 +00:00
Merge pull request #268 from shvar/patch-1
Fix upstream_cert call in case of https2http
This commit is contained in:
commit
e15b97372b
@ -226,7 +226,7 @@ class ConnectionHandler:
|
||||
else:
|
||||
host = self.server_conn.address.host
|
||||
sans = []
|
||||
if not self.config.no_upstream_cert or not self.server_conn.ssl_established:
|
||||
if not self.config.no_upstream_cert and self.server_conn.ssl_established:
|
||||
upstream_cert = self.server_conn.cert
|
||||
if upstream_cert.cn:
|
||||
host = upstream_cert.cn.decode("utf8").encode("idna")
|
||||
|
Loading…
Reference in New Issue
Block a user