Chromium Code Reviews| Index: chrome/browser/ssl/bad_clock_blocking_page.h |
| diff --git a/chrome/browser/ssl/bad_clock_blocking_page.h b/chrome/browser/ssl/bad_clock_blocking_page.h |
| index 592dae869963f86a1c1b6913fcf722576dd343bd..b75646d7b8c8e10eb6c208e0088bc6ad6b45ff13 100644 |
| --- a/chrome/browser/ssl/bad_clock_blocking_page.h |
| +++ b/chrome/browser/ssl/bad_clock_blocking_page.h |
| @@ -11,22 +11,24 @@ |
| #include "base/time/time.h" |
| #include "chrome/browser/interstitials/security_interstitial_page.h" |
| #include "chrome/browser/ssl/ssl_cert_reporter.h" |
| +#include "components/security_interstitials/core/bad_clock_ui.h" |
| #include "net/ssl/ssl_info.h" |
| class CertReportHelper; |
| class GURL; |
| -// This class is responsible for showing/hiding the interstitial page that is |
| -// shown when a certificate error happens. This error is not overridable. |
| -// It deletes itself when the interstitial page is closed. |
| +// This class is responsible for showing/hiding the interstitial page that |
| +// occurs when an SSL error is triggered by a clock misconfiguration. It |
| +// creates the UI using security_interstitials::BadClockUI and then |
| +// displays it. It deletes itself when the interstitial page is closed. |
| class BadClockBlockingPage : public SecurityInterstitialPage { |
| public: |
| // Interstitial type, used in tests. |
| static InterstitialPageDelegate::TypeID kTypeForTesting; |
| - // Creates a bad clock interstitial. If the blocking page isn't shown, the |
| - // caller is responsible for cleaning up the blocking page, otherwise the |
| - // interstitial takes ownership when shown. |
| + // If the blocking page isn't shown, the caller is responsible for cleaning |
| + // up the blocking page. Otherwise, the interstitial takes ownership when |
| + // shown. |
| BadClockBlockingPage(content::WebContents* web_contents, |
| int cert_error, |
| const net::SSLInfo& ssl_info, |
| @@ -44,7 +46,7 @@ class BadClockBlockingPage : public SecurityInterstitialPage { |
| scoped_ptr<SSLCertReporter> ssl_cert_reporter); |
| protected: |
| - // InterstitialPageDelegate implementation. |
| + // InterstitialPageDelegate implementation: |
| void CommandReceived(const std::string& command) override; |
| void OverrideEntry(content::NavigationEntry* entry) override; |
| void OverrideRendererPrefs(content::RendererPreferences* prefs) override; |
| @@ -54,6 +56,7 @@ class BadClockBlockingPage : public SecurityInterstitialPage { |
| bool ShouldCreateNewNavigation() const override; |
| void PopulateInterstitialStrings( |
| base::DictionaryValue* load_time_data) override; |
| + void AfterShow() override; |
| private: |
| void NotifyDenyCertificate(); |
| @@ -61,11 +64,10 @@ class BadClockBlockingPage : public SecurityInterstitialPage { |
| base::Callback<void(bool)> callback_; |
| const int cert_error_; |
| const net::SSLInfo ssl_info_; |
| - |
| - // The time at which the interstitial was triggered. The interstitial |
| - // calculates all times relative to this. |
| const base::Time time_triggered_; |
|
estark
2015/12/01 18:40:17
Did you mean to drop the comment on this?
felt
2015/12/01 19:13:45
I didn't think it added anything. It's named time_
estark
2015/12/01 21:41:50
ok, makes sense, just wanted to make sure it wasn'
|
| + scoped_ptr<ChromeControllerClient> controller_; |
| + scoped_ptr<security_interstitials::BadClockUI> bad_clock_ui_; |
| scoped_ptr<CertReportHelper> cert_report_helper_; |
| DISALLOW_COPY_AND_ASSIGN(BadClockBlockingPage); |