| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "net/socket/ssl_client_socket_pool.h" | 5 #include "net/socket/ssl_client_socket_pool.h" |
| 6 | 6 |
| 7 #include "base/bind.h" | 7 #include "base/bind.h" |
| 8 #include "base/bind_helpers.h" | 8 #include "base/bind_helpers.h" |
| 9 #include "base/metrics/field_trial.h" | 9 #include "base/metrics/field_trial.h" |
| 10 #include "base/metrics/histogram.h" | 10 #include "base/metrics/histogram.h" |
| (...skipping 240 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 251 | 251 |
| 252 int SSLConnectJob::DoTunnelConnectComplete(int result) { | 252 int SSLConnectJob::DoTunnelConnectComplete(int result) { |
| 253 // Extract the information needed to prompt for appropriate proxy | 253 // Extract the information needed to prompt for appropriate proxy |
| 254 // authentication so that when ClientSocketPoolBaseHelper calls | 254 // authentication so that when ClientSocketPoolBaseHelper calls |
| 255 // |GetAdditionalErrorState|, we can easily set the state. | 255 // |GetAdditionalErrorState|, we can easily set the state. |
| 256 if (result == ERR_SSL_CLIENT_AUTH_CERT_NEEDED) { | 256 if (result == ERR_SSL_CLIENT_AUTH_CERT_NEEDED) { |
| 257 error_response_info_ = transport_socket_handle_->ssl_error_response_info(); | 257 error_response_info_ = transport_socket_handle_->ssl_error_response_info(); |
| 258 } else if (result == ERR_PROXY_AUTH_REQUESTED || | 258 } else if (result == ERR_PROXY_AUTH_REQUESTED || |
| 259 result == ERR_HTTPS_PROXY_TUNNEL_RESPONSE) { | 259 result == ERR_HTTPS_PROXY_TUNNEL_RESPONSE) { |
| 260 StreamSocket* socket = transport_socket_handle_->socket(); | 260 StreamSocket* socket = transport_socket_handle_->socket(); |
| 261 HttpProxyClientSocket* tunnel_socket = | 261 ProxyClientSocket* tunnel_socket = |
| 262 static_cast<HttpProxyClientSocket*>(socket); | 262 static_cast<ProxyClientSocket*>(socket); |
| 263 error_response_info_ = *tunnel_socket->GetConnectResponseInfo(); | 263 error_response_info_ = *tunnel_socket->GetConnectResponseInfo(); |
| 264 } | 264 } |
| 265 if (result < 0) | 265 if (result < 0) |
| 266 return result; | 266 return result; |
| 267 | 267 |
| 268 next_state_ = STATE_SSL_CONNECT; | 268 next_state_ = STATE_SSL_CONNECT; |
| 269 return result; | 269 return result; |
| 270 } | 270 } |
| 271 | 271 |
| 272 int SSLConnectJob::DoSSLConnect() { | 272 int SSLConnectJob::DoSSLConnect() { |
| (...skipping 311 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 584 | 584 |
| 585 ClientSocketPoolHistograms* SSLClientSocketPool::histograms() const { | 585 ClientSocketPoolHistograms* SSLClientSocketPool::histograms() const { |
| 586 return base_.histograms(); | 586 return base_.histograms(); |
| 587 } | 587 } |
| 588 | 588 |
| 589 void SSLClientSocketPool::OnSSLConfigChanged() { | 589 void SSLClientSocketPool::OnSSLConfigChanged() { |
| 590 Flush(); | 590 Flush(); |
| 591 } | 591 } |
| 592 | 592 |
| 593 } // namespace net | 593 } // namespace net |
| OLD | NEW |