diff options
Diffstat (limited to 'net')
-rw-r--r-- | net/base/ssl_cert_request_info.cc | 5 | ||||
-rw-r--r-- | net/base/ssl_cert_request_info.h | 4 | ||||
-rw-r--r-- | net/http/http_network_transaction.cc | 41 | ||||
-rw-r--r-- | net/http/http_network_transaction.h | 3 | ||||
-rw-r--r-- | net/http/http_proxy_client_socket_pool.cc | 2 | ||||
-rw-r--r-- | net/http/http_stream_factory.h | 6 | ||||
-rw-r--r-- | net/http/http_stream_factory_impl.cc | 20 | ||||
-rw-r--r-- | net/http/http_stream_factory_impl.h | 6 | ||||
-rw-r--r-- | net/http/http_stream_factory_impl_job.cc | 48 | ||||
-rw-r--r-- | net/http/http_stream_factory_impl_job.h | 9 | ||||
-rw-r--r-- | net/http/http_stream_factory_impl_request.cc | 4 | ||||
-rw-r--r-- | net/http/http_stream_factory_impl_unittest.cc | 5 | ||||
-rw-r--r-- | net/spdy/spdy_network_transaction_unittest.cc | 2 |
13 files changed, 95 insertions, 60 deletions
diff --git a/net/base/ssl_cert_request_info.cc b/net/base/ssl_cert_request_info.cc index b7728e5..dd43340 100644 --- a/net/base/ssl_cert_request_info.cc +++ b/net/base/ssl_cert_request_info.cc @@ -1,4 +1,4 @@ -// Copyright (c) 2010 The Chromium Authors. All rights reserved. +// Copyright (c) 2011 The Chromium Authors. All rights reserved. // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. @@ -8,12 +8,13 @@ namespace net { -SSLCertRequestInfo::SSLCertRequestInfo() { +SSLCertRequestInfo::SSLCertRequestInfo() : is_proxy(false) { } void SSLCertRequestInfo::Reset() { host_and_port.clear(); client_certs.clear(); + is_proxy = false; } SSLCertRequestInfo::~SSLCertRequestInfo() { diff --git a/net/base/ssl_cert_request_info.h b/net/base/ssl_cert_request_info.h index 1593160..ffce13f 100644 --- a/net/base/ssl_cert_request_info.h +++ b/net/base/ssl_cert_request_info.h @@ -28,6 +28,10 @@ class NET_EXPORT SSLCertRequestInfo // The host and port of the SSL server that requested client authentication. std::string host_and_port; + // True if the server that issues this request was the HTTPS proxy used in + // the request. False, if the server was the origin server. + bool is_proxy; + // A list of client certificates that match the server's criteria in the // SSL CertificateRequest message. In TLS 1.0, the CertificateRequest // message is defined as: diff --git a/net/http/http_network_transaction.cc b/net/http/http_network_transaction.cc index f8e362f..d1e7ec5 100644 --- a/net/http/http_network_transaction.cc +++ b/net/http/http_network_transaction.cc @@ -107,9 +107,11 @@ HttpNetworkTransaction::HttpNetworkTransaction(HttpNetworkSession* session) read_buf_len_(0), next_state_(STATE_NONE), establishing_tunnel_(false) { - session->ssl_config_service()->GetSSLConfig(&ssl_config_); - if (session->http_stream_factory()->next_protos()) - ssl_config_.next_protos = *session->http_stream_factory()->next_protos(); + session->ssl_config_service()->GetSSLConfig(&server_ssl_config_); + if (session->http_stream_factory()->next_protos()) { + server_ssl_config_.next_protos = + *session->http_stream_factory()->next_protos(); + } } HttpNetworkTransaction::~HttpNetworkTransaction() { @@ -157,7 +159,7 @@ int HttpNetworkTransaction::Start(const HttpRequestInfo* request_info, start_time_ = base::Time::Now(); if (request_->load_flags & LOAD_DISABLE_CERT_REVOCATION_CHECKING) - ssl_config_.rev_checking_enabled = false; + server_ssl_config_.rev_checking_enabled = false; next_state_ = STATE_CREATE_STREAM; int rv = DoLoop(OK); @@ -189,10 +191,12 @@ int HttpNetworkTransaction::RestartWithCertificate( DCHECK(!stream_.get()); DCHECK_EQ(STATE_NONE, next_state_); - ssl_config_.client_cert = client_cert; + SSLConfig* ssl_config = response_.cert_request_info->is_proxy ? + &proxy_ssl_config_ : &server_ssl_config_; + ssl_config->send_client_cert = true; + ssl_config->client_cert = client_cert; session_->ssl_client_auth_cache()->Add( response_.cert_request_info->host_and_port, client_cert); - ssl_config_.send_client_cert = true; // Reset the other member variables. // Note: this is necessary only with SSL renegotiation. ResetStateForRestart(); @@ -375,7 +379,7 @@ void HttpNetworkTransaction::OnStreamReady(const SSLConfig& used_ssl_config, DCHECK(stream_request_.get()); stream_.reset(stream); - ssl_config_ = used_ssl_config; + server_ssl_config_ = used_ssl_config; proxy_info_ = used_proxy_info; response_.was_npn_negotiated = stream_request_->was_npn_negotiated(); response_.was_fetched_via_spdy = stream_request_->using_spdy(); @@ -390,7 +394,7 @@ void HttpNetworkTransaction::OnStreamFailed(int result, DCHECK_NE(OK, result); DCHECK(stream_request_.get()); DCHECK(!stream_.get()); - ssl_config_ = used_ssl_config; + server_ssl_config_ = used_ssl_config; OnIOComplete(result); } @@ -405,7 +409,7 @@ void HttpNetworkTransaction::OnCertificateError( DCHECK(!stream_.get()); response_.ssl_info = ssl_info; - ssl_config_ = used_ssl_config; + server_ssl_config_ = used_ssl_config; // TODO(mbelshe): For now, we're going to pass the error through, and that // will close the stream_request in all cases. This means that we're always @@ -428,7 +432,7 @@ void HttpNetworkTransaction::OnNeedsProxyAuth( response_.headers = proxy_response.headers; response_.auth_challenge = proxy_response.auth_challenge; headers_valid_ = true; - ssl_config_ = used_ssl_config; + server_ssl_config_ = used_ssl_config; proxy_info_ = used_proxy_info; auth_controllers_[HttpAuth::AUTH_PROXY] = auth_controller; @@ -442,7 +446,7 @@ void HttpNetworkTransaction::OnNeedsClientAuth( SSLCertRequestInfo* cert_info) { DCHECK_EQ(STATE_CREATE_STREAM_COMPLETE, next_state_); - ssl_config_ = used_ssl_config; + server_ssl_config_ = used_ssl_config; response_.cert_request_info = cert_info; OnIOComplete(ERR_SSL_CLIENT_AUTH_CERT_NEEDED); } @@ -456,7 +460,7 @@ void HttpNetworkTransaction::OnHttpsProxyTunnelResponse( headers_valid_ = true; response_ = response_info; - ssl_config_ = used_ssl_config; + server_ssl_config_ = used_ssl_config; proxy_info_ = used_proxy_info; stream_.reset(stream); stream_request_.reset(); // we're done with the stream request @@ -583,7 +587,8 @@ int HttpNetworkTransaction::DoCreateStream() { stream_request_.reset( session_->http_stream_factory()->RequestStream( *request_, - ssl_config_, + server_ssl_config_, + proxy_ssl_config_, this, net_log_)); DCHECK(stream_request_.get()); @@ -1124,8 +1129,10 @@ int HttpNetworkTransaction::HandleCertificateRequest(int error) { // TODO(davidben): Add a unit test which covers this path; we need to be // able to send a legitimate certificate and also bypass/clear the // SSL session cache. - ssl_config_.client_cert = client_cert; - ssl_config_.send_client_cert = true; + SSLConfig* ssl_config = response_.cert_request_info->is_proxy ? + &proxy_ssl_config_ : &server_ssl_config_; + ssl_config->send_client_cert = true; + ssl_config->client_cert = client_cert; next_state_ = STATE_CREATE_STREAM; // Reset the other member variables. // Note: this is necessary only with SSL renegotiation. @@ -1139,7 +1146,7 @@ int HttpNetworkTransaction::HandleCertificateRequest(int error) { // generated by the SSL proxy. http://crbug.com/69329 int HttpNetworkTransaction::HandleSSLHandshakeError(int error) { DCHECK(request_); - if (ssl_config_.send_client_cert && + if (server_ssl_config_.send_client_cert && (error == ERR_SSL_PROTOCOL_ERROR || IsClientCertificateError(error))) { session_->ssl_client_auth_cache()->Remove( GetHostAndPort(request_->url)); @@ -1150,7 +1157,7 @@ int HttpNetworkTransaction::HandleSSLHandshakeError(int error) { case ERR_SSL_VERSION_OR_CIPHER_MISMATCH: case ERR_SSL_DECOMPRESSION_FAILURE_ALERT: case ERR_SSL_BAD_RECORD_MAC_ALERT: - if (ssl_config_.tls1_enabled) { + if (server_ssl_config_.tls1_enabled) { // This could be a TLS-intolerant server, an SSL 3.0 server that // chose a TLS-only cipher suite or a server with buggy DEFLATE // support. Turn off TLS 1.0, DEFLATE support and retry. diff --git a/net/http/http_network_transaction.h b/net/http/http_network_transaction.h index 639d17d..c450bcb 100644 --- a/net/http/http_network_transaction.h +++ b/net/http/http_network_transaction.h @@ -248,7 +248,8 @@ class NET_EXPORT_PRIVATE HttpNetworkTransaction // responses. bool logged_response_time_; - SSLConfig ssl_config_; + SSLConfig server_ssl_config_; + SSLConfig proxy_ssl_config_; HttpRequestHeaders request_headers_; diff --git a/net/http/http_proxy_client_socket_pool.cc b/net/http/http_proxy_client_socket_pool.cc index eb90b53..69af61f 100644 --- a/net/http/http_proxy_client_socket_pool.cc +++ b/net/http/http_proxy_client_socket_pool.cc @@ -11,6 +11,7 @@ #include "googleurl/src/gurl.h" #include "net/base/load_flags.h" #include "net/base/net_errors.h" +#include "net/base/ssl_cert_request_info.h" #include "net/http/http_network_session.h" #include "net/http/http_proxy_client_socket.h" #include "net/socket/client_socket_factory.h" @@ -214,6 +215,7 @@ int HttpProxyConnectJob::DoSSLConnectComplete(int result) { if (result == ERR_SSL_CLIENT_AUTH_CERT_NEEDED) { error_response_info_ = transport_socket_handle_->ssl_error_response_info(); DCHECK(error_response_info_.cert_request_info.get()); + error_response_info_.cert_request_info->is_proxy = true; return result; } if (IsCertificateError(result)) { diff --git a/net/http/http_stream_factory.h b/net/http/http_stream_factory.h index 097915e..66c0a23 100644 --- a/net/http/http_stream_factory.h +++ b/net/http/http_stream_factory.h @@ -159,14 +159,16 @@ class NET_EXPORT HttpStreamFactory { // Will callback to the HttpStreamRequestDelegate upon completion. virtual HttpStreamRequest* RequestStream( const HttpRequestInfo& info, - const SSLConfig& ssl_config, + const SSLConfig& server_ssl_config, + const SSLConfig& proxy_ssl_config, HttpStreamRequest::Delegate* delegate, const BoundNetLog& net_log) = 0; // Requests that enough connections for |num_streams| be opened. virtual void PreconnectStreams(int num_streams, const HttpRequestInfo& info, - const SSLConfig& ssl_config, + const SSLConfig& server_ssl_config, + const SSLConfig& proxy_ssl_config, const BoundNetLog& net_log) = 0; virtual void AddTLSIntolerantServer(const HostPortPair& server) = 0; diff --git a/net/http/http_stream_factory_impl.cc b/net/http/http_stream_factory_impl.cc index dacc2fb..ebb0ec7 100644 --- a/net/http/http_stream_factory_impl.cc +++ b/net/http/http_stream_factory_impl.cc @@ -1,4 +1,4 @@ -// Copyright (c) 2010 The Chromium Authors. All rights reserved. +// Copyright (c) 2011 The Chromium Authors. All rights reserved. // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. @@ -51,7 +51,8 @@ HttpStreamFactoryImpl::~HttpStreamFactoryImpl() { HttpStreamRequest* HttpStreamFactoryImpl::RequestStream( const HttpRequestInfo& request_info, - const SSLConfig& ssl_config, + const SSLConfig& server_ssl_config, + const SSLConfig& proxy_ssl_config, HttpStreamRequest::Delegate* delegate, const BoundNetLog& net_log) { Request* request = new Request(request_info.url, this, delegate, net_log); @@ -64,12 +65,14 @@ HttpStreamRequest* HttpStreamFactoryImpl::RequestStream( HttpRequestInfo alternate_request_info = request_info; alternate_request_info.url = alternate_url; alternate_job = - new Job(this, session_, alternate_request_info, ssl_config, net_log); + new Job(this, session_, alternate_request_info, server_ssl_config, + proxy_ssl_config, net_log); request->AttachJob(alternate_job); alternate_job->MarkAsAlternate(request_info.url); } - Job* job = new Job(this, session_, request_info, ssl_config, net_log); + Job* job = new Job(this, session_, request_info, server_ssl_config, + proxy_ssl_config, net_log); request->AttachJob(job); if (alternate_job) { job->WaitFor(alternate_job); @@ -88,7 +91,8 @@ HttpStreamRequest* HttpStreamFactoryImpl::RequestStream( void HttpStreamFactoryImpl::PreconnectStreams( int num_streams, const HttpRequestInfo& request_info, - const SSLConfig& ssl_config, + const SSLConfig& server_ssl_config, + const SSLConfig& proxy_ssl_config, const BoundNetLog& net_log) { GURL alternate_url; bool has_alternate_protocol = @@ -97,10 +101,12 @@ void HttpStreamFactoryImpl::PreconnectStreams( if (has_alternate_protocol) { HttpRequestInfo alternate_request_info = request_info; alternate_request_info.url = alternate_url; - job = new Job(this, session_, alternate_request_info, ssl_config, net_log); + job = new Job(this, session_, alternate_request_info, server_ssl_config, + proxy_ssl_config, net_log); job->MarkAsAlternate(request_info.url); } else { - job = new Job(this, session_, request_info, ssl_config, net_log); + job = new Job(this, session_, request_info, server_ssl_config, + proxy_ssl_config, net_log); } preconnect_job_set_.insert(job); job->Preconnect(num_streams); diff --git a/net/http/http_stream_factory_impl.h b/net/http/http_stream_factory_impl.h index 4a46181..b84f158 100644 --- a/net/http/http_stream_factory_impl.h +++ b/net/http/http_stream_factory_impl.h @@ -27,13 +27,15 @@ class NET_EXPORT_PRIVATE HttpStreamFactoryImpl : public HttpStreamFactory { // HttpStreamFactory Interface virtual HttpStreamRequest* RequestStream( const HttpRequestInfo& info, - const SSLConfig& ssl_config, + const SSLConfig& server_ssl_config, + const SSLConfig& proxy_ssl_config, HttpStreamRequest::Delegate* delegate, const BoundNetLog& net_log); virtual void PreconnectStreams(int num_streams, const HttpRequestInfo& info, - const SSLConfig& ssl_config, + const SSLConfig& server_ssl_config, + const SSLConfig& proxy_ssl_config, const BoundNetLog& net_log); virtual void AddTLSIntolerantServer(const HostPortPair& server); virtual bool IsTLSIntolerantServer(const HostPortPair& server) const; diff --git a/net/http/http_stream_factory_impl_job.cc b/net/http/http_stream_factory_impl_job.cc index 2a0d91c..b55d1ac 100644 --- a/net/http/http_stream_factory_impl_job.cc +++ b/net/http/http_stream_factory_impl_job.cc @@ -61,11 +61,13 @@ Value* HttpStreamJobParameters::ToValue() const { HttpStreamFactoryImpl::Job::Job(HttpStreamFactoryImpl* stream_factory, HttpNetworkSession* session, const HttpRequestInfo& request_info, - const SSLConfig& ssl_config, + const SSLConfig& server_ssl_config, + const SSLConfig& proxy_ssl_config, const BoundNetLog& net_log) : request_(NULL), request_info_(request_info), - ssl_config_(ssl_config), + server_ssl_config_(server_ssl_config), + proxy_ssl_config_(proxy_ssl_config), net_log_(BoundNetLog::Make(net_log.net_log(), NetLog::SOURCE_HTTP_STREAM_JOB)), ALLOW_THIS_IN_INITIALIZER_LIST(io_callback_(this, &Job::OnIOComplete)), @@ -191,8 +193,12 @@ bool HttpStreamFactoryImpl::Job::using_spdy() const { return using_spdy_; } -const SSLConfig& HttpStreamFactoryImpl::Job::ssl_config() const { - return ssl_config_; +const SSLConfig& HttpStreamFactoryImpl::Job::server_ssl_config() const { + return server_ssl_config_; +} + +const SSLConfig& HttpStreamFactoryImpl::Job::proxy_ssl_config() const { + return proxy_ssl_config_; } const ProxyInfo& HttpStreamFactoryImpl::Job::proxy_info() const { @@ -217,7 +223,8 @@ void HttpStreamFactoryImpl::Job::OnStreamReadyCallback() { request_->Complete(was_npn_negotiated(), using_spdy(), net_log_.source()); - request_->OnStreamReady(this, ssl_config_, proxy_info_, stream_.release()); + request_->OnStreamReady(this, server_ssl_config_, proxy_info_, + stream_.release()); } // |this| may be deleted after this call. } @@ -231,7 +238,7 @@ void HttpStreamFactoryImpl::Job::OnSpdySessionReadyCallback() { new_spdy_session_ = NULL; if (IsOrphaned()) { stream_factory_->OnSpdySessionReady( - spdy_session, spdy_session_direct_, ssl_config_, proxy_info_, + spdy_session, spdy_session_direct_, server_ssl_config_, proxy_info_, was_npn_negotiated(), using_spdy(), net_log_.source()); stream_factory_->OnOrphanedJobComplete(this); } else { @@ -245,7 +252,7 @@ void HttpStreamFactoryImpl::Job::OnStreamFailedCallback(int result) { if (IsOrphaned()) stream_factory_->OnOrphanedJobComplete(this); else - request_->OnStreamFailed(this, result, ssl_config_); + request_->OnStreamFailed(this, result, server_ssl_config_); // |this| may be deleted after this call. } @@ -255,7 +262,7 @@ void HttpStreamFactoryImpl::Job::OnCertificateErrorCallback( if (IsOrphaned()) stream_factory_->OnOrphanedJobComplete(this); else - request_->OnCertificateError(this, result, ssl_config_, ssl_info); + request_->OnCertificateError(this, result, server_ssl_config_, ssl_info); // |this| may be deleted after this call. } @@ -267,7 +274,7 @@ void HttpStreamFactoryImpl::Job::OnNeedsProxyAuthCallback( stream_factory_->OnOrphanedJobComplete(this); else request_->OnNeedsProxyAuth( - this, response, ssl_config_, proxy_info_, auth_controller); + this, response, server_ssl_config_, proxy_info_, auth_controller); // |this| may be deleted after this call. } @@ -277,7 +284,7 @@ void HttpStreamFactoryImpl::Job::OnNeedsClientAuthCallback( if (IsOrphaned()) stream_factory_->OnOrphanedJobComplete(this); else - request_->OnNeedsClientAuth(this, ssl_config_, cert_info); + request_->OnNeedsClientAuth(this, server_ssl_config_, cert_info); // |this| may be deleted after this call. } @@ -289,7 +296,7 @@ void HttpStreamFactoryImpl::Job::OnHttpsProxyTunnelResponseCallback( stream_factory_->OnOrphanedJobComplete(this); else request_->OnHttpsProxyTunnelResponse( - this, response_info, ssl_config_, proxy_info_, stream); + this, response_info, server_ssl_config_, proxy_info_, stream); // |this| may be deleted after this call. } @@ -297,7 +304,7 @@ void HttpStreamFactoryImpl::Job::OnPreconnectsComplete() { DCHECK(!request_); if (new_spdy_session_) { stream_factory_->OnSpdySessionReady( - new_spdy_session_, spdy_session_direct_, ssl_config_, + new_spdy_session_, spdy_session_direct_, server_ssl_config_, proxy_info_, was_npn_negotiated(), using_spdy(), net_log_.source()); } stream_factory_->OnPreconnectsComplete(this); @@ -595,13 +602,12 @@ int HttpStreamFactoryImpl::Job::DoInitConnection() { bool want_spdy_over_npn = original_url_.get() ? true : false; - SSLConfig ssl_config_for_proxy = ssl_config_; if (proxy_info_.is_https()) { InitSSLConfig(proxy_info_.proxy_server().host_port_pair(), - &ssl_config_for_proxy); + &proxy_ssl_config_); } if (using_ssl_) { - InitSSLConfig(origin_, &ssl_config_); + InitSSLConfig(origin_, &server_ssl_config_); } if (IsPreconnecting()) { @@ -614,8 +620,8 @@ int HttpStreamFactoryImpl::Job::DoInitConnection() { proxy_info_, ShouldForceSpdySSL(), want_spdy_over_npn, - ssl_config_, - ssl_config_for_proxy, + server_ssl_config_, + proxy_ssl_config_, net_log_, num_streams_); } else { @@ -628,8 +634,8 @@ int HttpStreamFactoryImpl::Job::DoInitConnection() { proxy_info_, ShouldForceSpdySSL(), want_spdy_over_npn, - ssl_config_, - ssl_config_for_proxy, + server_ssl_config_, + proxy_ssl_config_, net_log_, connection_.get(), &io_callback_); @@ -973,7 +979,7 @@ int HttpStreamFactoryImpl::Job::ReconsiderProxyAfterError(int error) { return error; } - if (proxy_info_.is_https() && ssl_config_.send_client_cert) { + if (proxy_info_.is_https() && proxy_ssl_config_.send_client_cert) { session_->ssl_client_auth_cache()->Remove( proxy_info_.proxy_server().host_port_pair().ToString()); } @@ -1022,7 +1028,7 @@ int HttpStreamFactoryImpl::Job::HandleCertificateError(int error) { !ssl_info_.cert->GetDEREncoded(&bad_cert.der_cert)) return error; bad_cert.cert_status = ssl_info_.cert_status; - ssl_config_.allowed_bad_certs.push_back(bad_cert); + server_ssl_config_.allowed_bad_certs.push_back(bad_cert); int load_flags = request_info_.load_flags; if (HttpStreamFactory::ignore_certificate_errors()) diff --git a/net/http/http_stream_factory_impl_job.h b/net/http/http_stream_factory_impl_job.h index ef0893d..48ef2a2 100644 --- a/net/http/http_stream_factory_impl_job.h +++ b/net/http/http_stream_factory_impl_job.h @@ -37,7 +37,8 @@ class HttpStreamFactoryImpl::Job { Job(HttpStreamFactoryImpl* stream_factory, HttpNetworkSession* session, const HttpRequestInfo& request_info, - const SSLConfig& ssl_config, + const SSLConfig& server_ssl_config, + const SSLConfig& proxy_ssl_config, const BoundNetLog& net_log); ~Job(); @@ -73,7 +74,8 @@ class HttpStreamFactoryImpl::Job { bool using_spdy() const; const BoundNetLog& net_log() const { return net_log_; } - const SSLConfig& ssl_config() const; + const SSLConfig& server_ssl_config() const; + const SSLConfig& proxy_ssl_config() const; const ProxyInfo& proxy_info() const; // Indicates whether or not this job is performing a preconnect. @@ -205,7 +207,8 @@ class HttpStreamFactoryImpl::Job { const HttpRequestInfo request_info_; ProxyInfo proxy_info_; - SSLConfig ssl_config_; + SSLConfig server_ssl_config_; + SSLConfig proxy_ssl_config_; const BoundNetLog net_log_; CompletionCallbackImpl<Job> io_callback_; diff --git a/net/http/http_stream_factory_impl_request.cc b/net/http/http_stream_factory_impl_request.cc index a97f46e..801638a 100644 --- a/net/http/http_stream_factory_impl_request.cc +++ b/net/http/http_stream_factory_impl_request.cc @@ -241,7 +241,7 @@ void HttpStreamFactoryImpl::Request::OnSpdySessionReady( } // Cache these values in case the job gets deleted. - const SSLConfig used_ssl_config = job->ssl_config(); + const SSLConfig used_ssl_config = job->server_ssl_config(); const ProxyInfo used_proxy_info = job->proxy_info(); const bool was_npn_negotiated = job->was_npn_negotiated(); const bool using_spdy = job->using_spdy(); @@ -256,7 +256,7 @@ void HttpStreamFactoryImpl::Request::OnSpdySessionReady( bool use_relative_url = direct || url().SchemeIs("https"); delegate_->OnStreamReady( - job->ssl_config(), + job->server_ssl_config(), job->proxy_info(), new SpdyHttpStream(spdy_session, use_relative_url)); // |this| may be deleted after this point. diff --git a/net/http/http_stream_factory_impl_unittest.cc b/net/http/http_stream_factory_impl_unittest.cc index 6169aa1..2d2c24a 100644 --- a/net/http/http_stream_factory_impl_unittest.cc +++ b/net/http/http_stream_factory_impl_unittest.cc @@ -176,7 +176,7 @@ void PreconnectHelper(const TestCase& test, TestCompletionCallback callback; session->http_stream_factory()->PreconnectStreams( - test.num_streams, request, ssl_config, BoundNetLog()); + test.num_streams, request, ssl_config, ssl_config, BoundNetLog()); mock_factory->WaitForPreconnects(); }; @@ -403,7 +403,8 @@ TEST(HttpStreamFactoryTest, JobNotifiesProxy) { StreamRequestWaiter waiter; scoped_ptr<HttpStreamRequest> request( session->http_stream_factory()->RequestStream(request_info, ssl_config, - &waiter, log.bound())); + ssl_config, &waiter, + log.bound())); waiter.WaitForStream(); // The proxy that failed should now be known to the proxy_service as bad. diff --git a/net/spdy/spdy_network_transaction_unittest.cc b/net/spdy/spdy_network_transaction_unittest.cc index fff263e..a41a415 100644 --- a/net/spdy/spdy_network_transaction_unittest.cc +++ b/net/spdy/spdy_network_transaction_unittest.cc @@ -857,7 +857,7 @@ TEST_P(SpdyNetworkTransactionTest, TwoGetsLateBindingFromPreconnect) { } http_stream_factory->PreconnectStreams( - 1, httpreq, preconnect_ssl_config, log); + 1, httpreq, preconnect_ssl_config, preconnect_ssl_config, log); out.rv = trans1->Start(&httpreq, &callback1, log); ASSERT_EQ(ERR_IO_PENDING, out.rv); |