| 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_CT_TEST_UTIL_H_ | 5 #ifndef NET_CERT_CT_TEST_UTIL_H_ |
| 6 #define NET_CERT_CT_TEST_UTIL_H_ | 6 #define NET_CERT_CT_TEST_UTIL_H_ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 | 9 |
| 10 #include "base/memory/ref_counted.h" |
| 11 |
| 10 namespace net { | 12 namespace net { |
| 11 | 13 |
| 12 class X509Certificate; | |
| 13 | |
| 14 namespace ct { | 14 namespace ct { |
| 15 | 15 |
| 16 struct LogEntry; | 16 struct LogEntry; |
| 17 struct SignedCertificateTimestamp; | 17 struct SignedCertificateTimestamp; |
| 18 | 18 |
| 19 // Note: unless specified otherwise, all test data is taken from Certificate | 19 // Note: unless specified otherwise, all test data is taken from Certificate |
| 20 // Transparency test data repository. | 20 // Transparency test data repository. |
| 21 | 21 |
| 22 // Fills |entry| with test data for an X.509 entry. | 22 // Fills |entry| with test data for an X.509 entry. |
| 23 void GetX509CertLogEntry(LogEntry* entry); | 23 void GetX509CertLogEntry(LogEntry* entry); |
| (...skipping 11 matching lines...) Expand all Loading... |
| 35 // Returns the binary representation of a test serialized SCT. | 35 // Returns the binary representation of a test serialized SCT. |
| 36 std::string GetTestSignedCertificateTimestamp(); | 36 std::string GetTestSignedCertificateTimestamp(); |
| 37 | 37 |
| 38 // Test log key | 38 // Test log key |
| 39 std::string GetTestPublicKey(); | 39 std::string GetTestPublicKey(); |
| 40 | 40 |
| 41 // ID of test log key | 41 // ID of test log key |
| 42 std::string GetTestPublicKeyId(); | 42 std::string GetTestPublicKeyId(); |
| 43 | 43 |
| 44 // SCT for the X509Certificate provided above. | 44 // SCT for the X509Certificate provided above. |
| 45 void GetX509CertSCT(SignedCertificateTimestamp* sct); | 45 void GetX509CertSCT(scoped_refptr<SignedCertificateTimestamp>* sct); |
| 46 | 46 |
| 47 // SCT for the Precertificate log entry provided above. | 47 // SCT for the Precertificate log entry provided above. |
| 48 void GetPrecertSCT(SignedCertificateTimestamp* sct); | 48 void GetPrecertSCT(scoped_refptr<SignedCertificateTimestamp>* sct); |
| 49 | 49 |
| 50 // Issuer key hash | 50 // Issuer key hash |
| 51 std::string GetDefaultIssuerKeyHash(); | 51 std::string GetDefaultIssuerKeyHash(); |
| 52 | 52 |
| 53 } // namespace ct | 53 } // namespace ct |
| 54 | 54 |
| 55 } // namespace net | 55 } // namespace net |
| 56 | 56 |
| 57 #endif // NET_CERT_CT_TEST_UTIL_H_ | 57 #endif // NET_CERT_CT_TEST_UTIL_H_ |
| OLD | NEW |