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

Side by Side Diff: net/spdy/spdy_test_util_common.cc

Issue 2400183002: Cleanup: More accurate output parameter type for CTVerifier (Closed)
Patch Set: IWYU, review comments Created 4 years, 2 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
« no previous file with comments | « net/socket/ssl_server_socket_unittest.cc ('k') | net/test/ct_test_util.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 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/spdy/spdy_test_util_common.h" 5 #include "net/spdy/spdy_test_util_common.h"
6 6
7 #include <stdint.h> 7 #include <stdint.h>
8 8
9 #include <cstddef> 9 #include <cstddef>
10 #include <utility> 10 #include <utility>
11 11
12 #include "base/compiler_specific.h" 12 #include "base/compiler_specific.h"
13 #include "base/logging.h" 13 #include "base/logging.h"
14 #include "base/memory/ptr_util.h" 14 #include "base/memory/ptr_util.h"
15 #include "base/strings/string_number_conversions.h" 15 #include "base/strings/string_number_conversions.h"
16 #include "base/strings/string_split.h" 16 #include "base/strings/string_split.h"
17 #include "net/base/host_port_pair.h" 17 #include "net/base/host_port_pair.h"
18 #include "net/cert/ct_policy_enforcer.h" 18 #include "net/cert/ct_policy_enforcer.h"
19 #include "net/cert/ct_policy_status.h" 19 #include "net/cert/ct_policy_status.h"
20 #include "net/cert/mock_cert_verifier.h" 20 #include "net/cert/mock_cert_verifier.h"
21 #include "net/cert/multi_log_ct_verifier.h" 21 #include "net/cert/multi_log_ct_verifier.h"
22 #include "net/cert/signed_certificate_timestamp_and_status.h"
22 #include "net/http/http_cache.h" 23 #include "net/http/http_cache.h"
23 #include "net/http/http_network_session.h" 24 #include "net/http/http_network_session.h"
24 #include "net/http/http_network_transaction.h" 25 #include "net/http/http_network_transaction.h"
25 #include "net/http/http_server_properties_impl.h" 26 #include "net/http/http_server_properties_impl.h"
26 #include "net/log/net_log_with_source.h" 27 #include "net/log/net_log_with_source.h"
27 #include "net/socket/next_proto.h" 28 #include "net/socket/next_proto.h"
28 #include "net/socket/socket_test_util.h" 29 #include "net/socket/socket_test_util.h"
29 #include "net/socket/ssl_client_socket.h" 30 #include "net/socket/ssl_client_socket.h"
30 #include "net/socket/transport_client_socket_pool.h" 31 #include "net/socket/transport_client_socket_pool.h"
31 #include "net/spdy/buffered_spdy_framer.h" 32 #include "net/spdy/buffered_spdy_framer.h"
(...skipping 395 matching lines...) Expand 10 before | Expand all | Expand 10 after
427 }; 428 };
428 429
429 class IgnoresCTVerifier : public net::CTVerifier { 430 class IgnoresCTVerifier : public net::CTVerifier {
430 public: 431 public:
431 IgnoresCTVerifier() = default; 432 IgnoresCTVerifier() = default;
432 ~IgnoresCTVerifier() override = default; 433 ~IgnoresCTVerifier() override = default;
433 434
434 int Verify(net::X509Certificate* cert, 435 int Verify(net::X509Certificate* cert,
435 const std::string& stapled_ocsp_response, 436 const std::string& stapled_ocsp_response,
436 const std::string& sct_list_from_tls_extension, 437 const std::string& sct_list_from_tls_extension,
437 net::ct::CTVerifyResult* result, 438 SignedCertificateTimestampAndStatusList* output_scts,
438 const net::NetLogWithSource& net_log) override { 439 const net::NetLogWithSource& net_log) override {
439 return net::OK; 440 return net::OK;
440 } 441 }
441 442
442 void SetObserver(Observer* observer) override {} 443 void SetObserver(Observer* observer) override {}
443 }; 444 };
444 445
445 SpdyURLRequestContext::SpdyURLRequestContext() : storage_(this) { 446 SpdyURLRequestContext::SpdyURLRequestContext() : storage_(this) {
446 storage_.set_host_resolver( 447 storage_.set_host_resolver(
447 std::unique_ptr<HostResolver>(new MockHostResolver)); 448 std::unique_ptr<HostResolver>(new MockHostResolver));
(...skipping 692 matching lines...) Expand 10 before | Expand all | Expand 10 after
1140 headers[GetSchemeKey()] = scheme.c_str(); 1141 headers[GetSchemeKey()] = scheme.c_str();
1141 headers[GetPathKey()] = path.c_str(); 1142 headers[GetPathKey()] = path.c_str();
1142 if (content_length) { 1143 if (content_length) {
1143 std::string length_str = base::Int64ToString(*content_length); 1144 std::string length_str = base::Int64ToString(*content_length);
1144 headers["content-length"] = length_str; 1145 headers["content-length"] = length_str;
1145 } 1146 }
1146 return headers; 1147 return headers;
1147 } 1148 }
1148 1149
1149 } // namespace net 1150 } // namespace net
OLDNEW
« no previous file with comments | « net/socket/ssl_server_socket_unittest.cc ('k') | net/test/ct_test_util.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698