Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(255)

Side by Side Diff: net/socket/ssl_client_socket_impl.cc

Issue 1994353002: Update CertVerifier::Verify to use RequestParams instead (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@request_params
Patch Set: Rebased Created 4 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « net/quic/crypto/proof_verifier_chromium_test.cc ('k') | net/tools/quic/quic_client_bin.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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_impl.h" 5 #include "net/socket/ssl_client_socket_impl.h"
6 6
7 #include <errno.h> 7 #include <errno.h>
8 #include <openssl/bio.h> 8 #include <openssl/bio.h>
9 #include <openssl/bytestring.h> 9 #include <openssl/bytestring.h>
10 #include <openssl/err.h> 10 #include <openssl/err.h>
(...skipping 1301 matching lines...) Expand 10 before | Expand all | Expand 10 after
1312 const uint8_t* ocsp_response_raw; 1312 const uint8_t* ocsp_response_raw;
1313 size_t ocsp_response_len; 1313 size_t ocsp_response_len;
1314 SSL_get0_ocsp_response(ssl_, &ocsp_response_raw, &ocsp_response_len); 1314 SSL_get0_ocsp_response(ssl_, &ocsp_response_raw, &ocsp_response_len);
1315 ocsp_response.assign(reinterpret_cast<const char*>(ocsp_response_raw), 1315 ocsp_response.assign(reinterpret_cast<const char*>(ocsp_response_raw),
1316 ocsp_response_len); 1316 ocsp_response_len);
1317 } 1317 }
1318 1318
1319 start_cert_verification_time_ = base::TimeTicks::Now(); 1319 start_cert_verification_time_ = base::TimeTicks::Now();
1320 1320
1321 return cert_verifier_->Verify( 1321 return cert_verifier_->Verify(
1322 server_cert_.get(), host_and_port_.host(), ocsp_response, 1322 CertVerifier::RequestParams(server_cert_, host_and_port_.host(),
1323 ssl_config_.GetCertVerifyFlags(), 1323 ssl_config_.GetCertVerifyFlags(),
1324 ocsp_response, CertificateList()),
1324 // TODO(davidben): Route the CRLSet through SSLConfig so 1325 // TODO(davidben): Route the CRLSet through SSLConfig so
1325 // SSLClientSocket doesn't depend on SSLConfigService. 1326 // SSLClientSocket doesn't depend on SSLConfigService.
1326 SSLConfigService::GetCRLSet().get(), &server_cert_verify_result_, 1327 SSLConfigService::GetCRLSet().get(), &server_cert_verify_result_,
1327 base::Bind(&SSLClientSocketImpl::OnHandshakeIOComplete, 1328 base::Bind(&SSLClientSocketImpl::OnHandshakeIOComplete,
1328 base::Unretained(this)), 1329 base::Unretained(this)),
1329 &cert_verifier_request_, net_log_); 1330 &cert_verifier_request_, net_log_);
1330 } 1331 }
1331 1332
1332 int SSLClientSocketImpl::DoVerifyCertComplete(int result) { 1333 int SSLClientSocketImpl::DoVerifyCertComplete(int result) {
1333 cert_verifier_request_.reset(); 1334 cert_verifier_request_.reset();
(...skipping 997 matching lines...) Expand 10 before | Expand all | Expand 10 after
2331 if (rv != OK) { 2332 if (rv != OK) {
2332 net_log_.EndEventWithNetErrorCode(NetLog::TYPE_SSL_CONNECT, rv); 2333 net_log_.EndEventWithNetErrorCode(NetLog::TYPE_SSL_CONNECT, rv);
2333 return; 2334 return;
2334 } 2335 }
2335 2336
2336 net_log_.EndEvent(NetLog::TYPE_SSL_CONNECT, 2337 net_log_.EndEvent(NetLog::TYPE_SSL_CONNECT,
2337 base::Bind(&NetLogSSLInfoCallback, base::Unretained(this))); 2338 base::Bind(&NetLogSSLInfoCallback, base::Unretained(this)));
2338 } 2339 }
2339 2340
2340 } // namespace net 2341 } // namespace net
OLDNEW
« no previous file with comments | « net/quic/crypto/proof_verifier_chromium_test.cc ('k') | net/tools/quic/quic_client_bin.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698