| OLD | NEW |
| 1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2006-2008 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 266 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 277 static OSCertHandle DupOSCertHandle(OSCertHandle cert_handle); | 277 static OSCertHandle DupOSCertHandle(OSCertHandle cert_handle); |
| 278 | 278 |
| 279 // Frees (or releases a reference to) an OS certificate handle. | 279 // Frees (or releases a reference to) an OS certificate handle. |
| 280 static void FreeOSCertHandle(OSCertHandle cert_handle); | 280 static void FreeOSCertHandle(OSCertHandle cert_handle); |
| 281 | 281 |
| 282 private: | 282 private: |
| 283 friend class base::RefCountedThreadSafe<X509Certificate>; | 283 friend class base::RefCountedThreadSafe<X509Certificate>; |
| 284 FRIEND_TEST_ALL_PREFIXES(X509CertificateTest, Cache); | 284 FRIEND_TEST_ALL_PREFIXES(X509CertificateTest, Cache); |
| 285 FRIEND_TEST_ALL_PREFIXES(X509CertificateTest, IntermediateCertificates); | 285 FRIEND_TEST_ALL_PREFIXES(X509CertificateTest, IntermediateCertificates); |
| 286 | 286 |
| 287 class Cache; | |
| 288 | |
| 289 // Construct an X509Certificate from a handle to the certificate object | 287 // Construct an X509Certificate from a handle to the certificate object |
| 290 // in the underlying crypto library. | 288 // in the underlying crypto library. |
| 291 X509Certificate(OSCertHandle cert_handle, Source source, | 289 X509Certificate(OSCertHandle cert_handle, Source source, |
| 292 const OSCertHandles& intermediates); | 290 const OSCertHandles& intermediates); |
| 293 | 291 |
| 294 ~X509Certificate(); | 292 ~X509Certificate(); |
| 295 | 293 |
| 296 // Common object initialization code. Called by the constructors only. | 294 // Common object initialization code. Called by the constructors only. |
| 297 void Initialize(); | 295 void Initialize(); |
| 298 | 296 |
| (...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 336 | 334 |
| 337 // Where the certificate comes from. | 335 // Where the certificate comes from. |
| 338 Source source_; | 336 Source source_; |
| 339 | 337 |
| 340 DISALLOW_COPY_AND_ASSIGN(X509Certificate); | 338 DISALLOW_COPY_AND_ASSIGN(X509Certificate); |
| 341 }; | 339 }; |
| 342 | 340 |
| 343 } // namespace net | 341 } // namespace net |
| 344 | 342 |
| 345 #endif // NET_BASE_X509_CERTIFICATE_H_ | 343 #endif // NET_BASE_X509_CERTIFICATE_H_ |
| OLD | NEW |