-
Notifications
You must be signed in to change notification settings - Fork 2.7k
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
Questions about COOP/COEP and secure context #5164
Comments
I assume COOP has that statement because of https://blog.mozilla.org/security/2015/04/30/deprecating-non-secure-http/. We should probably lock COEP to secure contexts too if we haven't already. It's a clear minimum bar for security.
As currently defined, no. Mixed Content doesn't affect secure contextness. I have some ideas about improvements we can make over time, but I would expect them to have the same property: we make decisions about secureness at the time we commit the document, and lock it for the document's lifetime. |
Thanks, @mikewest! Although I support disallowing new powerful features in non-secure HTTP, I'm not convinced that it always makes sense. For COEP and CORP, you get to opt in to blocking things. If we apply "this is a new feature, pretend it doesn't exist for HTTP", couldn't that allow an attacker to embed an HTTPS resource that had opted in to disallow embedding? The secure context question is also discussed a bit here: Cross-Origin-Opener-Policy explainer |
Assuming that the HTTPS resource sends either If the response sets |
OK, so it seems important to do the CORP check also when the fetch originated from an non-secure context. |
I think that boils down to the question of how much security we should allow HTTP sites to pretend to have. If I could go back in time and kick myself in the butt about allowing SRI and CSP for HTTP pages, I would. :) |
I think it's a valid point that CORP cannot be restricted to secure contexts as that would make secure resources less secure. Not convinced that COOP or COEP should not require secure contexts though. (This thread did make me wonder whether we should have |
I think it's OK for COOP and COEP to require secure context. But it seems to me it increases overall complexity a bit. |
Keeping this as a tracking issue to add the secure context requirement to COEP. And yes, slight secure context branching complexity will exist until everything is a secure context or a network error. |
Let's merge this into #4930. |
In COOP there's this statement
COEP doesn't have an equivalent statement.
Although I first just wanted to file this to ask whether the inconsistency is intentional, I have a few more questions:
cc @jugglinmike @annevk @mikewest
The text was updated successfully, but these errors were encountered: