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

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

Issue 266243004: Clang format slam. Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 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 unified diff | Download patch | Annotate | Revision Log
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/ct_log_verifier.h" 5 #include "net/cert/ct_log_verifier.h"
6 6
7 #include "base/logging.h" 7 #include "base/logging.h"
8 #include "net/cert/ct_serialization.h" 8 #include "net/cert/ct_serialization.h"
9 9
10 namespace net { 10 namespace net {
(...skipping 26 matching lines...) Expand all
37 << ", got " << sct.signature.signature_algorithm << "."; 37 << ", got " << sct.signature.signature_algorithm << ".";
38 return false; 38 return false;
39 } 39 }
40 40
41 std::string serialized_log_entry; 41 std::string serialized_log_entry;
42 if (!ct::EncodeLogEntry(entry, &serialized_log_entry)) { 42 if (!ct::EncodeLogEntry(entry, &serialized_log_entry)) {
43 DVLOG(1) << "Unable to serialize entry."; 43 DVLOG(1) << "Unable to serialize entry.";
44 return false; 44 return false;
45 } 45 }
46 std::string serialized_data; 46 std::string serialized_data;
47 if (!ct::EncodeV1SCTSignedData(sct.timestamp, serialized_log_entry, 47 if (!ct::EncodeV1SCTSignedData(sct.timestamp,
48 sct.extensions, &serialized_data)) { 48 serialized_log_entry,
49 sct.extensions,
50 &serialized_data)) {
49 DVLOG(1) << "Unable to create SCT to verify."; 51 DVLOG(1) << "Unable to create SCT to verify.";
50 return false; 52 return false;
51 } 53 }
52 54
53 return VerifySignature(serialized_data, sct.signature.signature_data); 55 return VerifySignature(serialized_data, sct.signature.signature_data);
54 } 56 }
55 57
56 } // namespace net 58 } // namespace net
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698