diff options
author | rkn@chromium.org <rkn@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-07-21 16:55:17 +0000 |
---|---|---|
committer | rkn@chromium.org <rkn@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-07-21 16:55:17 +0000 |
commit | feb79bcd1b3f755b1125ba471c4e17c7b7ede66d (patch) | |
tree | 612c11cda543dbb6342d87613274a62aa08d8100 /jingle/notifier | |
parent | 6b4adc7d6f8787274a0fcf080777032521912e0c (diff) | |
download | chromium_src-feb79bcd1b3f755b1125ba471c4e17c7b7ede66d.zip chromium_src-feb79bcd1b3f755b1125ba471c4e17c7b7ede66d.tar.gz chromium_src-feb79bcd1b3f755b1125ba471c4e17c7b7ede66d.tar.bz2 |
Added an OriginBoundCertStore field to the SSLClientSocketNSS class and
did the plumbing to pass this field through the layers. In addition,
this CL groups several fields together into a single struct |SSLClientSocket::Context|.
BUG=None
TEST=None
Review URL: http://codereview.chromium.org/7315009
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@93416 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'jingle/notifier')
-rw-r--r-- | jingle/notifier/base/chrome_async_socket_unittest.cc | 6 | ||||
-rw-r--r-- | jingle/notifier/base/proxy_resolving_client_socket.cc | 2 | ||||
-rw-r--r-- | jingle/notifier/base/xmpp_client_socket_factory.cc | 9 |
3 files changed, 13 insertions, 4 deletions
diff --git a/jingle/notifier/base/chrome_async_socket_unittest.cc b/jingle/notifier/base/chrome_async_socket_unittest.cc index 6e4199d..e9ce73c 100644 --- a/jingle/notifier/base/chrome_async_socket_unittest.cc +++ b/jingle/notifier/base/chrome_async_socket_unittest.cc @@ -22,6 +22,7 @@ #include "net/base/net_errors.h" #include "net/base/ssl_config_service.h" #include "net/socket/socket_test_util.h" +#include "net/socket/ssl_client_socket.h" #include "net/url_request/url_request_context_getter.h" #include "talk/base/sigslot.h" #include "talk/base/socketaddress.h" @@ -137,9 +138,10 @@ class MockXmppClientSocketFactory : public ResolvingClientSocketFactory { virtual net::SSLClientSocket* CreateSSLClientSocket( net::ClientSocketHandle* transport_socket, const net::HostPortPair& host_and_port) { + net::SSLClientSocketContext context; + context.cert_verifier = &cert_verifier_; return mock_client_socket_factory_->CreateSSLClientSocket( - transport_socket, host_and_port, ssl_config_, NULL, &cert_verifier_, - NULL); + transport_socket, host_and_port, ssl_config_, NULL, context); } private: diff --git a/jingle/notifier/base/proxy_resolving_client_socket.cc b/jingle/notifier/base/proxy_resolving_client_socket.cc index 4deda20..45d0c11 100644 --- a/jingle/notifier/base/proxy_resolving_client_socket.cc +++ b/jingle/notifier/base/proxy_resolving_client_socket.cc @@ -45,6 +45,8 @@ ProxyResolvingClientSocket::ProxyResolvingClientSocket( session_params.client_socket_factory = NULL; session_params.host_resolver = request_context->host_resolver(); session_params.cert_verifier = request_context->cert_verifier(); + // TODO(rkn): This is NULL because OriginBoundCertService is not thread safe. + session_params.origin_bound_cert_service = NULL; session_params.dnsrr_resolver = request_context->dnsrr_resolver(); session_params.dns_cert_checker = request_context->dns_cert_checker(); session_params.proxy_service = request_context->proxy_service(); diff --git a/jingle/notifier/base/xmpp_client_socket_factory.cc b/jingle/notifier/base/xmpp_client_socket_factory.cc index 0a0bb52..7475bc1 100644 --- a/jingle/notifier/base/xmpp_client_socket_factory.cc +++ b/jingle/notifier/base/xmpp_client_socket_factory.cc @@ -8,6 +8,7 @@ #include "jingle/notifier/base/fake_ssl_client_socket.h" #include "jingle/notifier/base/proxy_resolving_client_socket.h" #include "net/socket/client_socket_factory.h" +#include "net/socket/ssl_client_socket.h" #include "net/url_request/url_request_context.h" #include "net/url_request/url_request_context_getter.h" @@ -40,9 +41,13 @@ net::StreamSocket* XmppClientSocketFactory::CreateTransportClientSocket( net::SSLClientSocket* XmppClientSocketFactory::CreateSSLClientSocket( net::ClientSocketHandle* transport_socket, const net::HostPortPair& host_and_port) { + net::SSLClientSocketContext context; + context.cert_verifier = + request_context_getter_->GetURLRequestContext()->cert_verifier(); + // TODO(rkn): context.origin_bound_cert_service is NULL because the + // OriginBoundCertService class is not thread safe. return client_socket_factory_->CreateSSLClientSocket( - transport_socket, host_and_port, ssl_config_, NULL, - request_context_getter_->GetURLRequestContext()->cert_verifier(), NULL); + transport_socket, host_and_port, ssl_config_, NULL, context); } |