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

Side by Side Diff: net/base/x509_certificate.h

Issue 7473009: Revert r92977 partially to fix a certificate verification regression (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 9 years, 5 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 | Annotate | Revision Log
« no previous file with comments | « no previous file | net/base/x509_certificate.cc » ('j') | net/base/x509_certificate.cc » ('J')
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 #ifndef NET_BASE_X509_CERTIFICATE_H_ 5 #ifndef NET_BASE_X509_CERTIFICATE_H_
6 #define NET_BASE_X509_CERTIFICATE_H_ 6 #define NET_BASE_X509_CERTIFICATE_H_
7 #pragma once 7 #pragma once
8 8
9 #include <string.h> 9 #include <string.h>
10 10
(...skipping 275 matching lines...) Expand 10 before | Expand all | Expand 10 after
286 // by one of the given names will be included in the list. 286 // by one of the given names will be included in the list.
287 static bool GetSSLClientCertificates( 287 static bool GetSSLClientCertificates(
288 const std::string& server_domain, 288 const std::string& server_domain,
289 const std::vector<CertPrincipal>& valid_issuers, 289 const std::vector<CertPrincipal>& valid_issuers,
290 CertificateList* certs); 290 CertificateList* certs);
291 291
292 // Creates the chain of certs to use for this client identity cert. 292 // Creates the chain of certs to use for this client identity cert.
293 CFArrayRef CreateClientCertificateChain() const; 293 CFArrayRef CreateClientCertificateChain() const;
294 #endif 294 #endif
295 295
296 #if defined(OS_WIN)
297 // Returns a handle to a global, in-memory certificate store. We use it for
298 // two purposes:
299 // 1. Import server certificates into this store so that we can verify and
300 // display the certificates using CryptoAPI.
301 // 2. Copy client certificates from the "MY" system certificate store into
302 // this store so that we can close the system store when we finish
303 // searching for client certificates.
304 static HCERTSTORE cert_store();
305 #endif
306
296 #if defined(USE_OPENSSL) 307 #if defined(USE_OPENSSL)
297 // Returns a handle to a global, in-memory certificate store. We 308 // Returns a handle to a global, in-memory certificate store. We
298 // use it for test code, e.g. importing the test server's certificate. 309 // use it for test code, e.g. importing the test server's certificate.
299 static X509_STORE* cert_store(); 310 static X509_STORE* cert_store();
300 #endif 311 #endif
301 312
302 // Verifies the certificate against the given hostname. Returns OK if 313 // Verifies the certificate against the given hostname. Returns OK if
303 // successful or an error code upon failure. 314 // successful or an error code upon failure.
304 // 315 //
305 // The |*verify_result| structure, including the |verify_result->cert_status| 316 // The |*verify_result| structure, including the |verify_result->cert_status|
(...skipping 161 matching lines...) Expand 10 before | Expand all | Expand 10 after
467 // (Marked mutable because it's used in a const method.) 478 // (Marked mutable because it's used in a const method.)
468 mutable base::Lock verification_lock_; 479 mutable base::Lock verification_lock_;
469 #endif 480 #endif
470 481
471 DISALLOW_COPY_AND_ASSIGN(X509Certificate); 482 DISALLOW_COPY_AND_ASSIGN(X509Certificate);
472 }; 483 };
473 484
474 } // namespace net 485 } // namespace net
475 486
476 #endif // NET_BASE_X509_CERTIFICATE_H_ 487 #endif // NET_BASE_X509_CERTIFICATE_H_
OLDNEW
« no previous file with comments | « no previous file | net/base/x509_certificate.cc » ('j') | net/base/x509_certificate.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698