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

Unified Diff: net/cert/merkle_tree_leaf.h

Issue 1945183005: Adds function for generating MerkleTreeLeaf hash. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@ct_merkle_tree_leaf_encode
Patch Set: Created 4 years, 7 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | net/cert/merkle_tree_leaf.cc » ('j') | net/cert/merkle_tree_leaf.cc » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/cert/merkle_tree_leaf.h
diff --git a/net/cert/merkle_tree_leaf.h b/net/cert/merkle_tree_leaf.h
index 2a69bc4a3a77abac4121a6f0ff39056d09ff6825..2e146c57459cf53cfb2dcbeb37e1f5e950484356 100644
--- a/net/cert/merkle_tree_leaf.h
+++ b/net/cert/merkle_tree_leaf.h
@@ -30,6 +30,10 @@ struct NET_EXPORT MerkleTreeLeaf {
MerkleTreeLeaf();
~MerkleTreeLeaf();
+ // Sets |*out| to the hash of this Merkle tree leaf, as defined in RFC6962.
+ // Returns true if the hash was generated, false if an error occurred.
+ bool Hash(std::string* out) const;
+
// Version and Merkle leaf type fields are omitted, as there is only one
// possible value for each of them in CTv1.
« no previous file with comments | « no previous file | net/cert/merkle_tree_leaf.cc » ('j') | net/cert/merkle_tree_leaf.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698