I have a PPPoE enabled router and OpenVPN installed. I followed the guide to install Adblock and when I click the Luci option I get:

Expected ';'
  in http://192.168.7.1/luci-static/resources/view/adblock/overview.js?v=git-20.136.49537-fb2f363:?

PROBLEM RESOLVED *******************************

Sorry - problem resolved, I was using a back-level browser.

1 Like

Hi @dibdot
Can you ask me to add this list?
Thanks.


filter : https://github.com/List-KR/List-KR/raw/master/filter.txt

added, will be part of the next update.

1 Like

Oh it is great, Many thanks!!

I am running Adblock 4.0.5-4.0 on Turris (TOS 5) and the parsing of oisd_nl fails. Anyone else having the issue? Thanks.

Jun 11 10:16:32 turris adblock-4.0.5[2275]: preparation of 'oisd_nl' failed, rc: 0

One general question why is adblock.sources compressed (.gz) these days?

Just wanted to say thanks this is working awesome on my WRT32X. I just have a couple of the small lists enabled to memory usage down, it was amazing to see no ads on mobile. Still use ublock on Chrome on my PC for youtube, since there doesn't seem to be a way to block that otherwise. Pi-hole has the same issue, but this being built into OpenWrt eliminates the need for one of those. Thanks!

Yep! :wink:
Fixed in 4.0.5-5 ...

**release 4.0.5-5

    add regional list source for czech/slovak
    add regional list source for korea
    adapt oisd_nl changes, switch to adb-syntax domains
1 Like

Thank you @dibdot!

Any further comments on the .gz compression for the adblock.sources file?

simply to save space, even on fs without compression.

Hope to be able to add custom source rules, which can simplify the setup, thank you!

PS:Could you please add this source? thank you.

Please check the readme, you can do that on your own.

added in 4.0.6

I'm fairly new to OpenWRT and networking in general, so maybe the solution to my problem is obvious, but I have been unable to find it.
I have OpenWRT running on a TP-Link Archer C5 v4, which I have configured as a dumb AP, but I keep failing to get adblock working correctly in it. The main router is the one provided by the ISP, and it can't be replaced by the Archer C5 without losing some of the services the ISP provides, so that is not currently an option.
The main router's local IP is 192.168.1.1 and I have configured the access point following the OpenWRT wiki to be on 192.168.1.2 (disabled DHCP on the AP, set DNS and gateway to main router, and disabled odhcpd and firewall). I have of course left dnsmasq enabled. I guess I'm missing something in this setup.
I have also tried disabling dhcp on main router and enabling it on AP. Adblock works like a charm this way, but some networking problems arise. Devices have problems switching between wireless networks, something that does not happen with the first setup. In fact, even if this little problem could be solved, I would prefer to maintain de main router as the one handling dhcp as, sadly, it tends to be resetted once in a while (it resets when disconnected from power and can also be done remotely by the ISP), and it is a pain to regain full access to the router. DNS settings can be changed easily, though.
According to the readme I understand that it is possible to get adblock working via dnsmasq on a dumb AP. Does it apply to this situation? If so, how?
Thanks

Yep, I've tested two variants successfully:

a) OpenWrt AP with adblock enabled DNS-Server and DHCP-Server (disable these services on your ISP-Router then)
b) OpenWrt AP only with adblock enabled DNS-Server (your ISP-Router have to announce this DNS-Server to your local clients, not sure if this configurable on your ISP-Router)

OK. The second option is what I am trying to achieve. The ISP router has some DNS related options: Static DNS (which is disabled by default) and DNS server (which point to the ISP ones). I guess I should modify one of those with the dumb AP IP address, right? But I have tried both options and it doesn't seem to work. Maybe I'm missing some option on the AP. Should the DNS server under Network->Interfaces->Lan be the main router's IP or the Acess Point IP?
I'm sorry for my ignorance in these topics.

Out of curiosity, I am wondering about the changes from ver 3.x.x to 4.0.5 and why dnsmasq can no longer parse the adb_list.overall. For the record,I use dnscrypt-proxy2, dnsmasq, dhcp, and Adblock.

To be honest, I just switched to a kernel 5.4.42 build that has Adblock 4.0.5 baked in. To avoid some issues, I backed up my config and removed problematic files from the tarball, then did a sysupgrade without restoring config, DL’d the user-installed apps I use and then restored config from backup. I didn’t realize the build included the Adblock version bump.

So, that sent dnsmasq into a boot loop, and Adblock complained about a /tmp config fault.

After some reading, I got those issues figured out, and all my dns tests seem to pass - DNSSEC, Leak Test, Randomness, and my NX.log file keeps getting bigger so it seems all is well, but. I notice in the system log that dnsmasq now faults on each line of the adb_list.overall file as it tries to parse it on startup.

Removing the /etc/config/dhcp entry

option serversfile '/tmp/dnsmasq.d/adb_list.overall'

Fixed that, but I am confused why dnsmasq cannot handle the adb_list.overall when it is the same format as Adblock 3.x.x generates.

I did see the direction to remove any


option serversfile '/tmp/dnsmasq.d/adb_list.overall'

just curious, don’t like confusion. Could be a stupid question too :wink:

Are there any additional settings needed to achieve that in OpernWrt? It is possible to set the DNS server in the ISP router, but it is not working. I guess I'm doing something wrong on the OpenWrt AP. I have dnsmasq enabled and I have set the ISP router's IP as gateway and DNS under the Lan interface (as per the wiki instructions). DHCP is ignored and both firewall and odhcpd disabled. I have deleted the WAN interface (maybe that was a mistake?).
Adblock is up and running. I haven't changed any of its settings. But it does not block anything.
I'm pretty sure I'm missing something stupid under DNS settings and I'm just proving my ignorance.

Example config for an adblock enabled AP on 192.168.0.10 (with enabled DNS- and DHCP-Server), gateway is an ISP router on 192.168.0.1 (with disabled DHCP-Server):

/etc/config/network:

[...]
config interface 'lan'
	option type 'bridge'
	option proto 'static'
	option netmask '255.255.255.0'
	option ip6assign '60'
	option ipaddr '192.168.0.10'
	option gateway '192.168.0.1'
	option ifname 'eth0.1 eth0.2'
	option dns '192.168.0.1'
[...]

/etc/config/dhcp (announce default gateway via dhcp_option):

[...]
config dhcp 'lan'
	option interface 'lan'
	option start '100'
	option limit '150'
	option leasetime '2h'
	list dhcp_option '3,192.168.0.1'
	option force '1'
[...]

Hope this helps!

Thanks. It works perfectly. Initially I was asking on how to do it maintaining the ISP router as DHCP server, but I ended up setting it in the (not so dumb anymore) AP. Everything is working (except ads, obviously), so I think I'll stick to this method.
Thanks again for this great and useful program!

hello,
anyone knows in which list are present domains to block:

  • samsung smart tv access to internet
  • netflix

this seems a little more than blocking advertisements, and i never got this sort of problems with old adblock 3.x, but not with adblock enabled my smart tv says i have no internet connection and, added to whitelist the domain for the smarttv, netflix says it can't connect to server..
thanks

I’ve been using Adblock with dnsmasq as a DNS backend since I first began using OpenWrt about 3 months ago, and it’s been pretty reliable. Typically blocking 21-25% of requests (at least the DNS Reports indicates such).

Reading the V4 PR thread, I noticed a post by @Fil indicating raw mode with dnscrypt-proxy2 was working well, and as I use dnscrypt-proxy2 I decided to compare the two and reconfigured Adblock to use raw/dnscrypt-proxy2 as the DNS Backend.

Right off the bat I noticed a significant drop in the blocked domains count, and the DNS Report began showing an OK response for domains that returned an NX response using dnsmasq as a backend.




root@MyDomain:~# cat /etc/dnscrypt-proxy2/adb_list.overall | grep blackberry
stun.voip.blackberry.com
turn.voip.blackberry.com
root@MyDomain:~#

Can anyone share some insight into where I’ve missed something in this setup?