Skip to content

[worklets] Add initialization of CSP list. #467

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Sep 1, 2017
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 16 additions & 1 deletion worklets/Overview.bs
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@ Editor: Ian Kilpatrick, ikilpatrick@chromium.org
<pre class=link-defaults>
spec:fetch; type:dfn; for:/; text:fetch
spec:html; type:dfn; for:/; text:browsing context
spec:html; type:interface; for:/; text:Document
spec:html; type:dfn; for:environment settings object;
text: global object
text: https state
Expand All @@ -49,6 +50,9 @@ urlPrefix: https://html.spec.whatwg.org/multipage/webappapis.html; type: dfn;
text: event loop processing model
text: microtask queue
text: task queues
text: discarded; url: a-browsing-context-is-discarded
urlPrefix: https://w3c.github.io/webappsec-csp/#; type: dfn;
text: initialize a global object's CSP list; url: initialize-global-object-csp
urlPrefix: http://www.ecma-international.org/ecma-262/6.0/#sec-; type: dfn;
text: Construct
text: InitializeHostDefinedRealm
Expand Down Expand Up @@ -134,6 +138,12 @@ interface WorkletGlobalScope {
};
</pre>

Each {{WorkletGlobalScope}} has an assocated <dfn for=WorkletGlobalScope>owner document</dfn>. It is
initially null and set inside the <a>create a WorkletGlobalScope</a> algorithm.

Whenever a {{Document}} object is <a>discarded</a>, each {{WorkletGlobalScope}} whose <a>owner
document</a> is that {{Document}} object, should clear its <a>owner document</a>.

Each {{WorkletGlobalScope}} has an associated <a>environment settings object</a>.

Each {{WorkletGlobalScope}} has an associated <dfn for=WorkletGlobalScope>module map</dfn>. It is a
Expand Down Expand Up @@ -194,7 +204,12 @@ When a user agent is to <dfn>create a WorkletGlobalScope</dfn>, given |workletGl

4. Associate the |insideSettings| with |workletGlobalScope|.

5. For each |entry| in the given |moduleResponsesMap| (in insertion order), run the following
5. Set |workletGlobalScope|'s <a>owner document</a> to |outsideSettings|'s <a>responsible
document</a>.

6. Invoke the <a>initialize a global object's CSP list</a> algorithm given |workletGlobalScope|.

7. For each |entry| in the given |moduleResponsesMap| (in insertion order), run the following
substeps:

1. Let |moduleURLRecord| be |entry|'s key.
Expand Down