1
0
mirror of https://github.com/scrapy/scrapy.git synced 2025-02-26 12:03:40 +00:00

Bugfix for leaking Proxy-Authorization header to remote host when using

tunneling
This commit is contained in:
ivannotes 2014-08-01 09:22:58 +08:00
parent 40cc875d6d
commit c1a108b447

View File

@ -166,6 +166,8 @@ class ScrapyAgent(object):
url = urldefrag(request.url)[0]
method = request.method
headers = TxHeaders(request.headers)
if isinstance(agent, self._TunnelingAgent):
headers.removeHeader('Proxy-Authorization')
bodyproducer = _RequestBodyProducer(request.body) if request.body else None
start_time = time()