Skip to content

Commit

Permalink
Send connect request with Host header
Browse files Browse the repository at this point in the history
Send connect request with Host header because some http(s) proxies check the Host header to confirm whether a request is authorized or not.
  • Loading branch information
luxion committed Mar 18, 2019
1 parent fa4a4f7 commit b6c2686
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions pdagent/thirdparty/httpswithverify.py
Original file line number Diff line number Diff line change
Expand Up @@ -121,6 +121,7 @@ def connect(self):
# proxy server. See: httplib.HTTPConnection._tunnel()
end_host = self._tunnel_host
self.sock = sock
self._tunnel_headers = {"Host": end_host}
self._tunnel()

# require server certificate to be provided, and pass along
Expand Down

0 comments on commit b6c2686

Please sign in to comment.