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

Side by Side Diff: chrome/browser/ssl/ssl_error_handler.h

Issue 1772143002: Use network time for bad clock interstitial. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: pass "gn check out/Default" Created 4 years, 9 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 | « chrome/browser/ssl/ssl_browser_tests.cc ('k') | chrome/browser/ssl/ssl_error_handler.cc » ('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 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 #ifndef CHROME_BROWSER_SSL_SSL_ERROR_HANDLER_H_ 5 #ifndef CHROME_BROWSER_SSL_SSL_ERROR_HANDLER_H_
6 #define CHROME_BROWSER_SSL_SSL_ERROR_HANDLER_H_ 6 #define CHROME_BROWSER_SSL_SSL_ERROR_HANDLER_H_
7 7
8 #include <string> 8 #include <string>
9 9
10 #include "base/callback_forward.h" 10 #include "base/callback_forward.h"
11 #include "base/macros.h" 11 #include "base/macros.h"
12 #include "base/timer/timer.h" 12 #include "base/timer/timer.h"
13 #include "chrome/browser/chrome_notification_types.h" 13 #include "chrome/browser/chrome_notification_types.h"
14 #include "chrome/browser/profiles/profile.h" 14 #include "chrome/browser/profiles/profile.h"
15 #include "chrome/browser/ssl/common_name_mismatch_handler.h" 15 #include "chrome/browser/ssl/common_name_mismatch_handler.h"
16 #include "chrome/browser/ssl/ssl_cert_reporter.h" 16 #include "chrome/browser/ssl/ssl_cert_reporter.h"
17 #include "components/ssl_errors/error_classification.h"
17 #include "content/public/browser/notification_observer.h" 18 #include "content/public/browser/notification_observer.h"
18 #include "content/public/browser/notification_registrar.h" 19 #include "content/public/browser/notification_registrar.h"
19 #include "content/public/browser/web_contents_observer.h" 20 #include "content/public/browser/web_contents_observer.h"
20 #include "content/public/browser/web_contents_user_data.h" 21 #include "content/public/browser/web_contents_user_data.h"
21 #include "net/ssl/ssl_info.h" 22 #include "net/ssl/ssl_info.h"
22 #include "url/gurl.h" 23 #include "url/gurl.h"
23 24
24 class CommonNameMismatchHandler; 25 class CommonNameMismatchHandler;
25 class Profile; 26 class Profile;
26 27
(...skipping 64 matching lines...) Expand 10 before | Expand all | Expand 10 after
91 // These are virtual for tests: 92 // These are virtual for tests:
92 virtual void CheckForCaptivePortal(); 93 virtual void CheckForCaptivePortal();
93 virtual bool GetSuggestedUrl(const std::vector<std::string>& dns_names, 94 virtual bool GetSuggestedUrl(const std::vector<std::string>& dns_names,
94 GURL* suggested_url) const; 95 GURL* suggested_url) const;
95 virtual void CheckSuggestedUrl(const GURL& suggested_url); 96 virtual void CheckSuggestedUrl(const GURL& suggested_url);
96 virtual void NavigateToSuggestedURL(const GURL& suggested_url); 97 virtual void NavigateToSuggestedURL(const GURL& suggested_url);
97 virtual bool IsErrorOverridable() const; 98 virtual bool IsErrorOverridable() const;
98 virtual void ShowCaptivePortalInterstitial(const GURL& landing_url); 99 virtual void ShowCaptivePortalInterstitial(const GURL& landing_url);
99 virtual void ShowSSLInterstitial(); 100 virtual void ShowSSLInterstitial();
100 101
101 void ShowBadClockInterstitial(const base::Time& now); 102 void ShowBadClockInterstitial(const base::Time& now,
103 ssl_errors::ClockState clock_state);
102 104
103 // Gets the result of whether the suggested URL is valid. Displays 105 // Gets the result of whether the suggested URL is valid. Displays
104 // common name mismatch interstitial or ssl interstitial accordingly. 106 // common name mismatch interstitial or ssl interstitial accordingly.
105 void CommonNameMismatchHandlerCallback( 107 void CommonNameMismatchHandlerCallback(
106 const CommonNameMismatchHandler::SuggestedUrlCheckResult& result, 108 const CommonNameMismatchHandler::SuggestedUrlCheckResult& result,
107 const GURL& suggested_url); 109 const GURL& suggested_url);
108 110
109 private: 111 private:
110 // content::NotificationObserver: 112 // content::NotificationObserver:
111 void Observe( 113 void Observe(
(...skipping 25 matching lines...) Expand all
137 base::OneShotTimer timer_; 139 base::OneShotTimer timer_;
138 140
139 scoped_ptr<CommonNameMismatchHandler> common_name_mismatch_handler_; 141 scoped_ptr<CommonNameMismatchHandler> common_name_mismatch_handler_;
140 142
141 scoped_ptr<SSLCertReporter> ssl_cert_reporter_; 143 scoped_ptr<SSLCertReporter> ssl_cert_reporter_;
142 144
143 DISALLOW_COPY_AND_ASSIGN(SSLErrorHandler); 145 DISALLOW_COPY_AND_ASSIGN(SSLErrorHandler);
144 }; 146 };
145 147
146 #endif // CHROME_BROWSER_SSL_SSL_ERROR_HANDLER_H_ 148 #endif // CHROME_BROWSER_SSL_SSL_ERROR_HANDLER_H_
OLDNEW
« no previous file with comments | « chrome/browser/ssl/ssl_browser_tests.cc ('k') | chrome/browser/ssl/ssl_error_handler.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698