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

Unified Diff: chrome/browser/chrome_content_browser_client.cc

Issue 450833002: Add additional UMA stats for remembering certificate decisions. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebase on ToT Created 6 years, 4 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/browser/chrome_content_browser_client.h ('k') | chrome/browser/ssl/chrome_ssl_host_state_delegate.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/chrome_content_browser_client.cc
diff --git a/chrome/browser/chrome_content_browser_client.cc b/chrome/browser/chrome_content_browser_client.cc
index cade2e0bcaf9e93155faa8ba539a7f2049a8b04f..f10e0ae6253bb435d011744ccb466efef002ce0e 100644
--- a/chrome/browser/chrome_content_browser_client.cc
+++ b/chrome/browser/chrome_content_browser_client.cc
@@ -1684,6 +1684,7 @@ void ChromeContentBrowserClient::AllowCertificateError(
ResourceType resource_type,
bool overridable,
bool strict_enforcement,
+ bool expired_previous_decision,
const base::Callback<void(bool)>& callback,
content::CertificateRequestResultType* result) {
if (resource_type != content::RESOURCE_TYPE_MAIN_FRAME) {
@@ -1721,9 +1722,15 @@ void ChromeContentBrowserClient::AllowCertificateError(
// Otherwise, display an SSL blocking page. The interstitial page takes
// ownership of ssl_blocking_page.
+ int options_mask = 0;
+ if (overridable)
+ options_mask = SSLBlockingPage::OVERRIDABLE;
+ if (strict_enforcement)
+ options_mask = SSLBlockingPage::STRICT_ENFORCEMENT;
+ if (expired_previous_decision)
+ options_mask = SSLBlockingPage::EXPIRED_BUT_PREVIOUSLY_ALLOWED;
SSLBlockingPage* ssl_blocking_page = new SSLBlockingPage(
- tab, cert_error, ssl_info, request_url, overridable,
- strict_enforcement, callback);
+ tab, cert_error, ssl_info, request_url, options_mask, callback);
ssl_blocking_page->Show();
}
« no previous file with comments | « chrome/browser/chrome_content_browser_client.h ('k') | chrome/browser/ssl/chrome_ssl_host_state_delegate.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698