Merge pull request #932 from fimad/master

Do not send Proxy-Agent in CONNECT responses, fix #783
This commit is contained in:
Maximilian Hils 2016-02-14 01:27:51 +01:00
commit a54fc2785f

View File

@ -456,14 +456,13 @@ def make_connect_request(address):
def make_connect_response(http_version):
headers = Headers(
Proxy_Agent=version.NAMEVERSION
)
# Do not send any response headers as it breaks proxying non-80 ports on
# Android emulators using the -http-proxy option.
return HTTPResponse(
http_version,
200,
"Connection established",
headers,
Headers(),
"",
)