Commit 7b717e17 authored by Lucas Garron's avatar Lucas Garron Committed by Commit Bot

Rename ChromeControllerClient to SSLErrorControllerClient and move to //chrome/browser/ssl

TBR=nparker@chromium.org

Bug: 785494
Change-Id: I4962501edae4815c60c4d00107053ee6f577639a
Reviewed-on: https://chromium-review.googlesource.com/773281
Commit-Queue: Lucas Garron <lgarron@chromium.org>
Reviewed-by: default avatarMustafa Emre Acer <meacer@chromium.org>
Cr-Commit-Position: refs/heads/master@{#517059}
parent 08e9d630
...@@ -560,8 +560,6 @@ split_static_library("browser") { ...@@ -560,8 +560,6 @@ split_static_library("browser") {
"installable/installable_task_queue.h", "installable/installable_task_queue.h",
"internal_auth.cc", "internal_auth.cc",
"internal_auth.h", "internal_auth.h",
"interstitials/chrome_controller_client.cc",
"interstitials/chrome_controller_client.h",
"interstitials/chrome_metrics_helper.cc", "interstitials/chrome_metrics_helper.cc",
"interstitials/chrome_metrics_helper.h", "interstitials/chrome_metrics_helper.h",
"intranet_redirect_detector.cc", "intranet_redirect_detector.cc",
...@@ -1373,6 +1371,8 @@ split_static_library("browser") { ...@@ -1373,6 +1371,8 @@ split_static_library("browser") {
"ssl/ssl_client_certificate_selector.h", "ssl/ssl_client_certificate_selector.h",
"ssl/ssl_error_assistant.cc", "ssl/ssl_error_assistant.cc",
"ssl/ssl_error_assistant.h", "ssl/ssl_error_assistant.h",
"ssl/ssl_error_controller_client.cc",
"ssl/ssl_error_controller_client.h",
"ssl/ssl_error_handler.cc", "ssl/ssl_error_handler.cc",
"ssl/ssl_error_handler.h", "ssl/ssl_error_handler.h",
"ssl/ssl_error_navigation_throttle.cc", "ssl/ssl_error_navigation_throttle.cc",
......
...@@ -9,7 +9,6 @@ ...@@ -9,7 +9,6 @@
#include "base/lazy_instance.h" #include "base/lazy_instance.h"
#include "chrome/browser/browser_process.h" #include "chrome/browser/browser_process.h"
#include "chrome/browser/history/history_service_factory.h" #include "chrome/browser/history/history_service_factory.h"
#include "chrome/browser/interstitials/chrome_controller_client.h"
#include "chrome/browser/interstitials/chrome_metrics_helper.h" #include "chrome/browser/interstitials/chrome_metrics_helper.h"
#include "chrome/browser/profiles/profile.h" #include "chrome/browser/profiles/profile.h"
#include "chrome/browser/renderer_preferences_util.h" #include "chrome/browser/renderer_preferences_util.h"
...@@ -19,6 +18,7 @@ ...@@ -19,6 +18,7 @@
#include "components/safe_browsing/browser/threat_details.h" #include "components/safe_browsing/browser/threat_details.h"
#include "components/safe_browsing/common/safe_browsing_prefs.h" #include "components/safe_browsing/common/safe_browsing_prefs.h"
#include "components/safe_browsing/triggers/trigger_manager.h" #include "components/safe_browsing/triggers/trigger_manager.h"
#include "components/security_interstitials/content/security_interstitial_controller_client.h"
#include "content/public/browser/browser_thread.h" #include "content/public/browser/browser_thread.h"
#include "content/public/browser/interstitial_page.h" #include "content/public/browser/interstitial_page.h"
#include "content/public/browser/navigation_entry.h" #include "content/public/browser/navigation_entry.h"
......
...@@ -5,7 +5,6 @@ ...@@ -5,7 +5,6 @@
#include <list> #include <list>
#include "base/run_loop.h" #include "base/run_loop.h"
#include "chrome/browser/interstitials/chrome_controller_client.h"
#include "chrome/browser/profiles/profile.h" #include "chrome/browser/profiles/profile.h"
#include "chrome/browser/safe_browsing/safe_browsing_blocking_page.h" #include "chrome/browser/safe_browsing/safe_browsing_blocking_page.h"
#include "chrome/browser/safe_browsing/test_safe_browsing_service.h" #include "chrome/browser/safe_browsing/test_safe_browsing_service.h"
...@@ -17,6 +16,7 @@ ...@@ -17,6 +16,7 @@
#include "components/prefs/pref_service.h" #include "components/prefs/pref_service.h"
#include "components/safe_browsing/browser/threat_details.h" #include "components/safe_browsing/browser/threat_details.h"
#include "components/safe_browsing/common/safe_browsing_prefs.h" #include "components/safe_browsing/common/safe_browsing_prefs.h"
#include "components/security_interstitials/content/security_interstitial_controller_client.h"
#include "components/security_interstitials/core/safe_browsing_quiet_error_ui.h" #include "components/security_interstitials/core/safe_browsing_quiet_error_ui.h"
#include "components/strings/grit/components_strings.h" #include "components/strings/grit/components_strings.h"
#include "content/public/browser/interstitial_page.h" #include "content/public/browser/interstitial_page.h"
......
...@@ -9,12 +9,12 @@ ...@@ -9,12 +9,12 @@
#include "base/callback_helpers.h" #include "base/callback_helpers.h"
#include "base/memory/ptr_util.h" #include "base/memory/ptr_util.h"
#include "base/strings/string_number_conversions.h" #include "base/strings/string_number_conversions.h"
#include "chrome/browser/interstitials/chrome_controller_client.h"
#include "chrome/browser/interstitials/chrome_metrics_helper.h" #include "chrome/browser/interstitials/chrome_metrics_helper.h"
#include "chrome/browser/profiles/profile.h" #include "chrome/browser/profiles/profile.h"
#include "chrome/browser/renderer_preferences_util.h" #include "chrome/browser/renderer_preferences_util.h"
#include "chrome/browser/ssl/cert_report_helper.h" #include "chrome/browser/ssl/cert_report_helper.h"
#include "chrome/browser/ssl/ssl_cert_reporter.h" #include "chrome/browser/ssl/ssl_cert_reporter.h"
#include "chrome/browser/ssl/ssl_error_controller_client.h"
#include "components/safe_browsing/common/safe_browsing_prefs.h" #include "components/safe_browsing/common/safe_browsing_prefs.h"
#include "components/security_interstitials/core/bad_clock_ui.h" #include "components/security_interstitials/core/bad_clock_ui.h"
#include "components/security_interstitials/core/metrics_helper.h" #include "components/security_interstitials/core/metrics_helper.h"
...@@ -72,7 +72,7 @@ BadClockBlockingPage::BadClockBlockingPage( ...@@ -72,7 +72,7 @@ BadClockBlockingPage::BadClockBlockingPage(
: SecurityInterstitialPage( : SecurityInterstitialPage(
web_contents, web_contents,
request_url, request_url,
base::MakeUnique<ChromeControllerClient>( base::MakeUnique<SSLErrorControllerClient>(
web_contents, web_contents,
ssl_info, ssl_info,
request_url, request_url,
......
...@@ -15,11 +15,11 @@ ...@@ -15,11 +15,11 @@
#include "base/values.h" #include "base/values.h"
#include "build/build_config.h" #include "build/build_config.h"
#include "chrome/browser/captive_portal/captive_portal_tab_helper.h" #include "chrome/browser/captive_portal/captive_portal_tab_helper.h"
#include "chrome/browser/interstitials/chrome_controller_client.h"
#include "chrome/browser/interstitials/chrome_metrics_helper.h" #include "chrome/browser/interstitials/chrome_metrics_helper.h"
#include "chrome/browser/profiles/profile.h" #include "chrome/browser/profiles/profile.h"
#include "chrome/browser/ssl/cert_report_helper.h" #include "chrome/browser/ssl/cert_report_helper.h"
#include "chrome/browser/ssl/ssl_cert_reporter.h" #include "chrome/browser/ssl/ssl_cert_reporter.h"
#include "chrome/browser/ssl/ssl_error_controller_client.h"
#include "components/captive_portal/captive_portal_detector.h" #include "components/captive_portal/captive_portal_detector.h"
#include "components/captive_portal/captive_portal_metrics.h" #include "components/captive_portal/captive_portal_metrics.h"
#include "components/certificate_reporting/error_reporter.h" #include "components/certificate_reporting/error_reporter.h"
...@@ -77,7 +77,7 @@ CaptivePortalBlockingPage::CaptivePortalBlockingPage( ...@@ -77,7 +77,7 @@ CaptivePortalBlockingPage::CaptivePortalBlockingPage(
: SecurityInterstitialPage( : SecurityInterstitialPage(
web_contents, web_contents,
request_url, request_url,
base::MakeUnique<ChromeControllerClient>( base::MakeUnique<SSLErrorControllerClient>(
web_contents, web_contents,
ssl_info, ssl_info,
request_url, request_url,
......
...@@ -8,12 +8,12 @@ ...@@ -8,12 +8,12 @@
#include "base/callback_helpers.h" #include "base/callback_helpers.h"
#include "base/memory/ptr_util.h" #include "base/memory/ptr_util.h"
#include "chrome/browser/interstitials/chrome_controller_client.h"
#include "chrome/browser/interstitials/chrome_metrics_helper.h" #include "chrome/browser/interstitials/chrome_metrics_helper.h"
#include "chrome/browser/profiles/profile.h" #include "chrome/browser/profiles/profile.h"
#include "chrome/browser/renderer_preferences_util.h" #include "chrome/browser/renderer_preferences_util.h"
#include "chrome/browser/ssl/cert_report_helper.h" #include "chrome/browser/ssl/cert_report_helper.h"
#include "chrome/browser/ssl/ssl_cert_reporter.h" #include "chrome/browser/ssl/ssl_cert_reporter.h"
#include "chrome/browser/ssl/ssl_error_controller_client.h"
#include "components/safe_browsing/common/safe_browsing_prefs.h" #include "components/safe_browsing/common/safe_browsing_prefs.h"
#include "components/security_interstitials/core/metrics_helper.h" #include "components/security_interstitials/core/metrics_helper.h"
#include "components/security_interstitials/core/mitm_software_ui.h" #include "components/security_interstitials/core/mitm_software_ui.h"
...@@ -71,7 +71,7 @@ MITMSoftwareBlockingPage::MITMSoftwareBlockingPage( ...@@ -71,7 +71,7 @@ MITMSoftwareBlockingPage::MITMSoftwareBlockingPage(
: SecurityInterstitialPage( : SecurityInterstitialPage(
web_contents, web_contents,
request_url, request_url,
base::MakeUnique<ChromeControllerClient>( base::MakeUnique<SSLErrorControllerClient>(
web_contents, web_contents,
ssl_info, ssl_info,
request_url, request_url,
......
...@@ -14,12 +14,12 @@ ...@@ -14,12 +14,12 @@
#include "base/strings/string_number_conversions.h" #include "base/strings/string_number_conversions.h"
#include "base/time/time.h" #include "base/time/time.h"
#include "chrome/browser/browser_process.h" #include "chrome/browser/browser_process.h"
#include "chrome/browser/interstitials/chrome_controller_client.h"
#include "chrome/browser/interstitials/chrome_metrics_helper.h" #include "chrome/browser/interstitials/chrome_metrics_helper.h"
#include "chrome/browser/profiles/profile.h" #include "chrome/browser/profiles/profile.h"
#include "chrome/browser/renderer_preferences_util.h" #include "chrome/browser/renderer_preferences_util.h"
#include "chrome/browser/ssl/cert_report_helper.h" #include "chrome/browser/ssl/cert_report_helper.h"
#include "chrome/browser/ssl/ssl_cert_reporter.h" #include "chrome/browser/ssl/ssl_cert_reporter.h"
#include "chrome/browser/ssl/ssl_error_controller_client.h"
#include "chrome/common/chrome_switches.h" #include "chrome/common/chrome_switches.h"
#include "components/safe_browsing/common/safe_browsing_prefs.h" #include "components/safe_browsing/common/safe_browsing_prefs.h"
#include "components/security_interstitials/core/controller_client.h" #include "components/security_interstitials/core/controller_client.h"
...@@ -178,13 +178,13 @@ SSLBlockingPage::SSLBlockingPage( ...@@ -178,13 +178,13 @@ SSLBlockingPage::SSLBlockingPage(
std::unique_ptr<ChromeMetricsHelper> metrics_helper, std::unique_ptr<ChromeMetricsHelper> metrics_helper,
bool is_superfish, bool is_superfish,
const base::Callback<void(content::CertificateRequestResultType)>& callback) const base::Callback<void(content::CertificateRequestResultType)>& callback)
: SecurityInterstitialPage( : SecurityInterstitialPage(web_contents,
web_contents, request_url,
request_url, base::MakeUnique<SSLErrorControllerClient>(
base::MakeUnique<ChromeControllerClient>(web_contents, web_contents,
ssl_info, ssl_info,
request_url, request_url,
std::move(metrics_helper))), std::move(metrics_helper))),
callback_(callback), callback_(callback),
ssl_info_(ssl_info), ssl_info_(ssl_info),
overridable_(overridable), overridable_(overridable),
......
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
// Use of this source code is governed by a BSD-style license that can be // Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file. // found in the LICENSE file.
#include "chrome/browser/interstitials/chrome_controller_client.h" #include "chrome/browser/ssl/ssl_error_controller_client.h"
#include "base/bind.h" #include "base/bind.h"
#include "base/command_line.h" #include "base/command_line.h"
...@@ -123,7 +123,7 @@ bool AreCommittedInterstitialsEnabled() { ...@@ -123,7 +123,7 @@ bool AreCommittedInterstitialsEnabled() {
} // namespace } // namespace
ChromeControllerClient::ChromeControllerClient( SSLErrorControllerClient::SSLErrorControllerClient(
content::WebContents* web_contents, content::WebContents* web_contents,
const net::SSLInfo& ssl_info, const net::SSLInfo& ssl_info,
const GURL& request_url, const GURL& request_url,
...@@ -138,9 +138,9 @@ ChromeControllerClient::ChromeControllerClient( ...@@ -138,9 +138,9 @@ ChromeControllerClient::ChromeControllerClient(
ssl_info_(ssl_info), ssl_info_(ssl_info),
request_url_(request_url) {} request_url_(request_url) {}
ChromeControllerClient::~ChromeControllerClient() {} SSLErrorControllerClient::~SSLErrorControllerClient() {}
void ChromeControllerClient::GoBack() { void SSLErrorControllerClient::GoBack() {
if (!AreCommittedInterstitialsEnabled()) { if (!AreCommittedInterstitialsEnabled()) {
SecurityInterstitialControllerClient::GoBack(); SecurityInterstitialControllerClient::GoBack();
return; return;
...@@ -149,7 +149,7 @@ void ChromeControllerClient::GoBack() { ...@@ -149,7 +149,7 @@ void ChromeControllerClient::GoBack() {
SecurityInterstitialControllerClient::GoBackAfterNavigationCommitted(); SecurityInterstitialControllerClient::GoBackAfterNavigationCommitted();
} }
void ChromeControllerClient::Proceed() { void SSLErrorControllerClient::Proceed() {
if (!AreCommittedInterstitialsEnabled()) { if (!AreCommittedInterstitialsEnabled()) {
SecurityInterstitialControllerClient::Proceed(); SecurityInterstitialControllerClient::Proceed();
return; return;
...@@ -164,7 +164,7 @@ void ChromeControllerClient::Proceed() { ...@@ -164,7 +164,7 @@ void ChromeControllerClient::Proceed() {
Reload(); Reload();
} }
bool ChromeControllerClient::CanLaunchDateAndTimeSettings() { bool SSLErrorControllerClient::CanLaunchDateAndTimeSettings() {
#if defined(OS_ANDROID) || defined(OS_LINUX) || defined(OS_MACOSX) || \ #if defined(OS_ANDROID) || defined(OS_LINUX) || defined(OS_MACOSX) || \
defined(OS_WIN) defined(OS_WIN)
return true; return true;
...@@ -173,7 +173,7 @@ bool ChromeControllerClient::CanLaunchDateAndTimeSettings() { ...@@ -173,7 +173,7 @@ bool ChromeControllerClient::CanLaunchDateAndTimeSettings() {
#endif #endif
} }
void ChromeControllerClient::LaunchDateAndTimeSettings() { void SSLErrorControllerClient::LaunchDateAndTimeSettings() {
DCHECK_CURRENTLY_ON(content::BrowserThread::UI); DCHECK_CURRENTLY_ON(content::BrowserThread::UI);
#if defined(OS_CHROMEOS) #if defined(OS_CHROMEOS)
......
...@@ -2,8 +2,8 @@ ...@@ -2,8 +2,8 @@
// Use of this source code is governed by a BSD-style license that can be // Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file. // found in the LICENSE file.
#ifndef CHROME_BROWSER_INTERSTITIALS_CHROME_CONTROLLER_CLIENT_H_ #ifndef CHROME_BROWSER_SSL_SSL_ERROR_CONTROLLER_CLIENT_H_
#define CHROME_BROWSER_INTERSTITIALS_CHROME_CONTROLLER_CLIENT_H_ #define CHROME_BROWSER_SSL_SSL_ERROR_CONTROLLER_CLIENT_H_
#include "base/macros.h" #include "base/macros.h"
#include "components/security_interstitials/content/security_interstitial_controller_client.h" #include "components/security_interstitials/content/security_interstitial_controller_client.h"
...@@ -13,16 +13,16 @@ namespace content { ...@@ -13,16 +13,16 @@ namespace content {
class WebContents; class WebContents;
} }
// Provides embedder-specific logic for the security error page controller. // Provides embedder-specific logic for the SSL error page controller.
class ChromeControllerClient class SSLErrorControllerClient
: public security_interstitials::SecurityInterstitialControllerClient { : public security_interstitials::SecurityInterstitialControllerClient {
public: public:
ChromeControllerClient( SSLErrorControllerClient(
content::WebContents* web_contents, content::WebContents* web_contents,
const net::SSLInfo& ssl_info, const net::SSLInfo& ssl_info,
const GURL& request_url, const GURL& request_url,
std::unique_ptr<security_interstitials::MetricsHelper> metrics_helper); std::unique_ptr<security_interstitials::MetricsHelper> metrics_helper);
~ChromeControllerClient() override; ~SSLErrorControllerClient() override;
// security_interstitials::ControllerClient overrides // security_interstitials::ControllerClient overrides
void GoBack() override; void GoBack() override;
...@@ -34,7 +34,7 @@ class ChromeControllerClient ...@@ -34,7 +34,7 @@ class ChromeControllerClient
const net::SSLInfo ssl_info_; const net::SSLInfo ssl_info_;
const GURL request_url_; const GURL request_url_;
DISALLOW_COPY_AND_ASSIGN(ChromeControllerClient); DISALLOW_COPY_AND_ASSIGN(SSLErrorControllerClient);
}; };
#endif // CHROME_BROWSER_INTERSTITIALS_CHROME_CONTROLLER_CLIENT_H_ #endif // CHROME_BROWSER_SSL_SSL_ERROR_CONTROLLER_CLIENT_H_
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment