 Chromium Code Reviews
 Chromium Code Reviews Issue 9148011:
  Allow chrome to handle 407 auth challenges to CONNECT requests  (Closed) 
  Base URL: svn://svn.chromium.org/chrome/trunk/src/
    
  
    Issue 9148011:
  Allow chrome to handle 407 auth challenges to CONNECT requests  (Closed) 
  Base URL: svn://svn.chromium.org/chrome/trunk/src/| Index: net/socket/ssl_client_socket_pool_unittest.cc | 
| =================================================================== | 
| --- net/socket/ssl_client_socket_pool_unittest.cc (revision 117986) | 
| +++ net/socket/ssl_client_socket_pool_unittest.cc (working copy) | 
| @@ -2,7 +2,7 @@ | 
| // Use of this source code is governed by a BSD-style license that can be | 
| // found in the LICENSE file. | 
| -#include "net/http/http_proxy_client_socket_pool.h" | 
| +#include "net/socket/ssl_client_socket_pool.h" | 
| #include "base/callback.h" | 
| #include "base/compiler_specific.h" | 
| @@ -19,6 +19,7 @@ | 
| #include "net/base/test_completion_callback.h" | 
| #include "net/http/http_auth_handler_factory.h" | 
| #include "net/http/http_network_session.h" | 
| +#include "net/http/http_proxy_client_socket_pool.h" | 
| #include "net/http/http_request_headers.h" | 
| #include "net/http/http_response_headers.h" | 
| #include "net/http/http_server_properties_impl.h" | 
| @@ -71,7 +72,9 @@ | 
| session_->http_auth_cache(), | 
| session_->http_auth_handler_factory(), | 
| session_->spdy_session_pool(), | 
| - true)), | 
| + true, | 
| + base::Bind(&SSLClientSocketPoolTest::OnNeedsProxyAuthCallback, | 
| + base::Unretained(this)))), | 
| http_proxy_histograms_("MockHttpProxy"), | 
| http_proxy_socket_pool_( | 
| kMaxSockets, | 
| @@ -144,6 +147,13 @@ | 
| return new HttpNetworkSession(params); | 
| } | 
| + void OnNeedsProxyAuthCallback(const HttpResponseInfo& response_info, | 
| + HttpAuthController* auth_controller, | 
| + CompletionCallback cb) { | 
| + // Don't add any auth, just execute the callback. | 
| 
vandebo (ex-Chrome)
2012/01/20 20:49:29
Do you expect this to ever be run?  If not, a NOT_
 
Ryan Hamilton
2012/01/20 21:51:35
Yes, it is used in the NeedProxyAuth test.
 | 
| + cb.Run(OK); | 
| + } | 
| + | 
| MockClientSocketFactory socket_factory_; | 
| MockCachingHostResolver host_resolver_; | 
| CertVerifier cert_verifier_; |