Closed Bug 1686426 Opened 3 years ago Closed 3 years ago

Add a debug assertion to ensure all documents in a DocGroup have the same cross-origin-isolated state

Categories

(Core :: DOM: Core & HTML, enhancement)

enhancement

Tracking

()

RESOLVED FIXED
89 Branch
Tracking Status
firefox89 --- fixed

People

(Reporter: tt, Assigned: tt)

References

Details

Attachments

(1 file)

When the cross-origin-isolated state is true, we use Origin as a key for the DocGroup. When the cross-origin-isolated state is false, we use SiteOrigin as a key for the DocGroup.
https://searchfox.org/mozilla-central/rev/014fe72eaba26dcf6082fb9bbaf208f97a38594e/dom/base/DocGroup.cpp#141-142

It's possible to have the same keys for the same origin but different cross-origin-isolated states. For instance, the origin and site origin for https://example.com are the same.

I thought it's not a problem since while a document is loading with both COOP and COEP headers are set, we load it on the cross-origin-isolated process per origin. So that two loaded documents with different cross-origin-isolated states should sit on different processes.

However, after thinking about this again, we should probably have a debug assertion to ensure all documents in the same DocGroup have the same state.

(Can we rename SiteOrigin to just Site? It's quite distinct from an Origin and that name seems like it might cause confusion.)

Severity: -- → S3
Pushed by shes050117@gmail.com:
https://hg.mozilla.org/integration/autoland/rev/a3ac5e8fe668
Add a debug assertion to ensure all documents in a DocGroup have the same cross-origin-isolated state; r=nika
Status: NEW → RESOLVED
Closed: 3 years ago
Resolution: --- → FIXED
Target Milestone: --- → 89 Branch
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: