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

Hide some navigation timing info when cross-origin redirects are present #7105

Closed
wants to merge 4 commits into from
Closed
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
31 changes: 23 additions & 8 deletions source
Original file line number Diff line number Diff line change
Expand Up @@ -2493,6 +2493,7 @@ a.setAttribute('href', 'https://example.com/'); // change the content attribute
<li><dfn data-x="body safely extract" data-x-href="https://fetch.spec.whatwg.org/#bodyinit-safely-extract">safely extracting a body</dfn></li>
<li><dfn data-x-href="https://fetch.spec.whatwg.org/#process-response-end-of-body">processResponseConsumeBody</dfn></li>
<li><dfn data-x-href="https://fetch.spec.whatwg.org/#fetch-processresponseendofbody">processResponseEndOfBody</dfn></li>
<li><dfn data-x="create-an-opaque-timing-info" data-x-href="https://fetch.spec.whatwg.org/#create-an-opaque-timing-info">create an opaque timing info</dfn></li>
<li>
<dfn data-x="concept-response"
data-x-href="https://fetch.spec.whatwg.org/#concept-response">response</dfn> and its
Expand Down Expand Up @@ -3988,6 +3989,7 @@ a.setAttribute('href', 'https://example.com/'); // change the content attribute
<li><dfn data-x="on-fetch-request-algorithm" data-x-href="https://w3c.github.io/ServiceWorker/#on-fetch-request-algorithm">handle fetch</dfn></li>
<li><dfn data-x="scope-match-algorithm" data-x-href="https://w3c.github.io/ServiceWorker/#scope-match-algorithm">match service worker registration</dfn></li>
<li><dfn data-x="dfn-service-worker" data-x-href="https://w3c.github.io/ServiceWorker/#dfn-service-worker">service worker</dfn></li>
<li><dfn data-x="service-worker-timing-info" data-x-href="https://w3c.github.io/ServiceWorker/#service-worker-timing-info">service worker timing info</dfn></li>
<li><dfn data-x="serviceworkercontainer-service-worker-client" data-x-href="https://w3c.github.io/ServiceWorker/#serviceworkercontainer-service-worker-client">service worker client</dfn></li>
<li><dfn data-x-href="https://w3c.github.io/ServiceWorker/#serviceworker"><code>ServiceWorker</code></dfn> interface</li>
<li><dfn data-x-href="https://w3c.github.io/ServiceWorker/#serviceworkercontainer"><code>ServiceWorkerContainer</code></dfn> interface</li>
Expand Down Expand Up @@ -88631,16 +88633,29 @@ interface <dfn interface>Location</dfn> { // but see also <a href="#the-location
</li>

<li><p>Let <var>redirectCount</var> be 0 if <var>navigationParams</var>'s <span
data-x="navigation-params-has-cross-origin-redirects">has cross-origin redirects</span> is true;
otherwise <var>navigationParams</var>'s <span data-x="navigation-params-request">request</span>'s
<span data-x="concept-request-redirect-count">redirect count</span>.
data-x="navigation-params-has-cross-origin-redirects">has cross-origin redirects</span> is
true; otherwise <var>navigationParams</var>'s
<span data-x="navigation-params-request">request</span>'s
<span data-x="concept-request-redirect-count">redirect count</span>.</p></li>

<li><p>Let <var>timingInfo</var> be the result of
<span data-x="create-an-opaque-timing-info">creating an opaque timing info</span> given
<var>navigationParams</var>'s <span data-x="navigation-params-response">response</span>'s
<span data-x="concept-response-timing-info">timing info</span>, if <var>navigationParams</var>'s
<span data-x="navigation-params-has-cross-origin-redirects">has cross-origin redirects</span>
is true; otherwise <span data-x="navigation-params-response">response</span>'s
<span data-x="concept-response-timing-info">timing info</span>.</p></li>

<li><p>Let <var>serviceWorkerTimingInfo</var> be
a new <span data-x="service-worker-timing-info">service worker timing info</span>
if <var>navigationParams</var>'s <span
data-x="navigation-params-has-cross-origin-redirects">has cross-origin redirects</span> is
true; otherwise <span data-x="navigation-params-response">response</span>'s
<span data-x="concept-response-service-worker-timing-info">service worker timing info</span>.</p></li>

<li><p><span>Create the navigation timing entry</span> for <var>document</var>, with
<var>navigationParams</var>'s <span data-x="navigation-params-response">response</span>'s <span
data-x="concept-response-timing-info">timing info</span>, <var>redirectCount</var>,
<var>navigationType</var>, and <var>navigationParams</var>'s <span
data-x="navigation-params-response">response</span>'s <span
data-x="concept-response-service-worker-timing-info">service worker timing info</span>.</p></li>
<var>timingInfo</var>, <var>redirectCount</var>, <var>navigationType</var>, and
<var>serviceWorkerTimingInfo</var>.</p></li>

<li>
<p>If <var>navigationParams</var>'s <span data-x="navigation-params-response">response</span>
Expand Down