Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(66)

Unified Diff: net/http/http_network_transaction.cc

Issue 123032: Backport r17761 from the trunk to the 172 branch.... (Closed) Base URL: svn://chrome-svn.corp.google.com/chrome/branches/172/src/
Patch Set: Created 11 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | net/http/http_network_transaction_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/http/http_network_transaction.cc
===================================================================
--- net/http/http_network_transaction.cc (revision 18186)
+++ net/http/http_network_transaction.cc (working copy)
@@ -346,13 +346,14 @@
// 5.3.
void HttpNetworkTransaction::BuildTunnelRequest() {
// RFC 2616 Section 9 says the Host request-header field MUST accompany all
- // HTTP/1.1 requests.
+ // HTTP/1.1 requests. Add "Proxy-Connection: keep-alive" for compat with
+ // HTTP/1.0 proxies such as Squid (required for NTLM authentication).
request_headers_ = StringPrintf("CONNECT %s:%d HTTP/1.1\r\n",
request_->url.host().c_str(), request_->url.EffectiveIntPort());
request_headers_ += "Host: " + request_->url.host();
if (request_->url.has_port())
request_headers_ += ":" + request_->url.port();
- request_headers_ += "\r\n";
+ request_headers_ += "\r\nProxy-Connection: keep-alive\r\n";
if (!request_->user_agent.empty())
request_headers_ += "User-Agent: " + request_->user_agent + "\r\n";
« no previous file with comments | « no previous file | net/http/http_network_transaction_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698