Skip to content

Conversation

@forkfury
Copy link
Contributor

Clarifies that third-party iframes MUST be blocked (not SHOULD) to align with the MUST NOT requirement for default exposure.

Removes ambiguous reference to Permissions API and allow attribute mechanism that was never fully specified, replacing it with explicit blocking requirement regardless of configuration.

@forkfury forkfury requested a review from eth-bot as a code owner November 16, 2025 07:02
@github-actions github-actions bot added c-update Modifies an existing proposal s-stagnant This EIP is Stagnant t-interface labels Nov 16, 2025
@eth-bot
Copy link
Collaborator

eth-bot commented Nov 16, 2025

File EIPS/eip-5593.md

Requires 1 more reviewers from @bbondy, @diracdeltas, @kdenhartog, @thypon
Requires 1 more reviewers from @g11tech, @lightclient, @SamWilsn

@eth-bot eth-bot added the a-review Waiting on author to review label Nov 16, 2025
@eth-bot eth-bot changed the title fix: resolve MUST/SHOULD contradiction for third-party iframe blocking Update EIP-5593: resolve MUST/SHOULD contradiction for third-party iframe blocking Nov 16, 2025
- By default the Ethereum Provider APIs MUST NOT be exposed to third-party iframes.
- `window.ethereum` MUST be `undefined` in an iframe where `window.isSecureContext` returns `false` in that iframe.
- If the iframe is a third party to the top-level secure origin, it SHOULD be blocked.
- If the iframe is a third party to the top-level secure origin, it MUST be blocked.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is defined as SHOULD rather than MUST because not all wallets were enforcing this.

I don't have an issue with this, but it's updating the document in a way that doesn't reflect reality. Also, it might be an issue for smart wallets, so that should be weighed here.

- If the iframe is a third party to the top-level secure origin, it MUST be blocked.
- If the iframe is first-party to the top-level origin AND the `sandbox` attribute is set on the iframe, the provider object MUST be blocked. If the `sandbox` attribute is set to `sandbox="allow-same-origin"` it MUST be injected for a first party frame.
- Note `"allow-same-origin"` does nothing if the iframe is third-party. The case of the third party iframe is dictated by the usage of the `allow` attribute and the Permissions API as defined in the rule above.
- Note `"allow-same-origin"` does nothing if the iframe is third-party. Third-party iframes MUST be blocked regardless of the `sandbox` attribute or any other configuration.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This would make Brave's implementation non-compliant which the whole point of the EIP was to document this sandbox behavior.

The page has the ability to request usage of this via the attribute in Brave and then the user can grant or deny the permission using the permissions prompt.

I'm not sure how other wallets would handle this though.

@g11tech
Copy link
Contributor

g11tech commented Nov 20, 2025

EIP authors need to first take a call on this

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

a-review Waiting on author to review c-update Modifies an existing proposal s-stagnant This EIP is Stagnant t-interface

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants