3 ms·
Hi! Can you elaborate on the ad-blocking at DNS server thing? Thanks!
by koevet 10y ago
Hi! Can you elaborate on the ad-blocking at DNS server thing?
Thanks!
- djsumdog 10y agoThey most likely use the /etc/hosts file or run a local DNS server that redirects all ad server URLs to 127.0.0.1. If you block ads this way and run a little web server locally, you can also log all the ad requests and see some of the information they're passing around. Some people also display little random images from that web server so they can see where the ads would have been on the page they're browsing. If you don't mind ads being served by the site owners, you'll also be able to see these ads. If ads running on the same server this bothers you, you usually can't block them via DNS and so this is a limitation over something like uBlock Origin which can have rules for dom IDs on a page.
- Fnoord 10y agoPi-Hole [1], for example. Using a proxy in your system settings together with e.g. Privoxy (which runs locally or remotely on e.g. a RPi) also works (but that is proxy-based filtering). Both DNS-based and proxy-based filtering can be circumvented. I just use uBlock everywhere, and have been playing around with AdNauseam. These work well enough. The only time those fail miserably is when a browser is being embedded in an application, like on Android and iOS apps. I tend to buy the premium version anyway if I really like an app (no subscriptions though!). There are 2 ways to circumvent those apps with ads. 1) use web browser (w/uBlock) instead or 2) use a DNS-based filtering (such as a Pi-Hole). However the latter option requires network access to the DNS server of the Pi-Hole which isn't there when you're roaming (e.g. on 3G/4G or a foreign Wi-Fi network). A workaround to that is using a VPN to your RPi. For me, that is too much work (had a similar setup in past), and the upload speed on my home network isn't to write home about (YMMV). Btw, not sure if all of this can be worked with DNSCrypt since when you're roaming there's the vulnerability of DNS hijacking. [1] https://pi-hole.net https://pi-hole.net
- freehunter 10y agoYep, I run Pi-Hole. I ran uBlock before, but a lot of sites would stop working when they detected it, and it didn't work on devices that didn't have browser extensions. I'm pretty happy with this setup.