-
Notifications
You must be signed in to change notification settings - Fork 62
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
DNR: Add excludedTopFrameDomains (and topFrameDomains) #762
Comments
Chrome is supportive of this. It seems like a compelling use case and a good proposal to achieve the desired behavior. |
What is the expected behavior if the top level is |
We should fall back on the initiator in this edge case? Maybe we also want |
@oliverdunk FWIW I created a Chromium issue for this a while back (though calling it In case it helps, some notes from the discussions in that earlier issue:
|
Let's say we want to block |
By the way, here is another real-world problem caused by |
@ghostwords with your example, I figure the |
Thanks @kzar - exciting to hear that you might be interested in contributing a patch for this. I hadn't seen the Chromium issue before today, but when I last spoke to Devlin about this he didn't feel as strongly about having a more flexible syntax. Let me check in with him, likely next week as I'm OOO from tomorrow. I'd then be happy to help with opening a proposal given there is interest in implementing this. |
Yeah, I think service worker-initiated requests have the service worker domain as the initiator. The problem with specifying |
Yea, I see what you mean. I think you're right that it makes sense for |
@oliverdunk I've had a go at drafting the API proposal document this afternoon. Any chance you and Devlin can take a pass? (I went with the name |
In addition to
excludedInitiatorDomains
(andinitiatorDomains
). HavingexcludedTopFrameDomains
(andtopFrameDomains
) would solve the problem of excluding (or including) requests based specifically on the top-level document's domain, not the initiator's (immediate parent frame's) domain.excludedTopFrameDomains
will work just likeexcludedInitiatorDomains
with the one difference being thatexcludedTopFrameDomains
compares against the top-level frame's domain instead of the immediate parent frame's domain.Developers should be able to feature detect the availability of
excludedTopFrameDomains
, so that they can use it when it is available and fall back onexcludedInitiatorDomains
otherwise.For a real world example of what this would solve, see EFForg/privacybadger#3048 (comment)
The text was updated successfully, but these errors were encountered: