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

Side by Side Diff: chrome/browser/ssl/security_state_tab_helper.cc

Issue 2860553002: Clean up most of the ChromeOS headers in non-ChromeOS build (Closed)
Patch Set: rebase Created 3 years, 7 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 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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/ssl/security_state_tab_helper.h" 5 #include "chrome/browser/ssl/security_state_tab_helper.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/metrics/histogram_macros.h" 8 #include "base/metrics/histogram_macros.h"
9 #include "base/time/time.h" 9 #include "base/time/time.h"
10 #include "build/build_config.h" 10 #include "build/build_config.h"
11 #include "chrome/browser/browser_process.h" 11 #include "chrome/browser/browser_process.h"
12 #include "chrome/browser/chromeos/policy/policy_cert_service.h"
13 #include "chrome/browser/chromeos/policy/policy_cert_service_factory.h"
14 #include "chrome/browser/profiles/profile.h" 12 #include "chrome/browser/profiles/profile.h"
15 #include "chrome/browser/safe_browsing/safe_browsing_service.h" 13 #include "chrome/browser/safe_browsing/safe_browsing_service.h"
16 #include "chrome/browser/safe_browsing/ui_manager.h" 14 #include "chrome/browser/safe_browsing/ui_manager.h"
17 #include "components/prefs/pref_service.h" 15 #include "components/prefs/pref_service.h"
18 #include "components/security_state/content/content_utils.h" 16 #include "components/security_state/content/content_utils.h"
19 #include "components/ssl_config/ssl_config_prefs.h" 17 #include "components/ssl_config/ssl_config_prefs.h"
20 #include "content/public/browser/navigation_entry.h" 18 #include "content/public/browser/navigation_entry.h"
21 #include "content/public/browser/navigation_handle.h" 19 #include "content/public/browser/navigation_handle.h"
22 #include "content/public/browser/render_frame_host.h" 20 #include "content/public/browser/render_frame_host.h"
23 #include "content/public/browser/web_contents.h" 21 #include "content/public/browser/web_contents.h"
24 #include "content/public/common/origin_util.h" 22 #include "content/public/common/origin_util.h"
25 #include "net/base/net_errors.h" 23 #include "net/base/net_errors.h"
26 #include "net/cert/x509_certificate.h" 24 #include "net/cert/x509_certificate.h"
27 #include "net/ssl/ssl_cipher_suite_names.h" 25 #include "net/ssl/ssl_cipher_suite_names.h"
28 #include "net/ssl/ssl_connection_status_flags.h" 26 #include "net/ssl/ssl_connection_status_flags.h"
29 #include "third_party/boringssl/src/include/openssl/ssl.h" 27 #include "third_party/boringssl/src/include/openssl/ssl.h"
30 #include "ui/base/l10n/l10n_util.h" 28 #include "ui/base/l10n/l10n_util.h"
31 29
30 #if defined(OS_CHROMEOS)
31 #include "chrome/browser/chromeos/policy/policy_cert_service.h"
32 #include "chrome/browser/chromeos/policy/policy_cert_service_factory.h"
33 #endif // defined(OS_CHROMEOS)
34
32 DEFINE_WEB_CONTENTS_USER_DATA_KEY(SecurityStateTabHelper); 35 DEFINE_WEB_CONTENTS_USER_DATA_KEY(SecurityStateTabHelper);
33 36
34 using safe_browsing::SafeBrowsingUIManager; 37 using safe_browsing::SafeBrowsingUIManager;
35 38
36 SecurityStateTabHelper::SecurityStateTabHelper( 39 SecurityStateTabHelper::SecurityStateTabHelper(
37 content::WebContents* web_contents) 40 content::WebContents* web_contents)
38 : content::WebContentsObserver(web_contents), 41 : content::WebContentsObserver(web_contents),
39 logged_http_warning_on_current_navigation_(false) {} 42 logged_http_warning_on_current_navigation_(false) {}
40 43
41 SecurityStateTabHelper::~SecurityStateTabHelper() {} 44 SecurityStateTabHelper::~SecurityStateTabHelper() {}
(...skipping 147 matching lines...) Expand 10 before | Expand all | Expand 10 after
189 std::unique_ptr<security_state::VisibleSecurityState> 192 std::unique_ptr<security_state::VisibleSecurityState>
190 SecurityStateTabHelper::GetVisibleSecurityState() const { 193 SecurityStateTabHelper::GetVisibleSecurityState() const {
191 auto state = security_state::GetVisibleSecurityState(web_contents()); 194 auto state = security_state::GetVisibleSecurityState(web_contents());
192 195
193 // Malware status might already be known even if connection security 196 // Malware status might already be known even if connection security
194 // information is still being initialized, thus no need to check for that. 197 // information is still being initialized, thus no need to check for that.
195 state->malicious_content_status = GetMaliciousContentStatus(); 198 state->malicious_content_status = GetMaliciousContentStatus();
196 199
197 return state; 200 return state;
198 } 201 }
OLDNEW
« no previous file with comments | « chrome/browser/profiles/profile_manager_unittest.cc ('k') | chrome/browser/ui/input_method/input_method_engine_base.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698