@@ -28,6 +28,9 @@ spec:html
28
28
text: plugin document
29
29
text: fallback base url
30
30
text: duplicate-attribute
31
+ text: create navigation params by fetching
32
+ text: attempt to populate the history entry's document
33
+ text: plugin
31
34
type: element
32
35
text: a
33
36
text: link
@@ -123,11 +126,12 @@ spec: HTML; urlPrefix: https://html.spec.whatwg.org/
123
126
for: script
124
127
text: "parser-inserted"
125
128
text: origin; url: concept-origin
126
- text: browsing context; url: browsing-context
127
129
text: content security policy state; url: attr-meta-http-equiv-content-security-policy
128
130
text: create and initialize a new document object; url: initialise-the-document-object
129
131
text: initializing a new Document object; url: initialise-the-document-object
130
132
text: prepare the script element; url: prepare-the-script-element
133
+ text: container document; for: navigable; url: nav-container-document
134
+ text: CSP-derived sandboxing flags; url: csp-derived-sandboxing-flags
131
135
132
136
spec: INFRA; urlPrefix: https://infra.spec.whatwg.org/
133
137
type: grammar
@@ -625,7 +629,7 @@ spec: WebRTC; urlPrefix: https://www.w3.org/TR/webrtc/
625
629
626
630
6. A <dfn for="directive" export>navigation response check</dfn> , which takes a
627
631
<a for="/">request</a> , a navigation type string ("`form-submission`" or "`other`"),
628
- a <a>response</a> , a <a>browsing context </a> , a check type string ("`source`"
632
+ a <a>response</a> , a <a>navigable </a> , a check type string ("`source`"
629
633
or "`response`"), and a <a for="/">policy</a> as arguments, and is executed during
630
634
[[#should-block-navigation-response]] . It returns "`Allowed`" unless otherwise specified.
631
635
@@ -1145,15 +1149,17 @@ spec: WebRTC; urlPrefix: https://www.w3.org/TR/webrtc/
1145
1149
base URL</a> algorithm to ensure that the <{base/href}> attribute's value
1146
1150
is valid.
1147
1151
1148
- 10. [[#should-block-navigation-request]] is called during the <a>process a
1149
- navigate fetch </a> algorithm, and [[#should-block-navigation-response]]
1150
- is called during the <a>process a navigate response </a> algorithm to
1152
+ 10. [[#should-block-navigation-request]] is called during the <a>create navigation params
1153
+ by fetching </a> algorithm, and [[#should-block-navigation-response]]
1154
+ is called during the <a>attempt to populate the history entry's document </a> algorithm to
1151
1155
apply directive's navigation checks, as well as inline checks for
1152
1156
navigations to `javascript:` URLs.
1153
1157
1154
1158
11. [[#run-global-object-csp-initialization]] is called during the <a>run a worker</a>
1155
1159
algorithm.
1156
1160
1161
+ 12. The <a>sandbox</a> directive is used to populate the <a>CSP-derived sandboxing flags</a> .
1162
+
1157
1163
<h4 id="run-document-csp-initialization" algorithm dfn export>
1158
1164
Run `CSP` initialization for a `Document`
1159
1165
</h4>
@@ -1310,7 +1316,7 @@ spec: WebRTC; urlPrefix: https://www.w3.org/TR/webrtc/
1310
1316
1311
1317
Given a <a for="/">request</a> (|navigation request|), a <a>response</a> |navigation
1312
1318
response|, a [=/CSP list=] |response CSP list|, a string (|type|, either
1313
- "`form-submission`" or "`other`"), and a <a>browsing context </a> |target|, this algorithm
1319
+ "`form-submission`" or "`other`"), and a <a>navigable </a> |target|, this algorithm
1314
1320
returns "`Blocked`" if the active policy blocks the navigation, and "`Allowed`"
1315
1321
otherwise:
1316
1322
@@ -1947,8 +1953,8 @@ this algorithm returns normally if compilation is allowed, and throws a
1947
1953
1948
1954
<h4 id="directive-child-src">`child-src`</h4>
1949
1955
1950
- The <dfn export>`child-src`</dfn> directive governs the creation of <a>nested browsing
1951
- contexts </a> (e.g. <{iframe}> and <{frame}> navigations) and Worker execution
1956
+ The <dfn export>`child-src`</dfn> directive governs the creation of <a>child
1957
+ navigables </a> (e.g. <{iframe}> and <{frame}> navigations) and Worker execution
1952
1958
contexts. The syntax for the directive's name and value is described by the
1953
1959
following ABNF:
1954
1960
@@ -2339,7 +2345,7 @@ this algorithm returns normally if compilation is allowed, and throws a
2339
2345
<h4 id="directive-frame-src">`frame-src`</h4>
2340
2346
2341
2347
The <dfn export>frame-src</dfn> directive restricts the URLs which may be loaded into
2342
- <a>nested browsing contexts </a> . The syntax for the directive's name and value
2348
+ <a>child navigables </a> . The syntax for the directive's name and value
2343
2349
is described by the following ABNF:
2344
2350
2345
2351
<pre>
@@ -2646,16 +2652,16 @@ this algorithm returns normally if compilation is allowed, and throws a
2646
2652
2647
2653
Note: The `object-src` directive acts upon any request made on behalf of
2648
2654
an <{object}> or <{embed}> element. This includes requests
2649
- which would populate the <a>nested browsing context </a> generated by the
2655
+ which would populate the <a>child navigable </a> generated by the
2650
2656
former two (also including navigations). This is true even when the data is
2651
2657
semantically equivalent to content which would otherwise be restricted by
2652
2658
another directive, such as an <{object}> element with a `text/html` MIME
2653
2659
type.
2654
2660
2655
- Note: When a plugin resource is navigated to directly (that is, as a <a>plugin document </a> in the
2656
- <a>top-level browsing context</a> or a <a>nested browsing context </a> , and not as an embedded
2661
+ Note: When a plugin resource is navigated to directly (that is, as a <a>plugin</a>
2662
+ inside a <a>navigable </a> , and not as an embedded
2657
2663
subresource via <{embed}> or <{object}> ), any <a for="/">policy</a> delivered along
2658
- with that resource will be applied to the <a>plugin document</a> . This means, for instance, that
2664
+ with that resource will be applied to the resulting <a>document</a> . This means, for instance, that
2659
2665
developers can prevent the execution of arbitrary resources as plugin content by delivering the
2660
2666
policy `object-src 'none' ` along with a response. Given plugins' power (and the
2661
2667
sometimes-interesting security model presented by Flash and others), this could mitigate the risk
@@ -3467,35 +3473,32 @@ this algorithm returns normally if compilation is allowed, and throws a
3467
3473
</h5>
3468
3474
3469
3475
This directive's <a for="directive">initialization</a> algorithm is
3470
- responsible for adjusting a {{Document}} 's <a>forced sandboxing flag set</a>
3471
- and for checking whether a worker is allowed to run according to the <a>`sandbox`</a>
3472
- values present in its policies as follows:
3476
+ responsible for checking whether a worker is allowed to run according
3477
+ to the <a>`sandbox`</a> values present in its policies as follows:
3478
+
3479
+ Note: The <a>sandbox</a> directive is also responsible for adjusting a
3480
+ {{Document}} 's <a for=Document>active sandboxing flag set</a> via the
3481
+ <a>CSP-derived sandboxing flags</a> .
3473
3482
3474
3483
Given a {{Document}} or <a for="/">global object</a> (|context|) and a <a for="/">policy</a>
3475
3484
(|policy|):
3476
3485
3477
3486
1. If |policy|'s <a for="policy">disposition</a> is not "`enforce`", or
3478
- |context| is a {{WorkletGlobalScope }} , then abort this algorithm.
3487
+ |context| is not a {{WorkerGlobalScope }} , then abort this algorithm.
3479
3488
3480
3489
2. Let |sandboxing flag set| be a new [=/sandboxing flag set=] .
3481
3490
3482
3491
3. <a>Parse a sandboxing directive</a> using this directive's <a
3483
3492
for="directive"> value</a> as the input, and |sandboxing flag set| as the output.
3484
3493
3485
- 4. If |context| is a {{WorkerGlobalScope}} :
3486
-
3487
- 1. If |sandboxing flag set| contains either the <a>sandboxed scripts browsing
3488
- context flag</a> or the <a>sandboxed origin browsing context flag</a> flags,
3489
- return "`Blocked`".
3494
+ 4. If |sandboxing flag set| contains either the <a>sandboxed scripts browsing context
3495
+ flag</a> or the <a>sandboxed origin browsing context flag</a> flags,
3496
+ return "`Blocked`".
3490
3497
3491
- Note: This will need to change if we allow Workers to be sandboxed into unique
3492
- origins, which seems like a pretty reasonable thing to do.
3498
+ Note: This will need to change if we allow Workers to be sandboxed into unique
3499
+ origins, which seems like a pretty reasonable thing to do.
3493
3500
3494
- 5. If |context| is a {{Document}} :
3495
-
3496
- 1. Set |context|'s <a>forced sandboxing flag set</a> to |sandboxing flag set|.
3497
-
3498
- 6. Return "`Allowed`".
3501
+ 5. Return "`Allowed`".
3499
3502
3500
3503
<h3 id="directives-navigation">
3501
3504
Navigation Directives
@@ -3564,7 +3567,7 @@ this algorithm returns normally if compilation is allowed, and throws a
3564
3567
3565
3568
Given a <a for="/">request</a> (|request|), a string |navigation type|
3566
3569
("`form-submission`" or "`other`"), a
3567
- <a>response</a> (|navigation response|) a <a>browsing context </a> (|target|),
3570
+ <a>response</a> (|navigation response|) a <a>navigable </a> (|target|),
3568
3571
a string |check type| ("`source`" or "`response`"), and a
3569
3572
<a for="/">policy</a> (|policy|) this algorithm returns "`Blocked`" if one or
3570
3573
more of the ancestors of |target| violate the `frame-ancestors` directive
@@ -3581,16 +3584,16 @@ this algorithm returns normally if compilation is allowed, and throws a
3581
3584
3. If |check type| is "`source`", return "`Allowed`".
3582
3585
3583
3586
Note: The 'frame-ancestors' <a>directive</a> is relevant only to the
3584
- |target| <a>browsing context </a> and it has no impact on the |request|'s
3587
+ |target| <a>navigable </a> and it has no impact on the |request|'s
3585
3588
context.
3586
3589
3587
- 4. If |target| is not a <a>nested browsing context </a> , return "`Allowed`".
3590
+ 4. If |target| is not a <a>child navigable </a> , return "`Allowed`".
3588
3591
3589
3592
5. Let |current| be |target|.
3590
3593
3591
- 6. While |current| is a <a>nested browsing context </a> :
3594
+ 6. While |current| is a <a>child navigable </a> :
3592
3595
3593
- 1. Let |document| be |current|'s [=browsing context /container document=] .
3596
+ 1. Let |document| be |current|'s [=navigable /container document=] .
3594
3597
3595
3598
2. Let |origin| be the result of executing the <a>URL parser</a> on the
3596
3599
<a lt="ASCII serialization of an origin">ASCII serialization</a>
@@ -3600,7 +3603,7 @@ this algorithm returns normally if compilation is allowed, and throws a
3600
3603
executed upon |origin|, this directive's <a for="directive">value</a> ,
3601
3604
|policy|'s [=policy/self-origin=] , and `0`, return "`Blocked`".
3602
3605
3603
- 4. Set |current| to |document|'s <a>browsing context </a> .
3606
+ 4. Set |current| to |document|'s <a>navigable </a> .
3604
3607
3605
3608
7. Return "`Allowed`".
3606
3609
</ol>
@@ -4712,7 +4715,7 @@ this algorithm returns normally if compilation is allowed, and throws a
4712
4715
</h3>
4713
4716
4714
4717
Documents loaded from <a>local schemes</a> will inherit a copy of the
4715
- policies in the <a> source browsing context</a> . The goal is to ensure that a page can't
4718
+ policies in the source document . The goal is to ensure that a page can't
4716
4719
bypass its policy by embedding a frame or opening a new window containing
4717
4720
content that is entirely under its control (`srcdoc` documents, `blob:` or `data:`
4718
4721
URLs, `about:blank` documents that can be manipulated via `document.write()`, etc).
@@ -4730,7 +4733,7 @@ this algorithm returns normally if compilation is allowed, and throws a
4730
4733
means that the new {{Document}} 's <a for="global object">CSP list</a> is a
4731
4734
snapshot of the relevant policies at its creation time. Modifications in the
4732
4735
<a for="global object">CSP list</a> of the new {{Document}} won't affect the
4733
- <a> source browsing context</a> 's <a for="global object">CSP list</a> or vice-versa.
4736
+ source {{Document}} 's <a for="global object">CSP list</a> or vice-versa.
4734
4737
4735
4738
<div class="example">
4736
4739
In the example below the image inside the iframe will not load because it is
0 commit comments