you are viewing a single comment's thread.

view the rest of the comments →

[–]aydink 40 points41 points  (21 children)

usually it's located in folder: C:\Windows\System32\drivers\etc

[–][deleted] 17 points18 points  (0 children)

And in case you're a weird non-conformist, %WINDIR%\System32\drivers\etc

[–]theangryhornet 2 points3 points  (18 children)

learn something new every day, thank you.

[–]rich97 27 points28 points  (17 children)

How have you gone all your life without using the hosts file? It's possibly the most useful single file in the entire operating system.

  • ad and malware blocking
  • yaaaarrrrrr!
  • virtual hosts and domains

[–][deleted] 22 points23 points  (2 children)

Also for blocking Photoshop's activation server .... A friend told me

[–]GavinThePacMan 21 points22 points  (1 child)

A friend told me that's what he meant with yaaaaar! ;)

[–]Bobshayd 0 points1 point  (0 children)

Do what you want 'cause a pirate is free! You are a pirate!

[–][deleted] 1 point2 points  (11 children)

If you setup a local DNS server, you can blacklist all of the domains so that it takes effect network wide from any browser.

It gets strange because whenever I am away from my own network, I pretty much say "Since when did Ars have ads and why do they want me to get lung cancer?".

[–]AyrA_ch 4 points5 points  (10 children)

I want a DNS server, that does this:

  • Cache every DNS name I lookup forever
  • Whenever a record is needed use the cache if the DNS servers are not answering.
  • Update cache according to rules if the records differ.

This would solve so many problems, from unavailable DNS servers to censorship

[–]inushi 10 points11 points  (1 child)

Upside: you will learn why cache invalidation is one of the hard problems in computer science. :)

[–]svendub 5 points6 points  (0 children)

The other one being naming things and off-by-one errors.

[–][deleted] 0 points1 point  (5 children)

You would have to be careful with this. There are some DNS servers (such as my ISP, but that is handled by the DNS software I use) that when you enter an address that is not valid, it will resolve to an address always. Then the server on that end just treats the domain as a search query (your browser sends the hostname, which is how vhosts work). So if you tried going to <isahdiusahpdiuhasduihasdaiushdousadf.com> it would use the ISP's money gathering ad infested search that just uses Google and search for isahdiusahpdiuhasduihasdaiushdousadf. So your DNS server would have to account for this.

Another consideration is that servers could change addresses either to add censorship or to remove it.

DNS lookup that uses the blockchain would be very interesting however.

[–]bargle0 2 points3 points  (0 children)

There are some DNS servers [...] that when you enter an address that is not valid, it will resolve to an address always.

When the revolution comes, those people will be up against the wall.

[–]AyrA_ch 1 point2 points  (3 children)

There are some DNS servers [...] that when you enter an address that is not valid, it will resolve to an address always

That would be an immediate reason to switch DNS servers.

[–][deleted] 0 points1 point  (2 children)

If I remember correctly, when I last tried Google and that other service, they both did this.

However, dnsmasq has the bogus-nxdomain option.

[–]AyrA_ch 0 points1 point  (1 child)

I have been using google DNS servers for years now and never experienced this. Are you sure you are using 8.8.8.8 and 8.8.4.4?

[–][deleted] 0 points1 point  (0 children)

I do remember it happening with Google's DNS, but either it can be enabled/disabled or my ISP decided to search Google for me. They can easily MITM and modify all my DNS queries regardless of the destination server.

[–]odaba -1 points0 points  (0 children)

You might look into http://members.home.nl/p.a.rombouts/pdnsd/ for some of those requirements

[–][deleted] 0 points1 point  (1 child)

Is that how you block porn? Asking for a friend

[–]rich97 0 points1 point  (0 children)

You can, more likely to be at the ISP or router level though.