Closed Bug 1862108 Opened 2 years ago Closed 1 years ago

[wpt-sync] Sync PR 42858 - Shared Storage: Allow iframe header writes if permission on redirect

Categories

(Testing :: web-platform-tests, task, P4)

task

Tracking

(firefox121 fixed)

RESOLVED FIXED
121 Branch
Tracking Status
firefox121 --- fixed

People

(Reporter: wpt-sync, Unassigned)

References

()

Details

(Whiteboard: [wptsync downstream])

Sync web-platform-tests PR 42858 into mozilla-central (this bug is closed when the sync is complete).

PR: https://github.com/web-platform-tests/wpt/pull/42858
Details from upstream follow.

Camillia Smith Barnes <cammie@chromium.org> wrote:

Shared Storage: Allow iframe header writes if permission on redirect

We correct the behavior of writing to shared storage from response
headers to match the spec with regard to how PermissionsPolicy
checks are handled.

Currently, if permission is revoked for any request in a redirect
chain, then no subsequent request in that chain can write to shared
storage from response headers.

This CL updates the behavior for HTMLIframeElement so that, for
redirect chains of requests that have opted-in via
sharedStorageWritable, each request in the chain has its
PermissionsPolicy checked independently of the others in the chain.

https://crrev.com/c/4911530 will do the same for fetch() and
HTMLImageElement, and fixes the network service code common to all
three.

Bug: 1218540,1489536
Change-Id: I292c558d9ca922171a00c106a6adad142010b674
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/4935951
Reviewed-by: Avi Drissman \<avi@chromium.org>
Commit-Queue: Cammie Smith Barnes \<cammie@chromium.org>
Reviewed-by: Yao Xiao \<yaoxia@chromium.org>
Cr-Commit-Position: refs/heads/main@{#1217159}

PR 42858 applied with additional changes from upstream: f631d1aa161f0176f3eb0ef206f7c6dc6b7af047

CI Results

Ran 9 Firefox configurations based on mozilla-central, and Firefox, Chrome, and Safari on GitHub CI

Total 1 tests and 3 subtests

Status Summary

Firefox

FAIL : 1
TIMEOUT: 2
NOTRUN : 1

Chrome

FAIL : 1
TIMEOUT: 2
NOTRUN : 1

Safari

FAIL : 1
TIMEOUT: 2
NOTRUN : 1

Links

Gecko CI (Treeherder)
GitHub PR Head
GitHub PR Base

Details

New Tests That Don't Pass

  • /shared-storage/shared-storage-writable-multi-redirect.tentative.https.sub.html [wpt.fyi]: TIMEOUT (Chrome: TIMEOUT, Safari: TIMEOUT)
    • permissions policy header shared-storage=(self) allows the 'Shared-Storage-Writable' header to be sent for the redirect of a shared storage fetch request, where the redirect has a same-origin URL, even if an intermediate redirect has a cross-origin URL.: FAIL (Chrome: FAIL, Safari: FAIL)
    • permissions policy header shared-storage=(self) allows the 'Shared-Storage-Writable' header to be sent for the redirect of a shared storage image request, where the redirect has a same-origin URL, even if an intermediate redirect has a cross-origin URL.: TIMEOUT (Chrome: TIMEOUT, Safari: TIMEOUT)
    • permissions policy header shared-storage=(self) allows the 'Shared-Storage-Writable' header to be sent for the redirect of a shared storage iframe request, where the redirect has a same-origin URL, even if an intermediate redirect has a cross-origin URL.: NOTRUN (Chrome: NOTRUN, Safari: NOTRUN)
Pushed by wptsync@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/97d6b3d9d650 [wpt PR 42858] - Shared Storage: Allow iframe header writes if permission on redirect, a=testonly https://hg.mozilla.org/integration/autoland/rev/559669508934 [wpt PR 42858] - Update wpt metadata, a=testonly
Pushed by wptsync@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/d252b41166b8 [wpt PR 42858] - Shared Storage: Allow iframe header writes if permission on redirect, a=testonly https://hg.mozilla.org/integration/autoland/rev/6137195e917b [wpt PR 42858] - Update wpt metadata, a=testonly
Status: NEW → RESOLVED
Closed: 1 years ago
Resolution: --- → FIXED
Target Milestone: --- → 121 Branch
You need to log in before you can comment on or make changes to this bug.