Skip to content
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

Specify declarativeNetRequest rules #87

Closed
chrmod opened this issue Sep 28, 2021 · 2 comments
Closed

Specify declarativeNetRequest rules #87

chrmod opened this issue Sep 28, 2021 · 2 comments
Labels
inconsistency Inconsistent behavior across browsers

Comments

@chrmod
Copy link

chrmod commented Sep 28, 2021

As of September 2021, we have two implementations of declarativeNetRequest - Chrome and Safari. Sadly those implementations are quite different. This issue focuses on the Rules only.

References:

Big issue for content blockers is a format in which the block rule condition should be expressed. Chrome seem to favor urlFilter but Safari only allows regexFilter. regexFilter on the other hand is heavily limited on Chrome to just a 1000 rules specified by MAX_NUMBER_OF_REGEX_RULES (this is likely due to poor performance of Chrome's blocking engine).

For that reason, content blockers have to generate two sets of rules sets, one for Chrome and one for Safari, which is another difference and add up to the cost extension developers have to pay due to the enforcement of declarativeNetRequest.

@xeenon xeenon added the inconsistency Inconsistent behavior across browsers label Sep 30, 2021
@xeenon xeenon changed the title Standarise declarativeNetRequest rules Standardise declarativeNetRequest rules Sep 30, 2021
@xeenon xeenon changed the title Standardise declarativeNetRequest rules Standardize declarativeNetRequest rules Sep 30, 2021
@dotproto dotproto changed the title Standardize declarativeNetRequest rules Specify declarativeNetRequest rules Oct 8, 2021
@dotproto
Copy link
Member

dotproto commented Oct 8, 2021

Changed the title from "standardize" to "specify" as standardization is outside this group's charter. We can discuss, align on, and even produce technical reports that specify these rules, but standardization is explicitly outside our purview.

@xeenon
Copy link
Collaborator

xeenon commented Mar 20, 2024

Safari does support urlFilter now, we translate it to a regex for our implementation.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
inconsistency Inconsistent behavior across browsers
Projects
None yet
Development

No branches or pull requests

3 participants