| OLD | NEW |
| 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/quic/test_tools/crypto_test_utils.h" | 5 #include "net/quic/test_tools/crypto_test_utils.h" |
| 6 | 6 |
| 7 #include <openssl/bn.h> | 7 #include <openssl/bn.h> |
| 8 #include <openssl/ec.h> | 8 #include <openssl/ec.h> |
| 9 #include <openssl/ecdsa.h> | 9 #include <openssl/ecdsa.h> |
| 10 #include <openssl/evp.h> | 10 #include <openssl/evp.h> |
| 11 #include <openssl/obj_mac.h> | 11 #include <openssl/obj_mac.h> |
| 12 #include <openssl/sha.h> | 12 #include <openssl/sha.h> |
| 13 | 13 |
| 14 #include "crypto/openssl_util.h" | 14 #include "crypto/openssl_util.h" |
| 15 #include "crypto/secure_hash.h" | 15 #include "crypto/secure_hash.h" |
| 16 #include "net/quic/crypto/channel_id.h" | 16 #include "net/quic/crypto/channel_id.h" |
| 17 | 17 |
| 18 using base::StringPiece; | 18 using base::StringPiece; |
| 19 using std::string; | 19 using std::string; |
| 20 | 20 |
| 21 namespace { | 21 namespace { |
| 22 | 22 |
| 23 void EvpMdCtxCleanUp(EVP_MD_CTX *ctx) { | 23 void EvpMdCtxCleanUp(EVP_MD_CTX* ctx) { |
| 24 (void)EVP_MD_CTX_cleanup(ctx); | 24 (void)EVP_MD_CTX_cleanup(ctx); |
| 25 } | 25 } |
| 26 | 26 |
| 27 } // namespace anonymous | 27 } // namespace anonymous |
| 28 | 28 |
| 29 namespace net { | 29 namespace net { |
| 30 | 30 |
| 31 namespace test { | 31 namespace test { |
| 32 | 32 |
| 33 class TestChannelIDSigner : public ChannelIDSigner { | 33 class TestChannelIDSigner : public ChannelIDSigner { |
| (...skipping 135 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 169 } | 169 } |
| 170 | 170 |
| 171 // static | 171 // static |
| 172 string CryptoTestUtils::ChannelIDKeyForHostname(const string& hostname) { | 172 string CryptoTestUtils::ChannelIDKeyForHostname(const string& hostname) { |
| 173 return TestChannelIDSigner::KeyForHostname(hostname); | 173 return TestChannelIDSigner::KeyForHostname(hostname); |
| 174 } | 174 } |
| 175 | 175 |
| 176 } // namespace test | 176 } // namespace test |
| 177 | 177 |
| 178 } // namespace net | 178 } // namespace net |
| OLD | NEW |