-
Notifications
You must be signed in to change notification settings - Fork 2.8k
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
Prevent cross document access via policy #4435
Comments
I like the general idea, but I wonder what boundary we are looking for. E.g., if we want these documents to (potentially) end up in different processes, the isolation needs to be at a different level (the agent cluster key) as otherwise there would still be shared memory between these documents, for instance. And as these "window" agent clusters really belong to the browsing context group, this seems like the kind of thing to decide when the browsing context group is created. |
I'm not thinking strictly about enforcing process isolation. More like I want to embed this content and it really doesn't have to interact with my content so let me limit the scope I expose to it. So I don't think it necessarily ties into the agent cluster key. ie. having two documents directly scriptable probably isn't widely used and it should be easy to opt out of it. |
Unless we also provide the ability for UAs to optionally process-isolate them it's not entirely clear to me it's worth it. Otherwise they can still (accidentally) share memory via |
I think these are good points. I probably want to make the definition of the js bindings dependent on the agent cluster key and then adjust the agent cluster key based on the feature policy. Is that what you were thinking? |
Yeah, other things to resolve:
And then depending on the resolutions to those there's more, I suspect. |
Are not all your points addressed how feature policies work? If set on an iframe it is on the container policy, otherwise documents can opt into it via the header. |
I don't understand how I'm afraid. |
document to another. Add steps in the IsPlatformObjectSameOrigin to force checks if the two documents do not share the same agent and thus cannot share memory because they would be in different agent clusters. Fixes whatwg#4435
document to another. Add steps in the IsPlatformObjectSameOrigin to force checks if the two documents do not share the same agent and thus cannot share memory because they would be in different agent clusters. Fixes whatwg#4435
document to another. Add steps that cause a newly created browsing context group at the iframe boundary. Fixes whatwg#4435
document to another. Add steps that cause a newly created browsing context group at the iframe boundary. Fixes whatwg#4435
document to another. Add steps that cause a newly created browsing context group at the iframe boundary. Fixes whatwg#4435
Consider adding a policy to prevent same origin cross document access.
See: https://github.com/dtapuska/documentaccess as an alternate for issue 2757.
@annevk @bzbarsky
The text was updated successfully, but these errors were encountered: