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

Replace same-origin Security & Privacy requirement with Permissions Policy one #136

Merged
merged 1 commit into from
Jan 31, 2024

Conversation

rakuco
Copy link
Member

@rakuco rakuco commented Jan 31, 2024

This addresses a conflict that was introduced in #121:

  • The presence of the Permissions Policy integration means usage of the
    Device Orientation API can be allowed in third-party iframes provided that
    the right tokens are in place.
  • The "Security and privacy considerations" section contains a requirement
    that events are fired only on child navigables that are same-origin with
    the top-level traversable.

The latter was introduced in #25 and served as a stop-gap measure before
Permissions Policy integration was added.

The current implementation status is:

  • Blink never implemented the same-origin requirement, but added Permissions
    Policy integration in 2018.
  • WebKit has always implemented Permissions Policy integration.
  • Gecko implements the same-origin requirement (see Mozilla bug 1197901).

This means we can safely replace the same-origin requirement with a
requirement to support the Permissions Policy integration, as switching from
one to the other is transparent in the sense that the exact same set of
websites that worked before will continue to work with the change, as the
features we define have a default allowlist of "self".

Fixes #133


Preview | Diff

…olicy one

This addresses a conflict that was introduced in #121:

- The presence of the Permissions Policy integration means usage of the
  Device Orientation API can be allowed in third-party iframes provided that
  the right tokens are in place.
- The "Security and privacy considerations" section contains a requirement
  that events are fired only on child navigables that are same-origin with
  the top-level traversable.

The latter was introduced in #25 and served as a stop-gap measure before
Permissions Policy integration was added.

The current implementation status is:
- Blink never implemented the same-origin requirement, but added Permissions
  Policy integration in 2018.
- WebKit has always implemented Permissions Policy integration.
- Gecko implements the same-origin requirement (see Mozilla bug 1197901).

This means we can safely replace the same-origin requirement with a
requirement to support the Permissions Policy integration, as switching from
one to the other is transparent in the sense that the exact same set of
websites that worked before will continue to work with the change, as the
features we define have a default allowlist of "self".

Fixes #133
@rakuco rakuco requested a review from reillyeon January 31, 2024 10:27
@rakuco rakuco merged commit a1bee02 into main Jan 31, 2024
2 checks passed
@rakuco rakuco deleted the remove-same-origin-security-and-privacy-requirement branch January 31, 2024 22:44
github-actions bot added a commit that referenced this pull request Jan 31, 2024
…olicy one (#136)

SHA: a1bee02
Reason: push, by rakuco

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
@anssiko
Copy link
Member

anssiko commented Feb 2, 2024

Does this suggest changes to https://www.w3.org/TR/orientation-event/#changes

If yes, please submit a PR to add one more bullet.

rakuco added a commit that referenced this pull request Feb 2, 2024
The language used to describe the previous Security & Privacy is not
very precise, but using the right terms would make the sentence long
and harder to understand.
@rakuco
Copy link
Member Author

rakuco commented Feb 2, 2024

Does this suggest changes to https://www.w3.org/TR/orientation-event/#changes

If yes, please submit a PR to add one more bullet.

Done in #138

anssiko pushed a commit that referenced this pull request Feb 2, 2024
The language used to describe the previous Security & Privacy is not
very precise, but using the right terms would make the sentence long
and harder to understand.
github-actions bot added a commit that referenced this pull request Feb 2, 2024
SHA: 36b567e
Reason: push, by anssiko

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Same origin S&P requirement conflicts with Permissions Policy integration
3 participants