Ad blocking = data savings [Guide]

  • 2
  • Idea
  • Updated 7 months ago
  • Not Planned
  • (Edited)
Normally I get on here to complain, but I thought I'd share some knowledge this time and help some people out. As we all know, satellite internet is slow, expensive, and metered (for a reason though). But there are ways to conserve data and make your browsing experience more pleasant.

Many of you are probably using an ad blocker, usually in the form of a browser extension. But this does little outside of cosmetic filtering. It does not prevent ads from being loaded, but rather removes them afterwards and rearranges the page. So while you may not be getting plastered with ads, they're still wasting bandwidth. But there's a particular FOSS (free and open source) program that can save the day: Privoxy. It prevents ads from ever being requested.

{Downloading}
These links are from Privoxy's official website and are completely safe.
Windows: privoxy-3.0.26.zip
macOS (OS X): Privoxy 3.0.26 64 bit.pkg
Linux: Install Privoxy using your package manager. If you use Linux and don't know how to do this, go back to Windows or macOS and follow those instructions.

{Setup}
Step 1: Install Privoxy. Windows users will need to extract that .zip file first, and make sure the "start at login" option is checked. On macOS and Linux, Privoxy registers itself as a service and runs in the background automatically (Linux users will need to enable the service manually, again, Linux users shouldn't need a how-to for this).

Step 2: Go to my GitHub repository:
https://github.com/ArgentWarrior/privoxy-adblock

Step 3: Download the contents of my repository with the button in this screenshot (the one highlighted in blue). These files tell Privoxy what to block, and without them Privoxy does absolutely nothing useful.


Step 4: Extract that .zip file (Safari does this automagically). Place "easylist.script.filter" and "easylist.script.action" in Privoxy's config directory.
On Windows, this is at "C:\Program Files (x86)\Privoxy\". Navigate to that folder in the file explorer.
On macOS, this is at /usr/local/etc/privoxy, and the easiest way to open a Finder window there is with the command line. Open Terminal.app and run this command:
open /usr/local/etc/privoxy
On Linux, this is in /etc instead of /usr/local/etc.

Step 5: Edit the configuration file using your favorite text editor. This file should be in the folder you just navigated to in the previous step.
On Windows this file is called "config.txt" (I think), and you will need to run your editor (probably Notepad) as Administrator, or else you won't be able to save.
On macOS, this is yet another task that the command line wins at. Enter your password when prompted, and don't be confused if you don't see stars or anything. Keystrokes don't echo (this is a security feature, Linux does it too).
sudo nano /usr/local/etc/privoxy/config

Step 6: Scroll down to the "actionsfile" section and add the last line in white to your config. I'm using Vim, but it should look roughly the same as this.


Step 7: Scroll down just a little more to the "filterfile" section, and again, add the last line in white to your config.


Step 8: Save your config and reboot. If you're using Nano on macOS, Ctrl+X (not Cmd+X) will prompt you to save, hit Enter.

Step 9: Configure your system proxy settings to route all HTTP and HTTPS traffic through 127.0.0.1:8118. Do not use this for FTP or any other protocol as it will prevent you from being able to use them.
You'll have to Google this part. I don't have a Windows machine to demonstrate on, nor do I feel like explaining how to do this, as it varies greatly by operating system.

Step 10: Enjoy faster, advertisement-free browsing.

Note: I am not responsible for anything that happens to your computer as a result of you following these instructions, including (but not limited to) loss of connectivity, fried motherboards, nuclear war, and universe-ending paradoxes. This should work just fine for you and I will try to help you if it doesn't, but don't type angrily at me if you're a fringe case.

Challenge mode: Run Privoxy on a dedicated machine (like a home server) and open it up to your entire LAN. If you know how to RTFM and/or use Google this is easy.

Edit: No [code] tags? Come on...
Photo of sildein

sildein

  • 40 Posts
  • 12 Reply Likes

Posted 2 years ago

  • 2
Photo of Old Labs

Old Labs

  • 3703 Posts
  • 3722 Reply Likes
Many of you are probably using an ad blocker, usually in the form of a browser extension. But this does little outside of cosmetic filtering. It does not prevent ads from being loaded, but rather removes them afterwards and rearranges the page. So while you may not be getting plastered with ads, they're still wasting bandwidth.
Not universally true for all ad blockers...

There are two methods used in content blocking.

The first is element hiding where the ad blocker simply injects code to hide the ad (or simply make it not visible). This is fine for those who aren't faced with severe data limits and generally requires more than simple hiding to ensure a page with forced hidden (or blocked) elements displays properly as its author intended.

The second  is asset (or request)  blocking and the extension does prevent the browser from downloading (or requesting) an asset if its URL includes specific keywords or expressions or matches a known ad content delivery network. This is more effective for ad content delivered through java script.

Robust ad blockers utilize both methods - however, some confusion/data leakage results with Exede due to it's web acceleration software which can prefetch (making its way to the modem) some minimal amount of static ads due to its "bundling" of requests to overcome inherent satellite latency for non-secured protocols. Fortunately, ViaSat can't perform deep packet inspection on secure sites (or shouldn't be able to who knows these days) 

But yes running a proxy as suggested is a more elegant/thourough approach offering some other advantages beyond simple ad blocking - but I think you'll find many casual users either won't or refuse to RTFM ;)

In general satellite users should pick a solution that both hides (eliminates the annoyance part) and blocks (the excessive data usage part).

Much the same for Flash/HTML5 media, pick a solution that both stops autoplay (the eliminate annoyance part) and preloading (the HTML5 excessive data usage part). Most Flash blockers simply stop autoplay - Flash Control for Firefox  however stops both autoplay and preload for the most part.   

 


(Edited)
Photo of sildein

sildein

  • 40 Posts
  • 12 Reply Likes
>tfw no upvotes

Photo of Kathy Owen Morgan

Kathy Owen Morgan

  • 9 Posts
  • 1 Reply Like
I am not an advanced person on doing these types of things but I am willing to try anything to save data on Excede. I managed to get all first 8 steps done but have no clue where to begin or what to google to make the last step happen for windows 10. Thank you for your time to post this . Could you give a little more direction on step 9 , would love to enjoy step 10

Thank you
Kathy
Photo of Old Labs

Old Labs

  • 3703 Posts
  • 3722 Reply Likes
In Windows, it's typically done at the browser level:

http://www.howto-connect.com/windows-10-customize-proxy-server-settings-in-browsers/

But really, your better option may be to simply run Firefox as your browser and install both the AdBlock Plus and Flash Control extensions for Firefox - but I'm just not inclined to recommend a proxy server to non-techies ;)

For Windows 10 usage itself look at the following:

http://merabheja.com/internet-data-usage-in-windows-10/

and/or

http://merabheja.com/internet-data-usage-in-windows-10/
Photo of Kathy Owen Morgan

Kathy Owen Morgan

  • 9 Posts
  • 1 Reply Like
I think I found out here how to do this here ( http://www.digitalcitizen.life/how-set-proxy-server-windows-10 ) Is there already a proxy setting set? Will this change that and if it does and this doesn't work can I change it back? Or will adding a new one not do anything  to worry about? Also as shown below do I add the dot after the last 8?
127.0.0.1:8118.
Photo of sildein

sildein

  • 40 Posts
  • 12 Reply Likes
There shouldn't already be a proxy set, no. And you could easily change it back.
And omit that dot, and the colon if there's a separate space for the port. 127.0.0.1 is the IP (which is actually a loopback interface that points to localhost, everything has it) and 8118 is the port.
(Edited)
Photo of Brad

Brad, Viasat Employee

  • 3047 Posts
  • 1069 Reply Likes
Ad blocking will certainly help skim off data usage and is a very effective practice to put into use. Some pages like Forbes will know and won't grant access but most will allow you to whitelist them for ads, but for the most part doing this or doing something simpler like adding Ad Blocker will help out.

Thanks for the how to Jesse! I hope some people find this useful!
Photo of sildein

sildein

  • 40 Posts
  • 12 Reply Likes
Subscribing to an anti-adblock killer list helps with sites like that. Extensions are still useful for the cosmetic filtering part and for things I don't feel like adding to Privoxy even if you use my method ;)

And personally I wouldn't worry about sites that block adblock users outright, they tend to have an unrecoverable loss of traffic even after they stop doing it. It's basically suicide for a website.
(Edited)
Photo of caseyd

caseyd

  • 11 Posts
  • 0 Reply Likes
Thanks for this nice article.

Here's what I do. perhaps I should write a guide?

1) after the Exede modem I have a hardware firewall.

1.1 ) On that appliance I block almost all the IP numbers for hardware firmware updates: meaning phones/tablets. However I have also blocked Denon; my AV receiver gets updates. our Juicebox. Any piece of hardware which is going to auto-update is denied.

1.2 ) On the firewall I block the Apple Store, the Google Store, Adobe. I also have unearthed IP numbers/ranges for Apple OS updates.

1.3) I have left off Microsoft. Not allowed in house. :P just checking to see if you are reading this wall of text.

2) the hardware firewall handles DHCP for clients. This is where you can throttle visitor's kids hardware.


3) for primary DNS I hand out the IP number of a Raspberry Pi running Pi-Hole. Pi-Hole is scheduled to grab blacklists ( just before my account's 'billing date' ) and uses that to block outgoing requests for... hmm about 10K sites last I checked. rilly.

3.1) given satellite latency any overhead involved in routing DNS through the Pi hasn't been a real-life issue.

this works pretty well.

NOTE: we're a Firefox house and run it with ad block software - in addition to the above.
Photo of Kathy Owen Morgan

Kathy Owen Morgan

  • 9 Posts
  • 1 Reply Like
1.1 ) On that appliance I block almost all the IP numbers for hardware firmware updates: meaning phones/tablets. However I have also blocked Denon; my AV receiver gets updates. our Juicebox. Any piece of hardware which is going to auto-update is denied.

How do you do that? Yes a guide would be nice. In one day once again 2 gb used which is insane. I used to use only 4 in a whole month.
Photo of Diana

Diana, Viasat Employee

  • 2215 Posts
  • 417 Reply Likes
Hi caseyd. Thanks for posting this information.  It may help many with issues of data.
Photo of Stealth

Stealth

  • 1 Post
  • 0 Reply Likes
How do I keep the Ad blocking up to date?

Thank you