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

Side by Side Diff: net/test/ct_test_util.h

Issue 1845113003: Certificate Transparency: Start tracking logs' state (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 8 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
« no previous file with comments | « net/net.gypi ('k') | net/test/ct_test_util.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 <stddef.h> 8 #include <stddef.h>
9 #include <stdint.h> 9 #include <stdint.h>
10 10
(...skipping 71 matching lines...) Expand 10 before | Expand all | Expand 10 after
82 82
83 // The SHA256 root hash for the sample STH. 83 // The SHA256 root hash for the sample STH.
84 std::string GetSampleSTHSHA256RootHash(); 84 std::string GetSampleSTHSHA256RootHash();
85 85
86 // The tree head signature for the sample STH. 86 // The tree head signature for the sample STH.
87 std::string GetSampleSTHTreeHeadSignature(); 87 std::string GetSampleSTHTreeHeadSignature();
88 88
89 // The same signature as GetSampleSTHTreeHeadSignature, decoded. 89 // The same signature as GetSampleSTHTreeHeadSignature, decoded.
90 bool GetSampleSTHTreeHeadDecodedSignature(DigitallySigned* signature); 90 bool GetSampleSTHTreeHeadDecodedSignature(DigitallySigned* signature);
91 91
92 // TODO(robpercival): The following two functions use the initialism "STH" but
93 // the rest of the functions use "SignedTreeHead".
94
95 // A sample, valid STH in SignedTreeHeadDataV1 format.
96 // See RFC 6962-bis for more information about this format.
97 std::string GetSampleSTH();
98
92 // The sample STH in JSON form. 99 // The sample STH in JSON form.
93 std::string GetSampleSTHAsJson(); 100 std::string GetSampleSTHAsJson();
94 101
95 // Assembles, and returns, a sample STH in JSON format using 102 // Assembles, and returns, a sample STH in JSON format using
96 // the provided parameters. 103 // the provided parameters.
97 std::string CreateSignedTreeHeadJsonString(size_t tree_size, 104 std::string CreateSignedTreeHeadJsonString(size_t tree_size,
98 int64_t timestamp, 105 int64_t timestamp,
99 std::string sha256_root_hash, 106 std::string sha256_root_hash,
100 std::string tree_head_signature); 107 std::string tree_head_signature);
101 108
(...skipping 16 matching lines...) Expand all
118 125
119 // Returns true if |origin| is in the |result|'s |verified_scts|. 126 // Returns true if |origin| is in the |result|'s |verified_scts|.
120 bool CheckForSCTOrigin(const CTVerifyResult& result, 127 bool CheckForSCTOrigin(const CTVerifyResult& result,
121 SignedCertificateTimestamp::Origin origin); 128 SignedCertificateTimestamp::Origin origin);
122 129
123 } // namespace ct 130 } // namespace ct
124 131
125 } // namespace net 132 } // namespace net
126 133
127 #endif // NET_CERT_CT_TEST_UTIL_H_ 134 #endif // NET_CERT_CT_TEST_UTIL_H_
OLDNEW
« no previous file with comments | « net/net.gypi ('k') | net/test/ct_test_util.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698