Skip to content

Instantly share code, notes, and snippets.

@shagamemnon
Forked from tuksik/dig_cs.sh
Last active April 24, 2020 18:15
Show Gist options
  • Save shagamemnon/d5bd027bd08fce58365ecc6dd460be94 to your computer and use it in GitHub Desktop.
Save shagamemnon/d5bd027bd08fce58365ecc6dd460be94 to your computer and use it in GitHub Desktop.
Frank's dig cheat sheet
# force recursion back to root nameservers (helpful for bypassing caches)
dig www.cloudflare.com A +trace

# get the address(es) for yahoo.com
dig yahoo.com A +noall +answer

# get a list of yahoo's mail servers
dig yahoo.com MX +noall +answer

# get a list of DNS servers authoritative for yahoo.com
dig yahoo.com NS +noall +answer

# get all of the above
dig yahoo.com ANY +noall +answer

# get a host’s IPv6 address using the AAAA option.

dig www.isc.org AAAA +short

#If the domain you want to query allows DNS transfers, you can get those, too.
dig yourdomain.com AXFR
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment