| 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 "base/memory/ref_counted.h" | 7 #include "base/memory/ref_counted.h" |
| 8 #include "base/memory/scoped_ptr.h" | 8 #include "base/memory/scoped_ptr.h" |
| 9 #include "net/base/net_errors.h" | 9 #include "net/base/net_errors.h" |
| 10 #include "net/base/test_data_directory.h" | 10 #include "net/base/test_data_directory.h" |
| (...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 58 certs_[1] = kIntermediateCert; | 58 certs_[1] = kIntermediateCert; |
| 59 } | 59 } |
| 60 ~FakeProofSource() override {} | 60 ~FakeProofSource() override {} |
| 61 | 61 |
| 62 // ProofSource interface | 62 // ProofSource interface |
| 63 bool GetProof(const IPAddressNumber& server_ip, | 63 bool GetProof(const IPAddressNumber& server_ip, |
| 64 const std::string& hostname, | 64 const std::string& hostname, |
| 65 const std::string& server_config, | 65 const std::string& server_config, |
| 66 bool ecdsa_ok, | 66 bool ecdsa_ok, |
| 67 const std::vector<std::string>** out_certs, | 67 const std::vector<std::string>** out_certs, |
| 68 std::string* out_signature) override { | 68 std::string* out_signature, |
| 69 std::string* out_leaf_cert_sct) override { |
| 69 *out_certs = &certs_; | 70 *out_certs = &certs_; |
| 70 *out_signature = kSignature; | 71 *out_signature = kSignature; |
| 71 return true; | 72 return true; |
| 72 } | 73 } |
| 73 | 74 |
| 74 private: | 75 private: |
| 75 std::vector<std::string> certs_; | 76 std::vector<std::string> certs_; |
| 76 DISALLOW_COPY_AND_ASSIGN(FakeProofSource); | 77 DISALLOW_COPY_AND_ASSIGN(FakeProofSource); |
| 77 }; | 78 }; |
| 78 | 79 |
| (...skipping 76 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 155 } | 156 } |
| 156 | 157 |
| 157 // static | 158 // static |
| 158 ProofVerifyContext* CryptoTestUtils::FakeProofVerifyContextForTesting() { | 159 ProofVerifyContext* CryptoTestUtils::FakeProofVerifyContextForTesting() { |
| 159 return nullptr; | 160 return nullptr; |
| 160 } | 161 } |
| 161 | 162 |
| 162 } // namespace test | 163 } // namespace test |
| 163 | 164 |
| 164 } // namespace net | 165 } // namespace net |
| OLD | NEW |