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

Unified Diff: content/browser/service_worker/service_worker_registration.cc

Issue 2071433003: Reland: service worker: Don't control a subframe of an insecure context (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: revised Created 4 years, 6 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 side-by-side diff with in-line comments
Download patch
Index: content/browser/service_worker/service_worker_registration.cc
diff --git a/content/browser/service_worker/service_worker_registration.cc b/content/browser/service_worker/service_worker_registration.cc
index d7fb0b1028c29c10de814da03e1336dfe120bc56..bad9920756875f7466faaebe8ad5b0867f13f9a9 100644
--- a/content/browser/service_worker/service_worker_registration.cc
+++ b/content/browser/service_worker/service_worker_registration.cc
@@ -201,6 +201,8 @@ void ServiceWorkerRegistration::ClaimClients() {
continue;
if (host->controlling_version() == active_version())
continue;
+ if (!host->IsContextSecureForServiceWorker())
+ continue;
if (host->MatchRegistration() == this)
host->ClaimedByRegistration(this);
}

Powered by Google App Engine
This is Rietveld 408576698