From 45e2322598e041bd7d0d57b71f04f68c409854ac Mon Sep 17 00:00:00 2001 From: Mike West Date: Fri, 15 Jul 2016 21:21:28 +0200 Subject: [PATCH] Upstream SharedWorker constructor changes from Secure Contexts Monkey-patches bad. Upstreaming good. Closes w3c/webappsec-secure-contexts#31. --- source | 22 ++++++++++++++++++++-- 1 file changed, 20 insertions(+), 2 deletions(-) diff --git a/source b/source index 08a34414261..03fd947e3b3 100644 --- a/source +++ b/source @@ -3936,6 +3936,18 @@ a.setAttribute('href', 'http://example.com/'); // change the content attribute d +
Secure Contexts
+ +
+ +

The following term is defined in Secure Contexts:

+ + + +
MathML
@@ -97062,11 +97074,17 @@ interface SharedWorker : EventTarget {

If worker global scope is not null, then run these steps:

    -
  1. Associate worker with worker global scope.

  2. -
  3. Let settings object be the relevant settings object for worker global scope.

  4. +
  5. If the result of executing Is environment settings object a secure + context? on outside settings does not match the result of executing + the same algorithm on settings object, then throw a + "SecurityError" DOMException and abort these steps. +

  6. + +
  7. Associate worker with worker global scope.

  8. +
  9. Create a new MessagePort object whose owner is settings object. Let this be the inside port.