Block Malware & Ads - Protect Privacy & Browse Faster Too!

How to do things, solutions, recipes, tutorials
Post Reply
Message
Author
puppyite

Block Malware & Ads - Protect Privacy & Browse Faster Too!

#1 Post by puppyite »

Like the title says all this can be easily accomplished by editing your hosts file. Here’s how:

Go to http://www.mvps.org/winhelp2002/hosts2.htm and download hosts.zip. Save it somewhere on your HD. Open the archive and save it as a text file named hosts_download (or any name you like).

Find hosts file in /etc, open it in a text editor, select Save As, then save the file as hosts_backup (or use any name you feel will remind you of it’s origin).

In a text editor open the hosts_download file you previously downloaded. Select and copy the entire contents of the file by pressing ctrl + a.

Again in a text editor open the hosts file in /etc. Place your cursor one or two lines below the last line of text, right click and then select Paste. Note: Be careful not to alter any text from the original hosts file. You only want to add the contents of the hosts file you downloaded to the end of your original hosts file.

Save and then close the hosts file. Note: Do not add an extension to the file name or change the case.

Click the Advanced options tab of the Shutdown menu and select Restart X Server.

After X restarts open your browser and start enjoying your new ad and malware free internet experience!

Note: The hosts file you downloaded will only block malware and advertisements. It will not block pornography. It does not filter sites based on any moral criteria.
Note: You should visit http://www.mvps.org/winhelp2002/hosts.htm peridocially to check for and download updated hosts files. The file date is visible at the top of hosts.zip.
Note: You may need to clear your browsers cache to remove any persistent ads.
Note: AFAIK a hosts file is equally functional with or without a firewall.
Note: I have been downloading and using the hosts file from the above site in WIN98SE for 10 years (except that the filename must be uppercase for Windows). I now use a hosts file from the same source in Puppy 4.2.1 and 4.1.2 with equal success.

I did not originate the idea of using a hosts file in Puppy. It has been discussed previously in these threads: Hosts File - Faster web browsing and How To utilize a Hosts File

More about hosts files: Using the Hosts File with Unix-style OS's

Your comments and questions are welcome.
Last edited by puppyite on Sat 29 Aug 2009, 16:06, edited 1 time in total.

panzerpuppy
Posts: 632
Joined: Tue 02 Oct 2007, 07:39

#2 Post by panzerpuppy »

Much easier:

1. Install the Opera 10 .PET package by Synth:
http://www.murga-linux.com/puppy/viewtopic.php?t=43950

2. Activate Opera Turbo (blocks flash ads)

3. Enjoy lightning-fast and ad-free browsing :)

Bruce B

#3 Post by Bruce B »

Thanks for the post.

For anyone's information . . .

The hosts file works. Used for filtering, it blocks contact with the site, (unless the contact is initiated with a direct IP address).

It works on every application without any application configuration or potential for dependency issues.

It can also be used to bypass name to IP address lookups and speed things up some that way also.

An ideal situation for me is build a custom hosts file based on my actual surfing. The file includes both resolves and filters. And believe it or not Puppy (SeaMonkey) logs all the browser connections.

puppyite

#4 Post by puppyite »

Advantages of using a hosts file as described in my OP:

No additional software needed, just hosts.zip (145KB).

You already have a hosts file, why not make it do double duty?

No need to download, install or learn new software as the hosts file works with any browser (maybe any OS too?).

No need to manually select what to block as hosts.zip will automatically block 17,000 malware and ad servers.

Hosts.zip is regularly updated and IIUC benefits by input from tens of thousands of users.

PS: I may be new to Linux but this isn't my first rodeo ;)
Last edited by puppyite on Wed 26 Aug 2009, 17:53, edited 1 time in total.

Bruce B

#5 Post by Bruce B »

puppyite,

Don't take it critical. panzerpuppy said Install the Opera 10 .PET package by Synth: - it's much easier.

What ever he is talking about and comparing to is very, very different. So I did some double duty, it's not that I was trying to tell you anything. Rather others.

Anyone following the topic you started gets the benefit of some reinforcement. I hope you understand. In fact I think if you will reread the post in that context it will make perfect sense.

Bruce

puppyite

#6 Post by puppyite »

Bruce B wrote:puppyite,

Don't take it critical. panzerpuppy said Install the Opera 10 .PET package by Synth: - it's much easier.

What ever he is talking about and comparing to is very, very different. So I did some double duty, it's not that I was trying to tell you anything. Rather others.

Anyone following the topic you started gets the benefit of some reinforcement. I hope you understand.
Your reinforcement about the benefits of using a hosts file are a welcome addition to the thread.

If anyone prefers to take panzerpuppy up on his suggestion to install Opera 10 rather than use a hosts file that’s fine by me. Doubtless Opera 10 is a capable browser and many will find the pet file a convenient means to install it.

PS to everyone: The hosts file is useful for Opera 10 too. ;)
Last edited by puppyite on Wed 26 Aug 2009, 19:05, edited 1 time in total.

panzerpuppy
Posts: 632
Joined: Tue 02 Oct 2007, 07:39

#7 Post by panzerpuppy »

...and for even better protection, use a *real* HOSTS file:

http://blocklistpro.com/download-center ... s.zip.html

;)

puppyite

#8 Post by puppyite »

panzerpuppy wrote:...and for even better protection, use a *real* HOSTS file:

http://blocklistpro.com/download-center ... s.zip.html

;)
Thank you for your input. I’m looking at the hosts file you suggested right now, if I like it I may combine it with the hosts file I linked to in my OP for use on my PC’s.

One of the things I like about the hosts file I currently use is that the filtering criteria is fully stated at the web site. I wonder if the file you suggested uses the same standard?

Edit:
I searched the hosts file you recommended and found the following entries that IMO look irrelevant. I visited all these sites and they seemed harmless enough to me:
www.selu.edu (Southeastern Louisiana University)
www.educationtest.com
www.educorp.com
www.eduy.com
www.pjwstk.edu.pl

I also found *many* entries intended to filter pornography. I prefer to make my own judgements about these things rather than let someone else decide for me but YMMV:
www.sensual-erotica.com
www.seniorsexxx.com
www.seniorsizzle.com
www.3dsex.com

I suspect there are more questionable entries but IMO it’s not worth pursuing any further. I will not be using this hosts file.

Post Reply