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

Side by Side Diff: chrome/browser/io_thread.cc

Issue 1991653002: Move caching out of MultiThreadedCertVerifier (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@request_params
Patch Set: CrOS fixes Created 4 years, 6 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
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 "chrome/browser/io_thread.h" 5 #include "chrome/browser/io_thread.h"
6 6
7 #include <utility> 7 #include <utility>
8 #include <vector> 8 #include <vector>
9 9
10 #include "base/base64.h" 10 #include "base/base64.h"
(...skipping 48 matching lines...) Expand 10 before | Expand all | Expand 10 after
59 #include "components/variations/variations_associated_data.h" 59 #include "components/variations/variations_associated_data.h"
60 #include "components/version_info/version_info.h" 60 #include "components/version_info/version_info.h"
61 #include "content/public/browser/browser_thread.h" 61 #include "content/public/browser/browser_thread.h"
62 #include "content/public/browser/cookie_store_factory.h" 62 #include "content/public/browser/cookie_store_factory.h"
63 #include "content/public/common/content_features.h" 63 #include "content/public/common/content_features.h"
64 #include "content/public/common/content_switches.h" 64 #include "content/public/common/content_switches.h"
65 #include "content/public/common/user_agent.h" 65 #include "content/public/common/user_agent.h"
66 #include "net/base/host_mapping_rules.h" 66 #include "net/base/host_mapping_rules.h"
67 #include "net/base/logging_network_change_observer.h" 67 #include "net/base/logging_network_change_observer.h"
68 #include "net/base/sdch_manager.h" 68 #include "net/base/sdch_manager.h"
69 #include "net/cert/caching_cert_verifier.h"
69 #include "net/cert/cert_verifier.h" 70 #include "net/cert/cert_verifier.h"
70 #include "net/cert/cert_verify_proc.h" 71 #include "net/cert/cert_verify_proc.h"
71 #include "net/cert/ct_known_logs.h" 72 #include "net/cert/ct_known_logs.h"
72 #include "net/cert/ct_log_verifier.h" 73 #include "net/cert/ct_log_verifier.h"
73 #include "net/cert/ct_policy_enforcer.h" 74 #include "net/cert/ct_policy_enforcer.h"
74 #include "net/cert/ct_verifier.h" 75 #include "net/cert/ct_verifier.h"
75 #include "net/cert/multi_log_ct_verifier.h" 76 #include "net/cert/multi_log_ct_verifier.h"
76 #include "net/cert/multi_threaded_cert_verifier.h" 77 #include "net/cert/multi_threaded_cert_verifier.h"
77 #include "net/cert/sth_distributor.h" 78 #include "net/cert/sth_distributor.h"
78 #include "net/cert/sth_observer.h" 79 #include "net/cert/sth_observer.h"
(...skipping 477 matching lines...) Expand 10 before | Expand all | Expand 10 after
556 FROM_HERE_WITH_EXPLICIT_FUNCTION( 557 FROM_HERE_WITH_EXPLICIT_FUNCTION(
557 "466432 IOThread::InitAsync::UpdateDnsClientEnabled::Start")); 558 "466432 IOThread::InitAsync::UpdateDnsClientEnabled::Start"));
558 UpdateDnsClientEnabled(); 559 UpdateDnsClientEnabled();
559 // TODO(erikchen): Remove ScopedTracker below once http://crbug.com/466432 560 // TODO(erikchen): Remove ScopedTracker below once http://crbug.com/466432
560 // is fixed. 561 // is fixed.
561 tracked_objects::ScopedTracker tracking_profile6( 562 tracked_objects::ScopedTracker tracking_profile6(
562 FROM_HERE_WITH_EXPLICIT_FUNCTION( 563 FROM_HERE_WITH_EXPLICIT_FUNCTION(
563 "466432 IOThread::InitAsync::UpdateDnsClientEnabled::End")); 564 "466432 IOThread::InitAsync::UpdateDnsClientEnabled::End"));
564 #if defined(OS_CHROMEOS) 565 #if defined(OS_CHROMEOS)
565 // Creates a CertVerifyProc that doesn't allow any profile-provided certs. 566 // Creates a CertVerifyProc that doesn't allow any profile-provided certs.
566 globals_->cert_verifier.reset(new net::MultiThreadedCertVerifier( 567 globals_->cert_verifier = base::MakeUnique<net::CachingCertVerifier>(
567 new chromeos::CertVerifyProcChromeOS())); 568 base::MakeUnique<net::MultiThreadedCertVerifier>(
569 new chromeos::CertVerifyProcChromeOS()));
568 #else 570 #else
569 globals_->cert_verifier.reset(new net::MultiThreadedCertVerifier( 571 globals_->cert_verifier = net::CertVerifier::CreateDefault();
570 net::CertVerifyProc::CreateDefault()));
571 #endif 572 #endif
572 573
573 globals_->transport_security_state.reset(new net::TransportSecurityState()); 574 globals_->transport_security_state.reset(new net::TransportSecurityState());
574 575
575 // TODO(erikchen): Remove ScopedTracker below once http://crbug.com/466432 576 // TODO(erikchen): Remove ScopedTracker below once http://crbug.com/466432
576 // is fixed. 577 // is fixed.
577 tracked_objects::ScopedTracker tracking_profile8( 578 tracked_objects::ScopedTracker tracking_profile8(
578 FROM_HERE_WITH_EXPLICIT_FUNCTION( 579 FROM_HERE_WITH_EXPLICIT_FUNCTION(
579 "466432 IOThread::InitAsync::CreateLogVerifiers::Start")); 580 "466432 IOThread::InitAsync::CreateLogVerifiers::Start"));
580 std::vector<scoped_refptr<const net::CTLogVerifier>> ct_logs( 581 std::vector<scoped_refptr<const net::CTLogVerifier>> ct_logs(
(...skipping 521 matching lines...) Expand 10 before | Expand all | Expand 10 after
1102 // TODO(rtenneti): We should probably use HttpServerPropertiesManager for the 1103 // TODO(rtenneti): We should probably use HttpServerPropertiesManager for the
1103 // system URLRequestContext too. There's no reason this should be tied to a 1104 // system URLRequestContext too. There's no reason this should be tied to a
1104 // profile. 1105 // profile.
1105 return context; 1106 return context;
1106 } 1107 }
1107 1108
1108 const metrics::UpdateUsagePrefCallbackType& 1109 const metrics::UpdateUsagePrefCallbackType&
1109 IOThread::GetMetricsDataUseForwarder() { 1110 IOThread::GetMetricsDataUseForwarder() {
1110 return metrics_data_use_forwarder_; 1111 return metrics_data_use_forwarder_;
1111 } 1112 }
OLDNEW
« no previous file with comments | « chrome/browser/chromeos/policy/policy_cert_verifier.cc ('k') | chrome/browser/profiles/profile_io_data.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698