You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
WindowProxy (and Location) leak a bunch of data that ideally would only be exposed through a mutually agreed postMessage() API. (This is a premise and it'd be great to hear pushback to this, if any.)
Given that premise, it'd be interesting to consider a new mode whereby that data is not exposed for a browsing context group. (It's not entirely clear to me it can be more granular as everyone kind of has to agree to this mode of operation as otherwise you can end up with very weird situations that might not be expected to all parties involved.)
If we had such a mode and you'd be looking at cross-origin things:
Location would not be exposed
WindowProxy would only expose postMessage().
Window might have a new API that lets you find all your-party-origin WindowProxy objects. I'm not sure if this is a set of objects or if they need to provide some additional data as to whether that particular WindowProxy is a top-level or not.
(Another thing to consider is making more drastic changes also in the same-origin case, as the indexed/named getters are a source of issues there too, but that might make this harder to adopt. Thoughts welcome though. This is still very exploratory.)
WindowProxy (and Location) leak a bunch of data that ideally would only be exposed through a mutually agreed postMessage() API.
Nit: I think the mutually-agreed bit is important. I wouldn't be dogmatic about it being agreed-upon via postMessage().
Given that premise, it'd be interesting to consider a new mode whereby that data is not exposed for a browsing context group.
This is an approach worth exploring!
I think it's also worth exploring what kinds of changes we could make without requiring opt-in. For instance, could we explore changing the window.frames/window.length contract to enumerate only cross-origin children? Could we make setting location a no-op for windows you didn't open? Can we neuter onload events by screwing with their timing?
As you note, that has a little more deployment risk, but it would also be more robust.
From mikewest/securer-contexts#2.
WindowProxy
(andLocation
) leak a bunch of data that ideally would only be exposed through a mutually agreedpostMessage()
API. (This is a premise and it'd be great to hear pushback to this, if any.)Given that premise, it'd be interesting to consider a new mode whereby that data is not exposed for a browsing context group. (It's not entirely clear to me it can be more granular as everyone kind of has to agree to this mode of operation as otherwise you can end up with very weird situations that might not be expected to all parties involved.)
If we had such a mode and you'd be looking at cross-origin things:
Location
would not be exposedWindowProxy
would only exposepostMessage()
.Window
might have a new API that lets you find all your-party-originWindowProxy
objects. I'm not sure if this is a set of objects or if they need to provide some additional data as to whether that particularWindowProxy
is a top-level or not.(Another thing to consider is making more drastic changes also in the same-origin case, as the indexed/named getters are a source of issues there too, but that might make this harder to adopt. Thoughts welcome though. This is still very exploratory.)
cc @mikewest
The text was updated successfully, but these errors were encountered: