From SkullSecurity
Revision as of 16:06, 21 February 2010 by Ron (talk | contribs)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search


This program simply checks whether or not you have the authoritative nameserver for a given domain. It is implicitly called by the other dns* programs I've written, all it does is look up a random subdomain and see if the response comes back.


./dnstest --domain <domain>

 -h --help
    Help (this page).
 -d --domain <domain>
    The domain name to check. The lookup will be for [random].domain.
 --dns <server>
    Set the DNS server. Default: the system's first DNS server.
 -s --source <address>
    The local address to bind to. Default: any (
 -p --port <port>
    The local port to listen on. I don't recommend changing this.
    default: 53.
 --rport <port>
    The port to send the request to. Default: 53.
 -u --username
    Drop privileges to this user after opening socket (default: 'nobody')
 -V --version
    Print the version and exit


There isn't really much to this program, but here's how it looks running on my laptop (which is the authoritative server for skullseclabs.org):

$ sudo ./dnstest
Listening for requests on
Sending request to
Trying to look up domain: avobwnjlopakgmdt.skullseclabs.org
Received a response: avobwnjlopakgmdt.skullseclabs.org
Contgratulations, you have the proper DNS server for this domain!