Chromium Code Reviews| Index: chrome/browser/ssl/chrome_security_state_model_client.cc |
| diff --git a/chrome/browser/ssl/chrome_security_state_model_client.cc b/chrome/browser/ssl/chrome_security_state_model_client.cc |
| index 5b7097e4b4e89c8b0c8ad8d31ffc030aa4cd8fbe..1db3e3c052e96879422d14e2f0ed1bb29732025b 100644 |
| --- a/chrome/browser/ssl/chrome_security_state_model_client.cc |
| +++ b/chrome/browser/ssl/chrome_security_state_model_client.cc |
| @@ -338,14 +338,17 @@ void ChromeSecurityStateModelClient::VisibleSSLStateChanged() { |
| return; |
| std::string warning; |
| + bool warning_is_user_visible = false; |
| switch (security_info.security_level) { |
| case security_state::SecurityStateModel::HTTP_SHOW_WARNING: |
| warning = |
| "This page includes a password or credit card input in a non-secure " |
| "context. A warning has been added to the URL bar. For more " |
| "information, see https://goo.gl/zmWq3m."; |
| + warning_is_user_visible = true; |
| break; |
| case security_state::SecurityStateModel::NONE: |
| + case security_state::SecurityStateModel::DANGEROUS: |
|
estark
2016/10/26 21:29:46
Two notes about this (no changes needed):
1. One
|
| warning = |
| "This page includes a password or credit card input in a non-secure " |
| "context. A warning will be added to the URL bar in Chrome 56 (Jan " |
| @@ -358,6 +361,8 @@ void ChromeSecurityStateModelClient::VisibleSSLStateChanged() { |
| logged_http_warning_on_current_navigation_ = true; |
| web_contents_->GetMainFrame()->AddMessageToConsole( |
| content::CONSOLE_MESSAGE_LEVEL_WARNING, warning); |
| + UMA_HISTOGRAM_BOOLEAN("Security.HTTPBad.UserWarnedAboutSensitiveInput", |
| + warning_is_user_visible); |
| } |
| void ChromeSecurityStateModelClient::DidFinishNavigation( |