dnsAgent is a tools which can forwarding DNS requests to TCP mode, and prevent DNS spoofing, and use cache to improve the speed.
-
Start daemon
# python dnsAgent.py -
Edit /etc/resolv.conf
# echo "nameserver 127.0.0.1" > /etc/resolv.conf
First request
xx@creac ~ $ time nslookup www.google.com
Server: 127.0.0.1
Address: 127.0.0.1#53
Non-authoritative answer:
Name: www.google.com
...
Address: 74.125.128.103
real 0m0.108s
user 0m0.009s
sys 0m0.006s
Second request
xx@creac ~ $ time nslookup www.google.com
Server: 127.0.0.1
Address: 127.0.0.1#53
Non-authoritative answer:
Name: www.google.com
...
Address: 74.125.128.103
real 0m0.015s
user 0m0.008s
sys 0m0.006s
-
Requires Python 2.6 or 2.7
-
Install gevent to improve performance