Skip to content
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

Fix CSP navigation request blocking #10949

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open
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
22 changes: 14 additions & 8 deletions source
Original file line number Diff line number Diff line change
Expand Up @@ -100144,8 +100144,8 @@ location.href = '#foo';</code></pre>
<dd><var>sourceDocument</var>'s <span>relevant settings object</span></dd>

<dt><span data-x="source-snapshot-params-policy-container">source policy container</span></dt>
<dd><var>sourceDocument</var>'s <span data-x="concept-document-policy-container">policy
container</span></dd>
<dd>a <span data-x="clone a policy container">clone</span> of <var>sourceDocument</var>'s <span
data-x="concept-document-policy-container">policy container</span></dd>
</dl>

<hr>
Expand Down Expand Up @@ -100541,8 +100541,9 @@ location.href = '#foo';</code></pre>
<li><p><span>Queue a global task</span> on the <span>navigation and traversal task
source</span> given <var>navigable</var>'s <span data-x="nav-window">active window</span> to
<span>navigate to a <code>javascript:</code> URL</span> given <var>navigable</var>,
<var>url</var>, <var>historyHandling</var>, <var>initiatorOriginSnapshot</var>,
<var>userInvolvement</var>, and <var>cspNavigationType</var>.</p></li>
<var>url</var>, <var>historyHandling</var>, <var>sourceSnapshotParams</var>,
<var>initiatorOriginSnapshot</var>, <var>userInvolvement</var>, and
<var>cspNavigationType</var>.</p></li>

<li><p>Return.</p></li>
</ol>
Expand Down Expand Up @@ -100915,8 +100916,9 @@ location.href = '#foo';</code></pre>

<p>To <dfn>navigate to a <code>javascript:</code> URL</dfn>, given a <span>navigable</span>
<var>targetNavigable</var>, a <span>URL</span> <var>url</var>, a <span>history handling
behavior</span> <var>historyHandling</var>, an <span>origin</span> <var>initiatorOrigin</var>, a
<span>user navigation involvement</span> <var>userInvolvement</var>, and a string
behavior</span> <var>historyHandling</var>, a <span>source snapshot params</span>
<var>sourceSnapshotParams</var>, an <span>origin</span> <var>initiatorOrigin</var>, a <span>user
navigation involvement</span> <var>userInvolvement</var>, and a string
<var>cspNavigationType</var>:</p>

<ol>
Expand All @@ -100938,7 +100940,9 @@ location.href = '#foo';</code></pre>
</li>

<li><p>If the result of <span>should navigation request of type be blocked by Content Security
Policy?</span> given <var>request</var> and <var>cspNavigationType</var> is "<code
Policy?</span> given <var>request</var>, <var>cspNavigationType</var>, and
<var>sourceSnapshotParams</var>'s <span data-x="source-snapshot-params-policy-container">source
policy container</span>'s <span data-x="policy-container-csp-list">CSP list</span> is "<code
data-x="">Blocked</code>", then return. <ref>CSP</ref></p></li>

<li><p>Let <var>newDocument</var> be the result of <span data-x="evaluate a javascript:
Expand Down Expand Up @@ -102782,7 +102786,9 @@ location.href = '#foo';</code></pre>
</li>

<li><p>If the result of <span>should navigation request of type be blocked by Content Security
Policy?</span> given <var>request</var> and <var>cspNavigationType</var> is "<code
Policy?</span> given <var>request</var>, <var>cspNavigationType</var>, and
<var>sourceSnapshotParams</var>'s <span data-x="source-snapshot-params-policy-container">source
policy container</span>'s <span data-x="policy-container-csp-list">CSP list</span> is "<code
data-x="">Blocked</code>", then set <var>response</var> to a <span>network error</span> and
<span>break</span>. <ref>CSP</ref></p></li>

Expand Down