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

Side by Side Diff: content/browser/ssl/ssl_manager.cc

Issue 2226523002: Add separate plumbing for subresources with certificate errors (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fix typo Created 4 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 unified diff | Download patch
« no previous file with comments | « content/browser/ssl/ssl_manager.h ('k') | content/browser/ssl/ssl_policy.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 "content/browser/ssl/ssl_manager.h" 5 #include "content/browser/ssl/ssl_manager.h"
6 6
7 #include <set> 7 #include <set>
8 8
9 #include "base/bind.h" 9 #include "base/bind.h"
10 #include "base/macros.h" 10 #include "base/macros.h"
(...skipping 122 matching lines...) Expand 10 before | Expand all | Expand 10 after
133 // load is committed, in case the active navigation entry has changed. 133 // load is committed, in case the active navigation entry has changed.
134 NotifyDidChangeVisibleSSLState(); 134 NotifyDidChangeVisibleSSLState();
135 } 135 }
136 136
137 void SSLManager::DidRunInsecureContent(const GURL& security_origin) { 137 void SSLManager::DidRunInsecureContent(const GURL& security_origin) {
138 NavigationEntryImpl* navigation_entry = controller_->GetLastCommittedEntry(); 138 NavigationEntryImpl* navigation_entry = controller_->GetLastCommittedEntry();
139 policy()->DidRunInsecureContent(navigation_entry, security_origin); 139 policy()->DidRunInsecureContent(navigation_entry, security_origin);
140 UpdateEntry(navigation_entry); 140 UpdateEntry(navigation_entry);
141 } 141 }
142 142
143 void SSLManager::DidRunContentWithCertificateErrors(
144 const GURL& security_origin) {
145 NavigationEntryImpl* navigation_entry = controller_->GetLastCommittedEntry();
146 policy()->DidRunContentWithCertificateErrors(navigation_entry,
147 security_origin);
148 UpdateEntry(navigation_entry);
149 }
150
143 void SSLManager::DidLoadFromMemoryCache( 151 void SSLManager::DidLoadFromMemoryCache(
144 const LoadFromMemoryCacheDetails& details) { 152 const LoadFromMemoryCacheDetails& details) {
145 // Simulate loading this resource through the usual path. 153 // Simulate loading this resource through the usual path.
146 policy()->OnRequestStarted(details.url, details.cert_id, details.cert_status); 154 policy()->OnRequestStarted(details.url, details.cert_id, details.cert_status);
147 } 155 }
148 156
149 void SSLManager::DidStartResourceResponse( 157 void SSLManager::DidStartResourceResponse(
150 const ResourceRequestDetails& details) { 158 const ResourceRequestDetails& details) {
151 // Notify our policy that we started a resource request. Ideally, the 159 // Notify our policy that we started a resource request. Ideally, the
152 // policy should have the ability to cancel the request, but we can't do 160 // policy should have the ability to cancel the request, but we can't do
(...skipping 25 matching lines...) Expand all
178 NotifyDidChangeVisibleSSLState(); 186 NotifyDidChangeVisibleSSLState();
179 } 187 }
180 188
181 void SSLManager::NotifyDidChangeVisibleSSLState() { 189 void SSLManager::NotifyDidChangeVisibleSSLState() {
182 WebContentsImpl* contents = 190 WebContentsImpl* contents =
183 static_cast<WebContentsImpl*>(controller_->delegate()->GetWebContents()); 191 static_cast<WebContentsImpl*>(controller_->delegate()->GetWebContents());
184 contents->DidChangeVisibleSSLState(); 192 contents->DidChangeVisibleSSLState();
185 } 193 }
186 194
187 } // namespace content 195 } // namespace content
OLDNEW
« no previous file with comments | « content/browser/ssl/ssl_manager.h ('k') | content/browser/ssl/ssl_policy.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698