| OLD | NEW |
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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/tools/domain_security_preload_generator/spki_hash.h" | 5 #include "net/tools/transport_security_state_generator/spki_hash.h" |
| 6 | 6 |
| 7 #include <string> | 7 #include <string> |
| 8 | 8 |
| 9 #include "base/base64.h" | 9 #include "base/base64.h" |
| 10 #include "base/logging.h" | 10 #include "base/logging.h" |
| 11 #include "base/strings/string_util.h" | 11 #include "base/strings/string_util.h" |
| 12 #include "third_party/boringssl/src/include/openssl/sha.h" | 12 #include "third_party/boringssl/src/include/openssl/sha.h" |
| 13 | 13 |
| 14 namespace net { | 14 namespace net { |
| 15 | 15 |
| (...skipping 25 matching lines...) Expand all Loading... |
| 41 return true; | 41 return true; |
| 42 } | 42 } |
| 43 | 43 |
| 44 void SPKIHash::CalculateFromBytes(const uint8_t* input, size_t input_length) { | 44 void SPKIHash::CalculateFromBytes(const uint8_t* input, size_t input_length) { |
| 45 SHA256(input, input_length, data_); | 45 SHA256(input, input_length, data_); |
| 46 } | 46 } |
| 47 | 47 |
| 48 } // namespace transport_security_state | 48 } // namespace transport_security_state |
| 49 | 49 |
| 50 } // namespace net | 50 } // namespace net |
| OLD | NEW |