Definition
Subdomain Enumeration is the process of identifying subdomains associated with a primary domain. It expands the attack surface for penetration testing by revealing additional vectors that might be vulnerable.How It Works
- Passive Methods:
- Active Methods:
Key Characteristics
- Reveals hidden parts of a domain which may be vulnerable.
- Can include development, testing, or outdated environments.
- Subdomains might have different security levels than the main domain.
Comparison
| Method | Type | Tools |
|---|---|---|
| Certificate Logs | Passive | crt.sh |
| DNS Records | Passive | dig, nslookup |
| Brute-force | Active | subfinder, amass |
| Zone Transfers | Active | dig, nslookup |
Real-World Example
CVE-2021-22986 involved F5 BIG-IP, where unlisted subdomains led to unauthorized access. Tools like httpx can be used to verify accessible subdomains.Detection & Prevention
- Regular scans using tools like subfinder and amass.
- Monitor certificate transparency logs with crt.sh.
- Restrict DNS zone transfers to trusted IPs.
Common Misconceptions
- Only large domains have vulnerable subdomains: Even small websites can have them.
- Subdomains are always secure: They often have different security policies.
- Finding subdomains is illegal: It is a legitimate part of security testing when authorized.