-
Notifications
You must be signed in to change notification settings - Fork 78
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
Consider treating non-special schemes like local schemes #69
Comments
👍 I don't think there's a use case for allowing a scheme that the policy author wouldn't know about ahead of time. |
I think I can get behind this (with the practical caveat that we don't have a ton of control over the contents of things loaded from interesting schemes, so the language about inheriting policy will be pretty toothless). Would you like to put together a PR? |
If we are going to safelist schemes it seems better to safelist "network schemes" rather than "special schemes". Note that by the time WebSocket reaches CSP the scheme will be "http"/"https" already. |
I am in favor of safelisting "network schemes", but missing "ws" and "wss" is confusing. Can you please clarify:
|
But what about Defining @dveditz, @ckerschb: Thoughts about changing Firefox's implementation? |
Interesting. @mikewest, does it also imply that |
Yeah. Those would break. We'd either need to special case them, or break them. If we think that's the right route to go, we can add some metrics to see how often such policies are present. I bet it's not particularly often. |
@shekyan: File a bug against Chrome; we can talk about how you might add metrics there. That stuff is all open. |
Filed a tracker at https://bugs.chromium.org/p/chromium/issues/detail?id=602717 |
Based on the discussion #69, updating the algorithm to match only network scheme URLs if expression is "*". WebSocket schemes are equivalent to HTTP schemes now.
I think we want to preserve forward compatibility and the ability to have On Sun, Apr 10, 2016 at 8:11 PM Michael Ficarra notifications@github.com
|
@hillbrad could you maybe try to restate that? I have a hard time following the point you are trying to make. |
I think this is settled in the spec and in Chrome/Firefox. |
Based on the discussion w3c/webappsec-csp#69, updating the algorithm to match only network scheme URLs if expression is "*". WebSocket schemes are equivalent to HTTP schemes now.
It most likely was discussed already, but I think it is worth clarifying:
currently, any non-local (e.g. none of "about", "blob", "data" or "filesystem") scheme is treated the same way by matching algorithms, meaning that
default-src *
allows all kinds of schemes like "carousel", "itms-apps" etc, unlike local schemes that need to be opted-in.I propose any scheme that is not a special scheme be disallowed by a wildcard source expression (
*
).The text was updated successfully, but these errors were encountered: