diff options
Diffstat (limited to 'net/socket/ssl_host_info.cc')
-rw-r--r-- | net/socket/ssl_host_info.cc | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/net/socket/ssl_host_info.cc b/net/socket/ssl_host_info.cc index 8c1b79f..527c2db 100644 --- a/net/socket/ssl_host_info.cc +++ b/net/socket/ssl_host_info.cc @@ -7,7 +7,6 @@ #include "base/metrics/histogram.h" #include "base/pickle.h" #include "base/string_piece.h" -#include "net/base/cert_verifier.h" #include "net/base/ssl_config_service.h" #include "net/base/x509_certificate.h" #include "net/socket/ssl_client_socket.h" @@ -29,7 +28,8 @@ void SSLHostInfo::State::Clear() { SSLHostInfo::SSLHostInfo( const std::string& hostname, - const SSLConfig& ssl_config) + const SSLConfig& ssl_config, + CertVerifier* cert_verifier) : cert_verification_complete_(false), cert_verification_error_(ERR_CERT_INVALID), hostname_(hostname), @@ -37,6 +37,7 @@ SSLHostInfo::SSLHostInfo( cert_verification_callback_(NULL), rev_checking_enabled_(ssl_config.rev_checking_enabled), verify_ev_cert_(ssl_config.verify_ev_cert), + verifier_(cert_verifier), callback_(new CancelableCompletionCallback<SSLHostInfo>( ALLOW_THIS_IN_INITIALIZER_LIST(this), &SSLHostInfo::VerifyCallback)) { @@ -110,12 +111,11 @@ bool SSLHostInfo::ParseInner(const std::string& data) { flags |= X509Certificate::VERIFY_EV_CERT; if (rev_checking_enabled_) flags |= X509Certificate::VERIFY_REV_CHECKING_ENABLED; - verifier_.reset(new CertVerifier); VLOG(1) << "Kicking off verification for " << hostname_; verification_start_time_ = base::TimeTicks::Now(); verification_end_time_ = base::TimeTicks(); - if (verifier_->Verify(cert_.get(), hostname_, flags, - &cert_verify_result_, callback_) == OK) { + if (verifier_.Verify(cert_.get(), hostname_, flags, + &cert_verify_result_, callback_) == OK) { VerifyCallback(OK); } } else { |