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

Unified Diff: content/browser/appcache/appcache_update_job.cc

Issue 725573004: Do not AppCache responses with SSL cert errors unless running with the --ignore-certificate-errors … (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 1 month 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/browser/appcache/appcache_update_job.cc
diff --git a/content/browser/appcache/appcache_update_job.cc b/content/browser/appcache/appcache_update_job.cc
index 088d939a6cef331338cc36536bf649f4ab7460e8..1447bbc5fe29c1c0a34752ab3a4e8784f4a6a3d1 100644
--- a/content/browser/appcache/appcache_update_job.cc
+++ b/content/browser/appcache/appcache_update_job.cc
@@ -179,7 +179,12 @@ void AppCacheUpdateJob::URLFetcher::OnResponseStarted(
// requested on the whatwg list.
// See http://code.google.com/p/chromium/issues/detail?id=69594
// TODO(michaeln): Consider doing this for cross-origin HTTP too.
- if (net::IsCertStatusError(request->ssl_info().cert_status) ||
+ const net::HttpNetworkSession::Params* session_params =
+ request->context()->GetNetworkSessionParams();
+ bool ignore_cert_errors = session_params &&
+ session_params->ignore_certificate_errors;
+ if ((net::IsCertStatusError(request->ssl_info().cert_status) &&
+ !ignore_cert_errors) ||
(url_.GetOrigin() != job_->manifest_url_.GetOrigin() &&
request->response_headers()->
HasHeaderValue("cache-control", "no-store"))) {
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698