summaryrefslogtreecommitdiffstats
path: root/net/url_request
diff options
context:
space:
mode:
authorabarth@chromium.org <abarth@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-02-27 07:28:08 +0000
committerabarth@chromium.org <abarth@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-02-27 07:28:08 +0000
commitc744cf276b917e0d043fe32c37c32597f3f2fc86 (patch)
tree2089a4510205bb308d15b4685debe36fe1acf724 /net/url_request
parent000527f01885912581e737c880121b12fe315c30 (diff)
downloadchromium_src-c744cf276b917e0d043fe32c37c32597f3f2fc86.zip
chromium_src-c744cf276b917e0d043fe32c37c32597f3f2fc86.tar.gz
chromium_src-c744cf276b917e0d043fe32c37c32597f3f2fc86.tar.bz2
Don't let an active network attacker play tricks with CONNECT tunnels throgh proxy servers.
R=darin,wtc,eroman BUG=7338 Review URL: http://codereview.chromium.org/27198 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@10595 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'net/url_request')
-rw-r--r--net/url_request/url_request_unittest.cc7
1 files changed, 3 insertions, 4 deletions
diff --git a/net/url_request/url_request_unittest.cc b/net/url_request/url_request_unittest.cc
index f2028f13..c8e2896 100644
--- a/net/url_request/url_request_unittest.cc
+++ b/net/url_request/url_request_unittest.cc
@@ -103,9 +103,8 @@ TEST_F(URLRequestTest, ProxyTunnelRedirectTest) {
MessageLoop::current()->Run();
- EXPECT_EQ(URLRequestStatus::SUCCESS, r.status().status());
- // We should have rewritten the 302 response code as 500.
- EXPECT_EQ(500, r.GetResponseCode());
+ EXPECT_EQ(URLRequestStatus::FAILED, r.status().status());
+ EXPECT_EQ(net::ERR_TUNNEL_CONNECTION_FAILED, r.status().os_error());
EXPECT_EQ(1, d.response_started_count());
// We should not have followed the redirect.
EXPECT_EQ(0, d.received_redirect_count());
@@ -132,7 +131,7 @@ TEST_F(URLRequestTest, UnexpectedServerAuthTest) {
MessageLoop::current()->Run();
EXPECT_EQ(URLRequestStatus::FAILED, r.status().status());
- EXPECT_EQ(net::ERR_UNEXPECTED_SERVER_AUTH, r.status().os_error());
+ EXPECT_EQ(net::ERR_TUNNEL_CONNECTION_FAILED, r.status().os_error());
}
}