mirror of
https://github.com/Hopiu/linkchecker.git
synced 2026-05-01 11:34:41 +00:00
Send correct host header when using http proxy.
This commit is contained in:
parent
9855b4c30e
commit
7536472797
2 changed files with 5 additions and 1 deletions
|
|
@ -4,6 +4,9 @@ Fixes:
|
|||
- ftp: Fix support for FTP ports other than the default.
|
||||
- build: Use _WIN32 instead of WIN32 define to detect Windows systems.
|
||||
Closes: SF bug #2978524
|
||||
- http: Send correct host header when using proxies. Thanks Jason Martin
|
||||
for the patch.
|
||||
Closes: SF bug #3035754
|
||||
|
||||
Changes:
|
||||
- checking: Caches are now size-restricted to limit the memory
|
||||
|
|
|
|||
|
|
@ -487,7 +487,8 @@ Use URL `%(newurl)s' instead for checking.""") % {
|
|||
self.urlparts[3], anchor))
|
||||
self.url_connection.putrequest(self.method, path, skip_host=True,
|
||||
skip_accept_encoding=True)
|
||||
self.url_connection.putheader("Host", host)
|
||||
# be sure to use the original host as header even for proxies
|
||||
self.url_connection.putheader("Host", self.urlparts[1])
|
||||
# userinfo is from http://user@pass:host/
|
||||
if self.userinfo:
|
||||
self.url_connection.putheader("Authorization", self.userinfo)
|
||||
|
|
|
|||
Loading…
Reference in a new issue