Monday, July 25, 2011

How To Check Reverse DNS Lookup

       People can remember Domain Name rather than ip-address.For an example www.debian.org than their ip-address 206.12.19.7.There are two types DNS, Forward DNS and Reverse DNS.

Forward DNS : Networks use the Domain Name System to determine the IP address associated with a domain name.


Reverse DNS : Reverse DNS lookup is the inverse process, the resolution of an IP address to its designated domain name.

dig is the command to make the DNS Queries.

root@debian:~# dig +noall +answer debian.org

Output :

debian.org.        3547    IN    A    206.12.19.7
debian.org.        3547    IN    A    128.31.0.51

+noall, +answer option tell the dig command to report only the answer of the DNS query and skip the rest of the output.

Reverse DNS can be checked in two method, one with the -x option passing to the dig command and other host command.

Method 1:

root@debian:~# dig  +noall +answer -x  128.31.0.51

Output :

51.0.31.128.in-addr.arpa. 1745    IN    PTR    senfl.debian.org.


Method 2:

root@debian:~# host  128.31.0.51

Output :

51.0.31.128.in-addr.arpa domain name pointer senfl.debian.org.

Common Uses of Reverse DNS :

1.Anti-spam
2.Network troubleshooting
3.Avoid spammers and phishers using a forward confirmed reverse DNS etc

No comments:

Post a Comment