adblocking do these instructions still work and dns setup

Post new topic   Reply to topic    DD-WRT Forum Index -> Atheros WiSOC based Hardware
Author Message
nyddwrtuser330
DD-WRT User


Joined: 05 Mar 2018
Posts: 217

PostPosted: Tue Feb 23, 2021 14:35    Post subject: adblocking do these instructions still work and dns setup Reply with quote
found this on the wiki
https://wiki.dd-wrt.com/wiki/index.php/Ad_blocking

Im using r7800 on latest BS build with DNSmasq, DNSCrypt to OpenDNS and forced DNS
I also have addn-hosts=/mnt/sda1/hosts/restricted.hosts specified as an option for dns that contains just a couple of entries to allow me to cname bing and google to safesearch

lastly i have some legacy config lines that have been there a while to overcome some issues from old builds and may no longer be necessary

no-resolv
server=208.67.222.222
server=208.67.220.220
no-negcache
bogus-priv

I wanted to use the simpler first method but (im not a programmer). If i use the shell script i can execute either the first part-the file exists check, Or the second part. But if i try to execute both together it starts reporting errors with the if then fi portion about expecting the then or the fi.

Also i dont have the option to enable local dns in services but i have the option to specify the ip of one in setup - should that be the router?

Does this even work in my setup, as when i executed the two parts separately it did not seem to block anything - is there a good test method?

Any help would be appreciated, trying to get my family not to install all sorts of Adblockers in their browsers as i've found some to be malware.

thanks in advance
Sponsor
Alozaros
DD-WRT Guru


Joined: 16 Nov 2015
Posts: 6410
Location: UK, London, just across the river..

PostPosted: Tue Feb 23, 2021 15:05    Post subject: Reply with quote
hmm many good add blockers around much better than this one you have posted...
have a look here
https://pastebin.com/aySi7RhY

or here

https://forum.dd-wrt.com/phpBB2/viewtopic.php?t=307533

or here

https://forum.dd-wrt.com/phpBB2/viewtopic.php?t=321121

https://forum.dd-wrt.com/phpBB2/viewtopic.php?t=315773

_________________
Atheros
TP-Link WR740Nv1 ---DD-WRT 55179 WAP
TP-Link WR1043NDv2 -DD-WRT 55303 Gateway/DoT,Forced DNS,Ad-Block,Firewall,x4VLAN,VPN
TP-Link WR1043NDv2 -Gargoyle OS 1.15.x AP,DNS,QoS,Quotas
Qualcomm-Atheros
Netgear XR500 --DD-WRT 55460 Gateway/DoH,Forced DNS,AP Isolation,4VLAN,Ad-Block,Firewall,Vanilla
Netgear R7800 --DD-WRT 55460 Gateway/DoT,AD-Block,Forced DNS,AP&Net Isolation,x3VLAN,Firewall,Vanilla
Netgear R9000 --DD-WRT 55363 Gateway/DoT,AD-Block,AP Isolation,Firewall,Forced DNS,x2VLAN,Vanilla
Broadcom
Netgear R7000 --DD-WRT 55460 Gateway/SmartDNS/DoH,AD-Block,Firewall,Forced DNS,x3VLAN,VPN
NOT USING 5Ghz ANYWHERE
------------------------------------------------------
Stubby DNS over TLS I DNSCrypt v2 by mac913
nyddwrtuser330
DD-WRT User


Joined: 05 Mar 2018
Posts: 217

PostPosted: Tue Feb 23, 2021 19:45    Post subject: Reply with quote
Thanks, i implemented the SurprisedItWorks script. However, i have a qustion that may have been buried in the pages.

Do i Need a cron job with this script to refresh the bad host files?

Also, i had syslog disabled, running the script with syslog disabled caused something to go wacky and lost my wireless.

Enabled syslog and things ran as expected. i see this logs, does it fail funny if syslog is disabled?
Alozaros
DD-WRT Guru


Joined: 16 Nov 2015
Posts: 6410
Location: UK, London, just across the river..

PostPosted: Tue Feb 23, 2021 21:21    Post subject: Reply with quote
yep keep syslog enabled, its vital, it doesn't take anything to run it and its essential for the system...
disable traff daemon this is taking a big toll if you want to disable something....
make sure NTP time is enabled

and SFE is disabled (unless you need it)

hmm..m yep cron job is ok to run, but there is an updated version of custom location name as

0 12 * * * root /tmp/.rc_custom.sh

and you put the ad block script in custom box and add to start up script this line

sh /tmp/.rc_custom

in general i don't use cron job, as those ad-blocking lists are not all updated on daily bases as well its one job less...to care about..

_________________
Atheros
TP-Link WR740Nv1 ---DD-WRT 55179 WAP
TP-Link WR1043NDv2 -DD-WRT 55303 Gateway/DoT,Forced DNS,Ad-Block,Firewall,x4VLAN,VPN
TP-Link WR1043NDv2 -Gargoyle OS 1.15.x AP,DNS,QoS,Quotas
Qualcomm-Atheros
Netgear XR500 --DD-WRT 55460 Gateway/DoH,Forced DNS,AP Isolation,4VLAN,Ad-Block,Firewall,Vanilla
Netgear R7800 --DD-WRT 55460 Gateway/DoT,AD-Block,Forced DNS,AP&Net Isolation,x3VLAN,Firewall,Vanilla
Netgear R9000 --DD-WRT 55363 Gateway/DoT,AD-Block,AP Isolation,Firewall,Forced DNS,x2VLAN,Vanilla
Broadcom
Netgear R7000 --DD-WRT 55460 Gateway/SmartDNS/DoH,AD-Block,Firewall,Forced DNS,x3VLAN,VPN
NOT USING 5Ghz ANYWHERE
------------------------------------------------------
Stubby DNS over TLS I DNSCrypt v2 by mac913
Display posts from previous:    Page 1 of 1
Post new topic   Reply to topic    DD-WRT Forum Index -> Atheros WiSOC based Hardware All times are GMT

Navigation

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You cannot download files in this forum