0

My set of websites that I visit regularly is not very large. In order to increase privacy, I'd like to visit these sites directly without the need of a remote DNS resolve each time I visit it, but I also don't want to remember IP addresses.

Is it possible to automatically store the DNS entry locally and use it the next time I visit the site again, and only fallback to my ISP's DNS server if I don't have an entry on my local "DNS server"?

I'm especially interested in solutions for Windows (and Firefox if this should matter), but Linux answers would be OK, too (since I'm using it more often lately). I'd also be able to use a Raspberry Pi, if this leads to more elegant or robust solutions/answers.

To sum it up: First time visit of website -> use ISP DNS -> Store it on some local DNS database (same computer or local network) -> second visit -> use this local DNS database (+privacy and +speed).

0

2 Answers 2

1

This is what your router's DNS server does. It remembers which websites you have visited in the past and stores its IP address. If it doesn't resolve, it'll try to resolve it through the internet.

If this is not desired, you can edit your local hosts file and add the domains and ip addresses locally.

Do note that even if you store the DNS's locally, logging is done based on IP address anyway, so you are still tracable. Privacy is not guaranteed using this method.

3
  • About Privacy: At least I'm reducing my statistical or entropic fingerprint - some less unencrypted IP packets floating around from my computer. Also a "spy" with direct access to the DNS server can't know what I'm doing, at least.
    – Foo Bar
    Aug 5, 2014 at 15:41
  • 1
    You're mistaken. A domain only translates to an IP. A spy will not check for logs, it just sniffs the traffic and that is enough to "see" what you see. If you want to be protected, you would want to encrypt your data using an SSH tunnel. Having a local DNS as you suggest is rather pointless IMHO.
    – LPChip
    Aug 5, 2014 at 15:46
  • 1
    Note: Many/most browsers also cache DNS as well. Aug 5, 2014 at 16:15
0

On Windows this is built into the operating system's resolver. For Linux you can enable nscd caching but it is generally considered a bad idea. On both platforms domain names are cached in the same process so using firefox will not issue a new query every time you hit the page.

Usually they cache as much as the "TTL" record on the DNS record defines. Each record is setup with a time after which the record must be required. This is because most major services on the internet move IP addresses frequently as part of something known as "Global Service Load Balancing". This will constantly move your traffic to the least loaded service available, rather than always pointing you at a fixed point. In many cases you can also have the IP address that used to serve a given host stop serving it, for example if the host moves. This is especially common with services using ELB in AWS.

You can setup a router that force caches DNS records using bind but it is virtually universally accepted as a bad idea as you will quickly start experiencing a very, very broken internet. Same goes for using /etc/hosts and such.

If you want to anonymous DNS you can pay for such a service, or you can use tor with "no resolving" proxy mode so the dns query is performed on the exit tunnel. For local only operations you can either use an DNS provider that enables relaying but is likely not logging, or you can VPN your DNS traffic.

Not the answer you're looking for? Browse other questions tagged .