View Single Post
  #8 (permalink)  
Old 07-09-2008, 03:04 AM
RobertVA
 
Posts: n/a
Re: Hosts file effectiveness
John Wunderlich wrote:
> RobertVA <robert_c72athotmail@invalid.com> wrote in
> news:eK0rOTU4IHA.3480@TK2MSFTNGP03.phx.gbl:
>
>> Am I misunderstanding the use of the Hosts file to block web
>> sites?
>>
>> I thought adding "127.0.0.1 acme.com" was supposed to
>> override the Domain Name Server's data for the IP address when ANY
>> browsers requested a page from acme.com (made up domain name),
>> directing the browser to the local hard drive. Since the requested
>> page probably isn't on my hard drive this should permit me to
>> block things like advertising pop-ups from that site.
>>
>> So many sites won't function without JavaScript. I'm not
>> enthusiastic about turning it off.
>>
>> However, I continue to find cookies from these domains when I scan
>> for tracking cookies. Third party cookies are turned off in my
>> browser security settings too. Today I was even subject to a
>> pop-up window with one of the supposedly blocked domains
>> displaying in the browser address bar!
>>
>> IF the sites opening these ads are using the site's actual IP
>> address to bypass the Hosts file, should the address bar be
>> displaying the IP address or the URL?
>>
>> TIA

>
> Keep in mind that the Hosts file is strictly a one-to-one mapping and
> it will override DNS lookups. The line in your example will block
> access to "acme.com" but won't block access to "www.acme.com" or
> "anything.acme.com" or "ads.acme.com".
>
> -- John


That would explain much of what's slipping through. Does whatever
processes the Hosts file recognize any wild card characters like "*"? It
would be handy if something like "127.0.0.1 *acme.com" would block
anything from the "acme.com" domain including sub-domains ("www..." or not).
Reply With Quote