Subfinder
Skill ComeOnOliver/skillshub/skills/TerminalSkills/skills/subfinder
π§ The right skill, one API call. AI agent skills registry with token-efficient skill resolution. 5,000+ skills from 500+ top repos.From the repository description
npx -y skills add ComeOnOliver/skillshub --skill subfinderAssembled from the repository path, not quoted from the project. Check it against their README if it does not work.
SKILL.md
7.1 KB, ~1.7k tokens by cl100k_base, as published. Nobody here has run it
Subfinder
Overview
Discover subdomains of a target domain using passive sources. Subfinder queries certificate transparency logs, DNS datasets, search engines, and other OSINT sources to enumerate subdomains without directly touching the target infrastructure.
Instructions
Installation
# Go install (requires Go 1.21+)
go install -v github.com/projectdiscovery/subfinder/v2/cmd/subfinder@latest
# Or download binary
# https://github.com/projectdiscovery/subfinder/releases
# Or Docker
docker pull projectdiscovery/subfinder:latest
Basic Usage
# Enumerate subdomains for a single domain
subfinder -d example.com
# Multiple domains
subfinder -d example.com,example.org
# From a file of domains
subfinder -dL domains.txt
# Output to file
subfinder -d example.com -o subdomains.txt
# JSON output (includes source information)
subfinder -d example.com -oJ -o subdomains.json
Configuration
API keys for better results
Subfinder works without API keys but returns significantly more results with them. Configure in ~/.config/subfinder/provider-config.yaml:
# ~/.config/subfinder/provider-config.yaml
# Add API keys for passive sources to dramatically increase results
binaryedge:
- your-binaryedge-api-key # https://app.binaryedge.io
censys:
- your-censys-api-id:api-secret # https://search.censys.io/account/api
chaos:
- your-chaos-api-key # https://chaos.projectdiscovery.io
github:
- your-github-token # Personal access token (public repos scope)
shodan:
- your-shodan-api-key # https://account.shodan.io
securitytrails:
- your-securitytrails-key # https://securitytrails.com/app/account
virustotal:
- your-virustotal-api-key # https://www.virustotal.com/gui/my-apikey
# Free sources that don't need keys:
# Certificate Transparency (crtsh), DNSdumpster, HackerTarget,
# Wayback Machine, AlienVault OTX, RapidDNS
Source selection
# Use all sources (default)
subfinder -d example.com -all
# Use only specific sources
subfinder -d example.com -s crtsh,dnsdumpster,hackertarget
# Exclude noisy sources
subfinder -d example.com -es github
# List available sources
subfinder -ls
Advanced Usage
Recursive enumeration
Find subdomains of subdomains (e.g., dev.api.example.com):
# Enable recursive mode β finds deeper subdomains
subfinder -d example.com -recursive
# Limit recursion depth
subfinder -d example.com -recursive -max-depth 3
Filtering and processing
# Show only results from specific sources
subfinder -d example.com -cs # Show source for each subdomain
# Pipe to other tools for validation
subfinder -d example.com -silent | httpx -silent # Check which are live
subfinder -d example.com -silent | dnsx -silent # Resolve DNS
subfinder -d example.com -silent | naabu -silent # Port scan
# Rate limiting (respect API limits)
subfinder -d example.com -rate-limit 5 # 5 requests/second max
subfinder -d example.com -t 10 # 10 concurrent threads
Integration with other recon tools
# Full recon pipeline:
# 1. Find subdomains
subfinder -d target.com -o subs.txt
# 2. Check which are live (httpx)
cat subs.txt | httpx -silent -status-code -title -o live.txt
# 3. Screenshot live hosts (gowitness)
cat live.txt | gowitness file -f -
# 4. Port scan discovered hosts (naabu)
cat subs.txt | naabu -silent -top-ports 1000 -o ports.txt
# 5. Run vulnerability scan (nuclei)
cat live.txt | nuclei -t cves/ -severity critical,high -o vulns.txt
Passive vs Active Enumeration
Subfinder is passive by default β it queries third-party data sources, NOT the target:
PASSIVE (subfinder default) β safe, stealthy
βββ Certificate Transparency logs (crt.sh, Google CT)
βββ DNS aggregation (SecurityTrails, DNSdumpster)
βββ Search engines (Google, Bing dorking)
βββ Threat intelligence (Shodan, Censys, BinaryEdge)
βββ Internet archives (Wayback Machine)
ACTIVE (use additional tools) β touches the target
βββ DNS brute-forcing (shuffledns, puredns)
βββ DNS zone transfers (dig axfr)
βββ Virtual host discovery (ffuf -H "Host: FUZZ.target.com")
βββ TLS/SSL cert inspection (direct connection)
For authorized pentests, combine both: subfinder for passive discovery, then active brute-forcing for what passive sources missed.
Interpreting Results
Common subdomain patterns and what they reveal:
admin.example.com β Admin panel (high-value target)
staging.example.com β Staging environment (often less secured)
dev.example.com β Development server (may have debug enabled)
api.example.com β API endpoint (test for auth bypass)
old.example.com β Legacy application (likely unpatched)
vpn.example.com β VPN gateway (credential attacks)
mail.example.com β Mail server (phishing target)
jenkins.example.com β CI/CD (code execution potential)
grafana.example.com β Monitoring (information disclosure)
*.s3.amazonaws.com β S3 buckets (check for public access)
Prioritize targets: admin panels, staging environments, and legacy hosts are the highest-value findings because they're often less secured than production.
Examples
Map the attack surface of a target domain
Run subdomain enumeration on our domain example.com using subfinder. Find all subdomains, check which ones are live with httpx, identify the web technologies with whatweb, and produce a prioritized target list. Flag any staging, development, or admin subdomains as high-priority. Include the source for each subdomain so we know which passive sources are most valuable for this target.
Find forgotten or shadow IT subdomains
Our company has 5 registered domains. Enumerate all subdomains across all of them, cross-reference with our known asset inventory (list provided), and identify any subdomains we don't recognize β potential shadow IT or forgotten services. For each unknown subdomain, check if it's live, what it's running, and whether it has a valid TLS certificate.
Set up continuous subdomain monitoring
Build a subdomain monitoring pipeline that runs weekly on our 3 primary domains. It should compare results against the previous week's baseline, alert on new subdomains (potential new attack surface or subdomain takeover), and generate a diff report. Store historical data for trend analysis. Use subfinder for enumeration and httpx for liveness checks.
Guidelines
- Only run against domains you have explicit written authorization to test
- Passive enumeration (subfinder default) does not touch the target, but active tools like httpx and naabu do β ensure they are in scope
- Configure API keys for better coverage β free sources alone miss many subdomains
- Use rate limiting (
-rate-limit) to avoid overwhelming third-party data sources - Validate findings before reporting β some passive sources return stale or incorrect data
- Combine with active DNS brute-forcing (puredns, shuffledns) for comprehensive coverage on authorized engagements
What ships with it
Read from the repository
Just SKILL.md. No reference files, no scripts.