AdguardTeam / AdGuardHome

Network-wide ads & trackers blocking DNS server
https://adguard.com/adguard-home.html
GNU General Public License v3.0
25.05k stars 1.8k forks source link

Custom filtering rules ignored with DNS allowlist #2371

Open brokoler opened 3 years ago

brokoler commented 3 years ago

Issue description: With the latest version of AdGuard Home (0.104.3) custom filtering rules get ignored, if a matching DNS allowlist entry exists.

Suggested solution: Please add an option to choose if custom filter rules or DNS list entries are prefered. Default behavior should be that custom filtering rules are always prefered.

Example of issue: Blocked google.com only for specific clients, which worked until a DNS allowlist was added which whitelists google.com.

Custom filterung rule: ||google.com^$client='192.168.0.82' DNS allowlist: https://raw.githubusercontent.com/notracking/hosts-blocklists-scripts/master/hostnames.whitelist.txt

Result right now, which should not happen:

google-whitelisted
ainar-g commented 3 years ago

Thank you for your report, we'll see what we can do without breaking other people's settings. An option is one option (heh), but perhaps a more flexible model is needed.

kiwilad-nz commented 3 years ago

I am running into this issue as well as that's actually how I would of expected this to work.

Whitelists are really good and convenient to override blacklists, but in my view custom rules should always trump both (override any backlist and/or whitelist).

angrynerd commented 3 years ago

yes, also running into this issue. would have thought custom is prefered.

bkuhns commented 2 years ago

Just ran into this. I subscribe to a generic whitelist for known services (was having trouble with Google services without it). But, that whitelist allows youtube.com, which I want to block. My custom filter to block youtube.com is being ignored because the whitelist I subscribe to contains an allow for it. Custom filters should trump both block/allow lists!

dd900 commented 4 days ago

Bumping this issue. I'm not sure why this hasn't been properly addressed yet. Custom Rules should take priority over all other rules. If not this, then maybe add some sort of priority modifier that goes beyond the $important modifier.