Blame SOURCES/wget-1.14-rh1203384.patch
|
|
dba8a8 |
From aed7d4163a9e2083d294a9471e1347ab13d6f2ab Mon Sep 17 00:00:00 2001
|
|
|
dba8a8 |
From: Pavel Mateja <pavel@netsafe.cz>
|
|
|
dba8a8 |
Date: Sat, 2 Nov 2013 11:27:58 +0100
|
|
|
dba8a8 |
Subject: [PATCH] http: specify Host when CONNECT is used.
|
|
|
dba8a8 |
|
|
|
dba8a8 |
---
|
|
|
dba8a8 |
src/http.c | 7 +++----
|
|
|
dba8a8 |
2 files changed, 7 insertions(+), 4 deletions(-)
|
|
|
dba8a8 |
|
|
|
dba8a8 |
diff --git a/src/http.c b/src/http.c
|
|
|
dba8a8 |
index dbfcdfb..8917fa5 100644
|
|
|
dba8a8 |
--- a/src/http.c
|
|
|
dba8a8 |
+++ b/src/http.c
|
|
|
dba8a8 |
@@ -2013,10 +2013,9 @@ gethttp (struct url *u, struct http_stat *hs, int *dt, struct url *proxy,
|
|
|
dba8a8 |
the regular request below. */
|
|
|
dba8a8 |
proxyauth = NULL;
|
|
|
dba8a8 |
}
|
|
|
dba8a8 |
- /* Examples in rfc2817 use the Host header in CONNECT
|
|
|
dba8a8 |
- requests. I don't see how that gains anything, given
|
|
|
dba8a8 |
- that the contents of Host would be exactly the same as
|
|
|
dba8a8 |
- the contents of CONNECT. */
|
|
|
dba8a8 |
+ request_set_header (connreq, "Host",
|
|
|
dba8a8 |
+ aprintf ("%s:%d", u->host, u->port),
|
|
|
dba8a8 |
+ rel_value);
|
|
|
dba8a8 |
|
|
|
dba8a8 |
write_error = request_send (connreq, sock, 0);
|
|
|
dba8a8 |
request_free (connreq);
|
|
|
dba8a8 |
--
|
|
|
dba8a8 |
2.1.0
|
|
|
dba8a8 |
|