| OLD | NEW |
| 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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 #include "chrome/browser/ssl/ssl_policy_backend.h" | 5 #include "chrome/browser/ssl/ssl_policy_backend.h" |
| 6 | 6 |
| 7 #include "app/resource_bundle.h" | 7 #include "app/resource_bundle.h" |
| 8 #include "chrome/browser/profile.h" | 8 #include "chrome/browser/profile.h" |
| 9 #include "chrome/browser/ssl/ssl_host_state.h" | 9 #include "chrome/browser/ssl/ssl_host_state.h" |
| 10 #include "chrome/browser/tab_contents/infobar_delegate.h" | 10 #include "chrome/browser/tab_contents/infobar_delegate.h" |
| (...skipping 105 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 116 void SSLPolicyBackend::DenyCertForHost(net::X509Certificate* cert, | 116 void SSLPolicyBackend::DenyCertForHost(net::X509Certificate* cert, |
| 117 const std::string& host) { | 117 const std::string& host) { |
| 118 ssl_host_state_->DenyCertForHost(cert, host); | 118 ssl_host_state_->DenyCertForHost(cert, host); |
| 119 } | 119 } |
| 120 | 120 |
| 121 void SSLPolicyBackend::AllowCertForHost(net::X509Certificate* cert, | 121 void SSLPolicyBackend::AllowCertForHost(net::X509Certificate* cert, |
| 122 const std::string& host) { | 122 const std::string& host) { |
| 123 ssl_host_state_->AllowCertForHost(cert, host); | 123 ssl_host_state_->AllowCertForHost(cert, host); |
| 124 } | 124 } |
| 125 | 125 |
| 126 net::X509Certificate::Policy::Judgment SSLPolicyBackend::QueryPolicy( | 126 net::CertPolicy::Judgment SSLPolicyBackend::QueryPolicy( |
| 127 net::X509Certificate* cert, const std::string& host) { | 127 net::X509Certificate* cert, const std::string& host) { |
| 128 return ssl_host_state_->QueryPolicy(cert, host); | 128 return ssl_host_state_->QueryPolicy(cert, host); |
| 129 } | 129 } |
| 130 | 130 |
| 131 void SSLPolicyBackend::ShowPendingMessages() { | 131 void SSLPolicyBackend::ShowPendingMessages() { |
| 132 std::vector<SSLMessageInfo>::const_iterator iter; | 132 std::vector<SSLMessageInfo>::const_iterator iter; |
| 133 for (iter = pending_messages_.begin(); | 133 for (iter = pending_messages_.begin(); |
| 134 iter != pending_messages_.end(); ++iter) { | 134 iter != pending_messages_.end(); ++iter) { |
| 135 ShowMessageWithLink(iter->message, iter->link_text, iter->action); | 135 ShowMessageWithLink(iter->message, iter->link_text, iter->action); |
| 136 } | 136 } |
| 137 ClearPendingMessages(); | 137 ClearPendingMessages(); |
| 138 } | 138 } |
| 139 | 139 |
| 140 void SSLPolicyBackend::ClearPendingMessages() { | 140 void SSLPolicyBackend::ClearPendingMessages() { |
| 141 pending_messages_.clear(); | 141 pending_messages_.clear(); |
| 142 } | 142 } |
| OLD | NEW |