AdguardTeam / FiltersCompiler

A tool that compiles & validates filters
GNU Lesser General Public License v3.0
52 stars 12 forks source link

Include trusted- scriptlets in uBO version of lists #197

Open superlex opened 10 months ago

superlex commented 10 months ago

As of now, uBO version of lists don't inlcude trusted- scriptlets. For example, compare Annoyances for uBO and Annoyances for AG/Firefox.

Since uBO supports them (trusted-click-element, trusted-set-cookie, etc.) it could be an idea adding them in uBO version of lists, so advanced users can take advantage of these AG rules.

Keep in mind that for standard users nothing changes: https://github.com/gorhill/uBlock/commit/64c1f8767c

ameshkov commented 10 months ago

As I understand, trusted scriptlets in uBO are only allowed in the lists maintained by the uBO team, is that right?

superlex commented 10 months ago

Hi @ameshkov 🙂 By default yes, trusted scriptlets are only allowed in the uBO lists. However a user can add adguard- token to trustedListPrefixes in order to allow trusted- scriptlets in stock AdGuard lists too.

slavaleleka commented 10 months ago

AdGuard trusted scriptlets are not compatible with any other blocker by desing https://github.com/AdguardTeam/Scriptlets/#trusted-scriptlets-restriction

i.e. trusted scriptlet rules are intentionally skipped during the build of the uBO version of AdGuard filter lists

ameshkov commented 10 months ago

@slavaleleka well, that's the policy of our apps. uBO has a similar policy, i.e. it won't trust our scriptlets right away. But we can still include them into uBO list versions nevertheless, it's up to the user to decide.

superlex commented 10 months ago

it's up to the user to decide

Exactly, that's the point. For a normal user nothing changes, he must accept the risks to enable advanced mode (and therefore enable adguard trusted scriptlets): https://github.com/gorhill/uBlock/wiki/Advanced-user-features

Btw, an advanced user can also add other AG lists that contain AG trusted scriptlets (e.g. AG lists for AG_ext/Firefox) and use them:

dd

(this is a rule of AG Annoyances for AG_ext/Firefox)