OLD | NEW |
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 #ifndef NET_CERT_X509_CERTIFICATE_H_ | 5 #ifndef NET_CERT_X509_CERTIFICATE_H_ |
6 #define NET_CERT_X509_CERTIFICATE_H_ | 6 #define NET_CERT_X509_CERTIFICATE_H_ |
7 | 7 |
8 #include <string.h> | 8 #include <string.h> |
9 | 9 |
10 #include <string> | 10 #include <string> |
(...skipping 92 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
103 // either "PKCS7" or "CERTIFICATE". | 103 // either "PKCS7" or "CERTIFICATE". |
104 FORMAT_PKCS7 = 1 << 2, | 104 FORMAT_PKCS7 = 1 << 2, |
105 | 105 |
106 // Automatically detect the format. | 106 // Automatically detect the format. |
107 FORMAT_AUTO = FORMAT_SINGLE_CERTIFICATE | FORMAT_PEM_CERT_SEQUENCE | | 107 FORMAT_AUTO = FORMAT_SINGLE_CERTIFICATE | FORMAT_PEM_CERT_SEQUENCE | |
108 FORMAT_PKCS7, | 108 FORMAT_PKCS7, |
109 }; | 109 }; |
110 | 110 |
111 // PickleType is intended for deserializing certificates that were pickled | 111 // PickleType is intended for deserializing certificates that were pickled |
112 // by previous releases as part of a net::HttpResponseInfo. | 112 // by previous releases as part of a net::HttpResponseInfo. |
113 // When serializing certificates to a new Pickle, | 113 // When serializing certificates to a new base::Pickle, |
114 // PICKLETYPE_CERTIFICATE_CHAIN_V3 is always used. | 114 // PICKLETYPE_CERTIFICATE_CHAIN_V3 is always used. |
115 enum PickleType { | 115 enum PickleType { |
116 // When reading a certificate from a Pickle, the Pickle only contains a | 116 // When reading a certificate from a Pickle, the Pickle only contains a |
117 // single certificate. | 117 // single certificate. |
118 PICKLETYPE_SINGLE_CERTIFICATE, | 118 PICKLETYPE_SINGLE_CERTIFICATE, |
119 | 119 |
120 // When reading a certificate from a Pickle, the Pickle contains the | 120 // When reading a certificate from a Pickle, the Pickle contains the |
121 // the certificate plus any certificates that were stored in | 121 // the certificate plus any certificates that were stored in |
122 // |intermediate_ca_certificates_| at the time it was serialized. | 122 // |intermediate_ca_certificates_| at the time it was serialized. |
123 // The count of certificates is stored as a size_t, which is either 32 | 123 // The count of certificates is stored as a size_t, which is either 32 |
(...skipping 395 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
519 // based on the type of the certificate. | 519 // based on the type of the certificate. |
520 std::string default_nickname_; | 520 std::string default_nickname_; |
521 #endif | 521 #endif |
522 | 522 |
523 DISALLOW_COPY_AND_ASSIGN(X509Certificate); | 523 DISALLOW_COPY_AND_ASSIGN(X509Certificate); |
524 }; | 524 }; |
525 | 525 |
526 } // namespace net | 526 } // namespace net |
527 | 527 |
528 #endif // NET_CERT_X509_CERTIFICATE_H_ | 528 #endif // NET_CERT_X509_CERTIFICATE_H_ |
OLD | NEW |