OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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_SIGNED_CERTIFICATE_TIMESTAMP_H_ | 5 #ifndef NET_CERT_SIGNED_CERTIFICATE_TIMESTAMP_H_ |
6 #define NET_CERT_SIGNED_CERTIFICATE_TIMESTAMP_H_ | 6 #define NET_CERT_SIGNED_CERTIFICATE_TIMESTAMP_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 #include <vector> | 9 #include <vector> |
10 | 10 |
11 #include "base/memory/ref_counted.h" | 11 #include "base/memory/ref_counted.h" |
12 #include "base/time/time.h" | 12 #include "base/time/time.h" |
13 #include "net/base/hash_value.h" | 13 #include "net/base/hash_value.h" |
14 #include "net/base/net_export.h" | 14 #include "net/base/net_export.h" |
15 | 15 |
16 class Pickle; | 16 class Pickle; |
17 class PickleIterator; | 17 class PickleIterator; |
18 | 18 |
19 namespace net { | 19 namespace net { |
20 | 20 |
21 // Structures related to Certificate Transparency (RFC6962). | 21 // Structures related to Certificate Transparency (RFC6962). |
22 namespace ct { | 22 namespace ct { |
23 | 23 |
24 // LogEntry struct in RFC 6962, Section 3.1 | 24 // LogEntry struct in RFC 6962, Section 3.1 |
25 struct NET_EXPORT LogEntry { | 25 struct NET_EXPORT LogEntry { |
26 // LogEntryType enum in RFC 6962, Section 3.1 | 26 // LogEntryType enum in RFC 6962, Section 3.1 |
27 enum Type { | 27 enum Type { LOG_ENTRY_TYPE_X509 = 0, LOG_ENTRY_TYPE_PRECERT = 1 }; |
28 LOG_ENTRY_TYPE_X509 = 0, | |
29 LOG_ENTRY_TYPE_PRECERT = 1 | |
30 }; | |
31 | 28 |
32 LogEntry(); | 29 LogEntry(); |
33 ~LogEntry(); | 30 ~LogEntry(); |
34 void Reset(); | 31 void Reset(); |
35 | 32 |
36 Type type; | 33 Type type; |
37 | 34 |
38 // Set if type == LOG_ENTRY_TYPE_X509 | 35 // Set if type == LOG_ENTRY_TYPE_X509 |
39 std::string leaf_certificate; | 36 std::string leaf_certificate; |
40 | 37 |
(...skipping 82 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
123 ~SignedCertificateTimestamp(); | 120 ~SignedCertificateTimestamp(); |
124 | 121 |
125 DISALLOW_COPY_AND_ASSIGN(SignedCertificateTimestamp); | 122 DISALLOW_COPY_AND_ASSIGN(SignedCertificateTimestamp); |
126 }; | 123 }; |
127 | 124 |
128 } // namespace ct | 125 } // namespace ct |
129 | 126 |
130 } // namespace net | 127 } // namespace net |
131 | 128 |
132 #endif // NET_CERT_SIGNED_CERTIFICATE_TIMESTAMP_H_ | 129 #endif // NET_CERT_SIGNED_CERTIFICATE_TIMESTAMP_H_ |
OLD | NEW |