Branding_print


Go Back   Web User Forums > Welcome > Hints and Tips

Reply
 
Thread Tools Search this Thread Display Modes
  #1  
Old 07-10-09, 17:56
darkness darkness is offline
256Kbps
 
Join Date: Apr 2009
Posts: 22
Default Protect a PC with the HOSTS file

Firstly, If you have Spybot - Search & Destroy your hosts file will already have entries in it. Do not change anything. You are already protected

The hosts file is a plain-text file and is traditionally named hosts, and is most often located at the path /etc/hosts. It contains the mappings of IP addresses to host names. This file is loaded into memory (cache) at startup, then Windows checks the Hosts file before it queries any DNS servers, which enables it to override addresses in the DNS. This prevents access to the listed sites by redirecting any connection attempts back to the local (your) machine.

The best bit about it is that you can also use a HOSTS file to block ads, banners, 3rd party Cookies, 3rd party page counters, web bugs, and even most hijackers. This is accomplished by blocking the connection(s) that supplies these little gems.

Example - the following entry 127.0.0.1 ad.doubleclick.net blocks all files supplied by that DoubleClick Server to the web page you are viewing. This also prevents the server from tracking your movements. Why? ... because in certain cases "Ad Servers" like Doubleclick (and many others) will try to open a separate connection on the webpage you are viewing.

Protect yourself using the host file. All the information is located on this website http://www.mvps.org/winhelp2002/hosts.htm . The host file is updated about once a month.

As with everything be careful.
Reply With Quote
  #2  
Old 07-10-09, 17:58
darkness darkness is offline
256Kbps
 
Join Date: Apr 2009
Posts: 22
Default Re: Protect a PC with the HOSTS file

If anyone has got anything to add please feel free to do so.
Reply With Quote
  #3  
Old 07-10-09, 18:46
BurrWalnut BurrWalnut is offline
Chippendaler
256Gbps
 
Join Date: May 2003
Posts: 3,758
Default Re: Protect a PC with the HOSTS file

Here are a few more details to add to Darkness's post:

In XP, Vista and 7, it is normally located at C:\Windows\System32\Drivers\etc\ If it is not there, look at this registry key HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Servic es\Tcpip\Parameters\DataBasePath for its location.

In essence, the 127.0.0.1 at the beginning of each line stops access to the website listed alongside it, so if there are entries like 127.0.0.1 coolwebsearch.com, don’t remove them as they help to protect the system from malware sites. However, if you see entries with known names like webuser.co.uk or ibm.com you should remove them, as malware is trying to block access to them (127.0.0.1) or redirect them (n.n.n.n) to another website.

So:
127.0.0.1 NastySite.co.uk is a good entry
127.0.0.1 webuser.co.uk is a baddie
123.4.5.6 webuser.co.uk is a baddie

When attempting to make changes to it, you may be denied access as it could be read only. To make it accessible, right-click it > Properties and remove the Read-only attribute. Now make a backup copy of it before making changes.

You can delete all the entries but leave the line 127.0.0.1 localhost. Comment lines can be recognised by beginning with #. When saving it, make sure you select Save As without an extension, otherwise it will be given a .txt extension.
Reply With Quote
  #4  
Old 07-10-09, 20:06
darkness darkness is offline
256Kbps
 
Join Date: Apr 2009
Posts: 22
Default Re: Protect a PC with the HOSTS file

Thank you BurrWalnut

A much appreciated addition to this post
Reply With Quote
  #5  
Old 09-10-09, 14:11
ourstanley's Avatar
ourstanley ourstanley is offline
512Gbps
 
Join Date: Jul 2003
Location: Yorkshire, England
Posts: 8,574
Default Re: Protect a PC with the HOSTS file

Better still IMHO is to install a hosts manager program such as HostsMan 3.1.57 which will not only add to your hosts file the current 'baddies' but will also allow you to edit, either by adding or deleting your own personal entries.
BTW the MVPS HOSTS file was updated yesterday. Thanks roddy32
Reply With Quote
Reply

Bookmarks

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


Search

Search

© Copyright IPC Media Limited 2009, All rights reserved





All times are GMT. The time now is 22:44.


Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2010, Jelsoft Enterprises Ltd.
© Copyright IPC Media Limited 2010, All rights reserved