DNS (Domain Name System) runs on TCP and UDP port 53. Nmap identifies it as domain. DNS translates hostnames to IP addresses and is a core service on virtually every network. Common implementations include BIND, Microsoft DNS, dnsmasq, and Unbound.
DNS is a goldmine for reconnaissance. Zone transfers (AXFR) can leak the entire domain inventory when misconfigured. Reverse lookups, subdomain brute-forcing, and record enumeration (MX, TXT, SRV, PTR) reveal internal hostnames, mail servers, and service locations. DNS can also be abused for data exfiltration tunneling.
Check for zone transfers first, then enumerate subdomains and record types. Tools like dig, dnsenum, and dnsrecon automate most of this. If the resolver allows recursive queries from external hosts, it can be leveraged for DNS amplification attacks.
Enumeration
DNS records, zone transfers, subdomains, and misconfig probing guides
DNS Record Enumeration
DNS Server Version Fingerprinting
DNS Zone Transfer (AXFR)
Exploit misconfigured DNS servers to perform AXFR zone transfers, extracting complete DNS records to map target infrastructure and discover hidden subdomains.
Reverse DNS Lookup Sweeps
Perform reverse DNS lookup sweeps to map IP ranges to hostnames, uncover hidden infrastructure, and identify targets during network enumeration.
Subdomain Brute Forcing
Systematically discover hidden subdomains by automating DNS queries against wordlists, revealing exposed infrastructure and expanding attack surface visibility.
Exploitation
DNS exploitation guides covering poisoning, takeover, and hijacking
ADIDNS Poisoning and Hijacking
Exploit Active Directory DNS zones by injecting wildcard records and hijacking ADIDNS to redirect traffic or capture credentials in AD environments.
DNS Cache Poisoning and Spoofing
DNS Rebinding – Bypass SOP to Reach Internal Services
Insecure DNS Dynamic Updates (RFC 2136)
Subdomain Takeover Exploitation
TSIG Key Abuse – Authenticated DNS Zone Manipulation
Data Exfiltration
Exfiltrate data via DNS queries using dnscat2, iodine, and manual methods