| 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/callback_helpers.h" | 7 #include "base/callback_helpers.h" |
| 8 #include "base/logging.h" | 8 #include "base/logging.h" |
| 9 #include "base/memory/ref_counted.h" | 9 #include "base/memory/ref_counted.h" |
| 10 #include "base/memory/scoped_ptr.h" | 10 #include "base/memory/scoped_ptr.h" |
| (...skipping 119 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 130 const std::string& cert_file) | 130 const std::string& cert_file) |
| 131 : TestProofVerifierChromium(cert_verifier.Pass(), | 131 : TestProofVerifierChromium(cert_verifier.Pass(), |
| 132 transport_security_state.Pass(), | 132 transport_security_state.Pass(), |
| 133 cert_file) {} | 133 cert_file) {} |
| 134 ~FakeProofVerifier() override {} | 134 ~FakeProofVerifier() override {} |
| 135 | 135 |
| 136 // ProofVerifier interface | 136 // ProofVerifier interface |
| 137 QuicAsyncStatus VerifyProof(const std::string& hostname, | 137 QuicAsyncStatus VerifyProof(const std::string& hostname, |
| 138 const std::string& server_config, | 138 const std::string& server_config, |
| 139 const std::vector<std::string>& certs, | 139 const std::vector<std::string>& certs, |
| 140 const std::string& cert_sct, |
| 140 const std::string& signature, | 141 const std::string& signature, |
| 141 const ProofVerifyContext* verify_context, | 142 const ProofVerifyContext* verify_context, |
| 142 std::string* error_details, | 143 std::string* error_details, |
| 143 scoped_ptr<ProofVerifyDetails>* verify_details, | 144 scoped_ptr<ProofVerifyDetails>* verify_details, |
| 144 ProofVerifierCallback* callback) override { | 145 ProofVerifierCallback* callback) override { |
| 145 error_details->clear(); | 146 error_details->clear(); |
| 146 scoped_ptr<ProofVerifyDetailsChromium> verify_details_chromium( | 147 scoped_ptr<ProofVerifyDetailsChromium> verify_details_chromium( |
| 147 new ProofVerifyDetailsChromium); | 148 new ProofVerifyDetailsChromium); |
| 148 DCHECK(!certs.empty()); | 149 DCHECK(!certs.empty()); |
| 149 // Convert certs to X509Certificate. | 150 // Convert certs to X509Certificate. |
| (...skipping 103 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 253 } | 254 } |
| 254 | 255 |
| 255 // static | 256 // static |
| 256 ProofVerifyContext* CryptoTestUtils::ProofVerifyContextForTesting() { | 257 ProofVerifyContext* CryptoTestUtils::ProofVerifyContextForTesting() { |
| 257 return new ProofVerifyContextChromium(/*cert_verify_flags=*/0, BoundNetLog()); | 258 return new ProofVerifyContextChromium(/*cert_verify_flags=*/0, BoundNetLog()); |
| 258 } | 259 } |
| 259 | 260 |
| 260 } // namespace test | 261 } // namespace test |
| 261 | 262 |
| 262 } // namespace net | 263 } // namespace net |
| OLD | NEW |