Chromium Code Reviews| Index: chrome/browser/ui/website_settings/website_settings.cc |
| diff --git a/chrome/browser/ui/website_settings/website_settings.cc b/chrome/browser/ui/website_settings/website_settings.cc |
| index f93484c1b45f5fe647db6ec31130765d0f6b10d1..28ec72094045c29feb412aed1f666091e2141aa7 100644 |
| --- a/chrome/browser/ui/website_settings/website_settings.cc |
| +++ b/chrome/browser/ui/website_settings/website_settings.cc |
| @@ -32,6 +32,7 @@ |
| #include "chrome/common/content_settings_pattern.h" |
| #include "content/public/browser/browser_thread.h" |
| #include "content/public/browser/cert_store.h" |
| +#include "content/public/browser/ssl_host_state_delegate.h" |
| #include "content/public/browser/user_metrics.h" |
| #include "content/public/common/content_switches.h" |
| #include "content/public/common/ssl_status.h" |
| @@ -532,6 +533,12 @@ void WebsiteSettings::Init(Profile* profile, |
| } |
| } |
| + // Check if a user decision has been made to allow or deny certificates with |
| + // errors on this site. |
| + content::SSLHostStateDelegate* delegate = profile->GetSSLHostStateDelegate(); |
| + if (delegate) |
|
Peter Kasting
2014/08/11 22:35:41
Is there ever not a delegate? If so, consider not
|
| + have_bypassed_ssl_error_ = delegate->HasUserDecision(url.host()); |
| + |
| // By default select the permissions tab that displays all the site |
| // permissions. In case of a connection error or an issue with the |
| // certificate presented by the website, select the connection tab to draw |
| @@ -665,6 +672,7 @@ void WebsiteSettings::PresentSiteIdentity() { |
| info.signed_certificate_timestamp_ids.assign( |
| signed_certificate_timestamp_ids_.begin(), |
| signed_certificate_timestamp_ids_.end()); |
| + info.have_bypassed_ssl_error = have_bypassed_ssl_error_; |
| ui_->SetIdentityInfo(info); |
| } |