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

Side by Side Diff: net/cert/signed_certificate_timestamp.cc

Issue 2824983002: Rename net::ct::LogEntry to SignedEntryData and clarify the comment. (Closed)
Patch Set: sort forward decls Created 3 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/cert/signed_certificate_timestamp.h ('k') | net/test/ct_test_util.h » ('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 #include "net/cert/signed_certificate_timestamp.h" 5 #include "net/cert/signed_certificate_timestamp.h"
6 6
7 #include "base/pickle.h" 7 #include "base/pickle.h"
8 8
9 namespace net { 9 namespace net {
10 10
(...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after
71 sct->version = static_cast<Version>(version); 71 sct->version = static_cast<Version>(version);
72 sct->timestamp = base::Time::FromInternalValue(timestamp); 72 sct->timestamp = base::Time::FromInternalValue(timestamp);
73 sct->signature.hash_algorithm = 73 sct->signature.hash_algorithm =
74 static_cast<DigitallySigned::HashAlgorithm>(hash_algorithm); 74 static_cast<DigitallySigned::HashAlgorithm>(hash_algorithm);
75 sct->signature.signature_algorithm = 75 sct->signature.signature_algorithm =
76 static_cast<DigitallySigned::SignatureAlgorithm>(sig_algorithm); 76 static_cast<DigitallySigned::SignatureAlgorithm>(sig_algorithm);
77 sct->origin = static_cast<Origin>(origin); 77 sct->origin = static_cast<Origin>(origin);
78 return sct; 78 return sct;
79 } 79 }
80 80
81 LogEntry::LogEntry() : type(LOG_ENTRY_TYPE_X509) {} 81 SignedEntryData::SignedEntryData() : type(LOG_ENTRY_TYPE_X509) {}
82 82
83 LogEntry::~LogEntry() {} 83 SignedEntryData::~SignedEntryData() {}
84 84
85 void LogEntry::Reset() { 85 void SignedEntryData::Reset() {
86 type = LogEntry::LOG_ENTRY_TYPE_X509; 86 type = SignedEntryData::LOG_ENTRY_TYPE_X509;
87 leaf_certificate.clear(); 87 leaf_certificate.clear();
88 tbs_certificate.clear(); 88 tbs_certificate.clear();
89 } 89 }
90 90
91 DigitallySigned::DigitallySigned() 91 DigitallySigned::DigitallySigned()
92 : hash_algorithm(HASH_ALGO_NONE), signature_algorithm(SIG_ALGO_ANONYMOUS) {} 92 : hash_algorithm(HASH_ALGO_NONE), signature_algorithm(SIG_ALGO_ANONYMOUS) {}
93 93
94 DigitallySigned::~DigitallySigned() {} 94 DigitallySigned::~DigitallySigned() {}
95 95
96 bool DigitallySigned::SignatureParametersMatch( 96 bool DigitallySigned::SignatureParametersMatch(
97 HashAlgorithm other_hash_algorithm, 97 HashAlgorithm other_hash_algorithm,
98 SignatureAlgorithm other_signature_algorithm) const { 98 SignatureAlgorithm other_signature_algorithm) const {
99 return (hash_algorithm == other_hash_algorithm) && 99 return (hash_algorithm == other_hash_algorithm) &&
100 (signature_algorithm == other_signature_algorithm); 100 (signature_algorithm == other_signature_algorithm);
101 } 101 }
102 } // namespace ct 102 } // namespace ct
103 103
104 } // namespace net 104 } // namespace net
OLDNEW
« no previous file with comments | « net/cert/signed_certificate_timestamp.h ('k') | net/test/ct_test_util.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698