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

Anonymous iframes #639

Closed
1 task done
camillelamy opened this issue May 21, 2021 · 9 comments
Closed
1 task done

Anonymous iframes #639

camillelamy opened this issue May 21, 2021 · 9 comments
Assignees
Labels
chromium-high-priority Something that the Chromium team would like the TAG to prioritise Progress: review complete Resolution: satisfied The TAG is satisfied with this design Review type: CG early review An early review of general direction from a Community Group Venue: WHATWG

Comments

@camillelamy
Copy link

camillelamy commented May 21, 2021

Ya ya yawm TAG!

I'm requesting a TAG review of Anonymous iframes.

Anonymous iframes allows to load document that haven't enabled COEP in COEP environments. To make this safe, anonymous iframes restrict usage of shared storage and credentials, to avoid personalized resources being loaded in a high-risk crossOriginIsolated environment.

Further details:

  • I have reviewed the TAG's Web Platform Design Principles

  • The group where the incubation/design work on this is being done (or is intended to be done in the future): WHATWG

  • The group where standardization of this work is intended to be done ("unknown" if not known): WHATWG

  • Existing major pieces of multi-stakeholder review or discussion of this design:

  • Major unresolved issues with or opposition to this design:

  • This work is being funded by: Google

You should also know that...

[please tell us anything you think is relevant to this review]

We'd prefer the TAG provide feedback as (please delete all but the desired option):

🐛 open issues in our GitHub repo for each point of feedback

@hadleybeeman
Copy link
Member

Hi @camillelamy! Thanks for this review request.

  1. What end user needs are you trying to support? When would this feature be useful to a user, and why is it worth adding to the web? It would be great if you could add this to the explainer.

  2. We are seeing a number of iframe related proposals, all of which would benefit from input from the rest of the W3C community. To help bring that together, we will be recommending the W3C create a task force on iFrames, and we would very much welcome your participation.

  3. Could you elaborate on the answers in the Security and Privacy questionnaire? For example, where you've just said "No", can you give more detail?

@hadleybeeman hadleybeeman added Venue: WHATWG Progress: pending editor update TAG is waiting for a spec/explainer update labels Jul 12, 2021
@camillelamy
Copy link
Author

Hi @hadleybeeman!

I have put together another doc explaining the wider problems we are facing with crossOriginIsolation. To sum it up: developers that currently use SharedArrayBuffers on Chrome need to migrate to crossOriginIsolation or risk losing access to SABs and their websites stop functioning. The migration to crossOriginIsolation is hard, in particular deploying COEP. COEP requires every single embedded frame to have deployed COEP to load or be blocked. This particularly complex when embedding legacy content. This proposal tackles this issue by adding an attribute on iframes that waves the COEP deployment requirement in exchange of additional restrictions on the frame. This way sites that are currently using SABs and have legacy/arbitrary 3rd party content can keep functioning. Real world examples are Google Earth or any site using both SABs and Google Ads for example.

We know that there other proposal around iframes going on, Fenced Frames for example. We have been looking at the interaction between Fenced Frames and our proposal, and we'd be happy to discuss our conclusions and look at the interaction with other iframe-related proposals.

I have also updated the Security and Privacy questionaire. However, I'd like to point out that many of the questions are yes/no questions, so there often isn't that many more details to give beyond "no the feature is not doing that".

@torgo torgo added Progress: in progress chromium-high-priority Something that the Chromium team would like the TAG to prioritise and removed Progress: pending editor update TAG is waiting for a spec/explainer update labels Aug 26, 2021
@hober
Copy link
Contributor

hober commented Sep 14, 2021

@atanassov and I looked at this today during our virtual F2F. One thing I'm not terribly enthused about is the name of the DOM attribute or attribute value, because it's not credentials that are being omitted, it's storage, and it's not so much that it's omitted, it's that you get a new, one-off partition. There's an open issue that captures this concern: camillelamy/explainers#20

@torgo torgo added the Progress: pending external feedback The TAG is waiting on response to comments/questions asked by the TAG during the review label Sep 16, 2021
@torgo
Copy link
Member

torgo commented Sep 21, 2021

Hi @camillelamy I have similar feedback as i did for #649 which is that the explainer jumps right in to talking about how "sites that wish to continue using SharedArrayBuffer must opt-into cross-origin isolation" without first talking about the end-user use cases (the user need). I see you've responded to Hadley's comment above with a link to the general doc describing the wider problem. But what user need is being served by the use of SharedArrayBuffer in this context that this set of mitigations is aimed at securing? You talk about password managers later on in the explainer doc - is that one of the primary use cases? Can you please amend the explainer to start with a few user needs to help us set the context?

@ArthurSonzogni
Copy link

ArthurSonzogni commented Sep 21, 2021

But what user need is being served by the use of SharedArrayBuffer in this context that this set of mitigations is aimed at securing

SharedArrayBuffer availability in the context of an anonymous iframe is not really updated by this proposal.
This is more about using SAB on the main document, which is never an anonymous one.

Let me explain why I believe anonymous iframe is useful to developers and end users:

  1. End users needs performant websites.
  2. Some developers get performant website, by using multithreading/SharedArrayBuffer on the main document.
  3. To mitigate Spectre attacks, Web browsers (Chrome, Firefox, Safari (soon)) gate SharedArrayBuffer usage behind the crossOriginIsolated capability. This requires COOP and COEP.
  4. COEP requirement is recursive: 3rd party iframes are required to deploy COEP in order to be embeddable inside a COEP parent.
  5. Waiting for 3rd party to deploy COEP is painful for developers. Most of the time this is out of their control. Anonymous iframe removes the need to wait for 3rd party to update their website, at the cost of loading them using an ephemeral storage partition.

So anonymous iframe is helpful to developers, because they allow the top-level document to deploy crossOriginIsolation and keep embedding their 3rd party iframes.

Hoping to have answered the right question.


I made a quick online search. Here are some example of users who would see their problems addressed by this proposal:

@torgo
Copy link
Member

torgo commented Nov 8, 2021

Thanks @ArthurSonzogni that's very helpful. Can this info be brought into the explainer to make that document more clear (including the linked user needs)? This looks good to us on the basis of it being a stopgap. Can you please progress the open issues including the one Tess pointed to. Spec-wise where is this going? Is this headed to HTML?

@torgo torgo self-assigned this Nov 8, 2021
@torgo torgo added Progress: propose closing we think it should be closed but are waiting on some feedback or consensus and removed Progress: pending external feedback The TAG is waiting on response to comments/questions asked by the TAG during the review labels Nov 8, 2021
ArthurSonzogni added a commit to ArthurSonzogni/explainers that referenced this issue Nov 10, 2021
Address @torgo suggestion from
w3ctag/design-reviews#639 (comment)
This adds an example of user's need into the explainer.

Along the way, add some minor updates to the explainer.
ArthurSonzogni added a commit to ArthurSonzogni/explainers that referenced this issue Nov 10, 2021
Address @torgo suggestion from
w3ctag/design-reviews#639 (comment)
This adds an example of user's need into the explainer.

Along the way, add some minor updates to the explainer.
ArthurSonzogni added a commit to ArthurSonzogni/explainers that referenced this issue Nov 10, 2021
Address @torgo suggestion from
w3ctag/design-reviews#639 (comment)
This adds an example of user's need into the explainer.

Along the way, add some minor updates to the explainer.
@torgo
Copy link
Member

torgo commented Nov 15, 2021

@ArthurSonzogni noting the above updates to your explainer. Anything you'd in particular like to draw our attention to?

@ArthurSonzogni
Copy link

ArthurSonzogni commented Nov 15, 2021

I was going to reply in a few days:

Can this info be brought into the explainer to make that document more clear (including the linked user needs)?

Will be done by PR: camillelamy/explainers#25

Can you please progress the open issues including the one Tess pointed to

Tess pointed to camillelamy/explainers#20, which is also addressed by PR camillelamy/explainers#25.

Spec-wise where is this going? Is this headed to HTML?

I think HTML & fetch.

  1. Adding the iframe's attribute and inheritance logic is going to happen in the HTML spec. Inheritance is similar to the sandbox attribute, modulo that this is only for iframe, it doesn't propagate to popups.

  2. Some details: autofill, behavior of popup opened from anonymous iframe, etc are also going inside the HTML spec.

  3. Getting an ephemeral storage partition is done by piggybacking on ongoing efforts. This is mostly about adding a nonce to the network partition key / cookie partition key / storage partition key, defined from: Partition Network State, Cookies Having Independent Partitioned State, Client-Side Storage Partitioning. This would touch HTML and fetch I believe.

@torgo
Copy link
Member

torgo commented Nov 17, 2021

Thanks @ArthurSonzogni based on this I think we are good to close this. Thanks for being responsive to our feedback!

@torgo torgo closed this as completed Nov 17, 2021
@torgo torgo added Progress: review complete Resolution: satisfied The TAG is satisfied with this design and removed Progress: propose closing we think it should be closed but are waiting on some feedback or consensus labels Nov 17, 2021
@torgo torgo removed this from the 2021-11-15-week milestone Nov 17, 2021
@ArthurSonzogni ArthurSonzogni mentioned this issue Jul 24, 2022
1 task
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
chromium-high-priority Something that the Chromium team would like the TAG to prioritise Progress: review complete Resolution: satisfied The TAG is satisfied with this design Review type: CG early review An early review of general direction from a Community Group Venue: WHATWG
Projects
None yet
Development

No branches or pull requests

8 participants
@hober @torgo @hadleybeeman @plinss @ArthurSonzogni @atanassov @camillelamy and others