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

Unified Diff: chrome/browser/ssl/ssl_blocking_page.cc

Issue 1119963004: Extend the enterprise policy for SSL overrides to the "danger" command (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Remove parens Created 5 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/browser/ssl/ssl_blocking_page.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ssl/ssl_blocking_page.cc
diff --git a/chrome/browser/ssl/ssl_blocking_page.cc b/chrome/browser/ssl/ssl_blocking_page.cc
index 46ad971efae26dd6142ab724d1af302275e9c338..e62514f49e8e315c836701441595d75255bfae2f 100644
--- a/chrome/browser/ssl/ssl_blocking_page.cc
+++ b/chrome/browser/ssl/ssl_blocking_page.cc
@@ -251,7 +251,8 @@ SSLBlockingPage::SSLBlockingPage(content::WebContents* web_contents,
overridable_(IsOverridable(
options_mask,
Profile::FromBrowserContext(web_contents->GetBrowserContext()))),
- danger_overridable_(true),
+ danger_overridable_(DoesPolicyAllowDangerOverride(
+ Profile::FromBrowserContext(web_contents->GetBrowserContext()))),
strict_enforcement_((options_mask & STRICT_ENFORCEMENT) != 0),
expired_but_previously_allowed_(
(options_mask & EXPIRED_BUT_PREVIOUSLY_ALLOWED) != 0),
@@ -713,3 +714,9 @@ bool SSLBlockingPage::IsOverridable(int options_mask,
profile->GetPrefs()->GetBoolean(prefs::kSSLErrorOverrideAllowed);
return is_overridable;
}
+
+// static
+bool SSLBlockingPage::DoesPolicyAllowDangerOverride(
+ const Profile* const profile) {
+ return profile->GetPrefs()->GetBoolean(prefs::kSSLErrorOverrideAllowed);
+}
« no previous file with comments | « chrome/browser/ssl/ssl_blocking_page.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698