Skip to content

Commit cc7b5af

Browse files
committed
Augment COEP violation report
- "blocked-url" is renamed to "blockedURL" (whatwg/html#5818). - Added "disposition" (whatwg/html#5391). - Added "destination" (whatwg/html#5391). The CORP check now takes "destination" as a parameter.
1 parent 28e6e68 commit cc7b5af

File tree

1 file changed

+21
-9
lines changed

1 file changed

+21
-9
lines changed

fetch.bs

+21-9
Original file line numberDiff line numberDiff line change
@@ -3232,9 +3232,9 @@ Cross-Origin-Resource-Policy = %s"same-origin" / %s"same-site" / %s"cross-or
32323232
</code></pre>
32333233

32343234
<p>To perform a <dfn export>cross-origin resource policy check</dfn>, given an <a for=url>origin</a>
3235-
<var>origin</var>, an <a for=/>environment settings object</a> <var>settingsObject</var>, a
3236-
<a for=/>response</a> <var>response</var>, and an optional boolean <var>forNavigation</var>, run
3237-
these steps:
3235+
<var>origin</var>, an <a for=/>environment settings object</a> <var>settingsObject</var>, a string
3236+
<var>destination</var>, a <a for=/>response</a> <var>response</var>, and an optional boolean
3237+
<var>forNavigation</var>, run these steps:
32383238

32393239
<ol>
32403240
<li><p>Set <var>forNavigation</var> to false if it is not given.
@@ -3254,14 +3254,14 @@ these steps:
32543254
<var>embedderPolicy</var>'s <a for="embedder policy">report only value</a>, <var>response</var>,
32553255
and <var>forNavigation</var> returns <b>blocked</b>, then
32563256
<a>queue a cross-origin embedder policy CORP violation report</a> with <var>response</var>,
3257-
<var>settingsObject</var>, and true.
3257+
<var>settingsObject</var>, <var>destination</var>, and true.
32583258

32593259
<li><p>If the <a>cross-origin resource policy internal check</a> with <var>origin</var>,
32603260
<var>embedderPolicy</var>'s <a for="embedder policy">value</a>, <var>response</var>, and
32613261
<var>forNavigation</var> returns <b>allowed</b>, then return <b>allowed</b>.
32623262

32633263
<li><p><a>Queue a cross-origin embedder policy CORP violation report</a> with <var>response</var>,
3264-
<var>settingsObject</var>, and false.
3264+
<var>settingsObject</var>, <var>destination</var>, and false.
32653265

32663266
<li><p>Return <b>blocked</b>.
32673267
</ol>
@@ -3341,7 +3341,8 @@ these steps:
33413341

33423342
<p>To <dfn>queue a cross-origin embedder policy CORP violation report</dfn>, given a
33433343
<a for=/>response</a> <var>response</var>, an <a for=/>environment settings object</a>
3344-
<var>settingsObject</var>, and a boolean <var>reportOnly</var>, run these steps:
3344+
<var>settingsObject</var>, a string <var>destination</var>, and a boolean <var>reportOnly</var>,
3345+
run these steps:
33453346

33463347
<ol>
33473348
<li><p>Let <var>endpoint</var> be <var>settingsObject</var>'s
@@ -3350,10 +3351,13 @@ these steps:
33503351
<var>settingsObject</var>'s <a for="environment settings object">embedder policy</a>'s
33513352
<a for="embedder policy">reporting endpoint</a> otherwise.
33523353

3353-
<li><p>Let <var>serialized url</var> be the result of
3354+
<li><p>Let <var>serializedURL</var> be the result of
33543355
<a lt="serialize a response URL for reporting">serializing a response URL for reporting</a> with
33553356
<var>response</var>.
33563357

3358+
<li><p>Let <var>disposition</var> be "<code>reporting</code>" if <var>reportOnly</var> is true,
3359+
and "<code>enforce</code>" otherwise.
3360+
33573361
<li>
33583362
<p>Let <var>body</var> be a new object containing the following properties:
33593363

@@ -3368,8 +3372,16 @@ these steps:
33683372
<td>"<code>corp</code>"
33693373
</tr>
33703374
<tr>
3371-
<td>"<code>blocked-url</code>"
3372-
<td><var>serialized url</var>
3375+
<td>"<code>blockedURL</code>"
3376+
<td><var>serializedURL</var>
3377+
</tr>
3378+
<tr>
3379+
<td>"<code>destination</code>"
3380+
<td><var>destination</var>
3381+
</tr>
3382+
<tr>
3383+
<td>"<code>disposition</code>"
3384+
<td><var>disposition</var>
33733385
</tr>
33743386
</tbody>
33753387
</table>

0 commit comments

Comments
 (0)