Content Discovery
Finding paths, files, virtual hosts and parameters a web server answers for but never links: harvest known URLs first (archives, crawl, JS), then brute-force with a wordlist built for the target’s stack, then triage hits by hand.
How it works
- A hidden path is not a finding. It becomes one when it exposes data without auth, a working admin function, or source code. The underlying weakness is usually forced browsing / CWE-425 Direct Request (restricted URLs with no authorization), so obscurity is never the control (Invadel, Suvendu Dash).
- It runs after host discovery: Subdomain Enumeration then httpx probing, then discovery on every live in-scope host. Staging, dev and old subdomains are the soft ones (Suvendu Dash).
- Typical yield:
/admin/,/manage/,/internal/;config.php.bak,backup.zip,db.sql;/.git/;/api/v1/next to a live/api/v3/; debug and status pages, logs and default install pages. - MITRE files it as Active Scanning: Wordlist Scanning (T1595.003) (Invadel).
Techniques / payloads
1. Harvest real paths before guessing
gau example.com | uro > archived.txt # archived URLs, deduped by pattern
cat domains.txt | waybackurls | anew urls.txt # append only new lines
katana -u https://target.example -d 3 -jc -o crawl.txt # crawl + parse JS for endpoints
katana -u https://target.example -f qurl # field extraction: only URLs with query strings
cat wayback.txt | unfurl --unique keys # parameter names from history
meg --savestatus 200 /robots.txt # one path across many hosts- Old endpoints from the Wayback Machine often still work, or reveal naming patterns the current site follows (as93, Miessler on TomNomNom tools).
- Katana’s default fields are
url, path, fqdn, rdn, rurl, qurl, qpath, file, key, value, kv, dir, udir. Custom regex fields load from$HOME/.config/katana/field-config.yamlor-flc custom.yaml. On one target-f qurlcut 205 endpoints to 25 parameterised ones (ProjectDiscovery: Katana field extraction). - Scrape
robots.txtandsitemap.xml, and crawl manually through Burp with JS/CSS unblocked to set a baseline (YesWeHack). In one lab, arobots.txtDisallow of/backupled toProductTemplate.java.bakcontaining a hard-coded Postgres password (Backup-file lab). - Split the harvested folder and file names into a custom per-target wordlist. It often beats a huge generic list. JS mining is covered in JavaScript Analysis.
2. Wordlists (they matter more than the tool)
| List | What it is |
|---|---|
SecLists Discovery/Web-Content/ (raft-medium-directories.txt, api/api-endpoints.txt, common.txt) | Default general and API lists (as93) |
| Assetnote wordlists | Built from real-world data (Suvendu Dash) |
| trickest/wordlists | Per-technology lists generated from cloned repos (including *-all-levels.txt with every directory depth); robots.txt Allow/Disallow paths of the top 100/1k/10k sites; 1.4M-word “Inventory” subdomains from 50+ bug bounty programs; 940k cloud subdomains from CN/SANs of 7M+ certificates (trickest) |
| p0dalirius/webapp-wordlists | About 105k lists: every file and directory for each version of common webapps and CMSes, for version-exact discovery (webapp-wordlists) |
api_wordlist (actions.txt × objects.txt) | API function verbs × nouns. Run as a Burp Intruder Cluster Bomb to build getUser, deleteAccount and similar; add a third objects set for compound names like UserAccount (api_wordlist) |
| CeWL | Builds a list from keywords on the target’s own site (YesWeHack) |
Match the stack: PHP lists for PHP, .jsp/.do for Java, Tomcat, WordPress, Spring Boot Actuator, Jenkins or Kubernetes Dashboard defaults once fingerprinted. Start small and grow only on interesting hosts (Invadel, OSINT Team: wordlists).
3. Brute force with ffuf
ffuf -u https://t/FUZZ -w common.txt -mc 200,204,301,302,307,401,403 -rate 50
ffuf -u https://t/FUZZ -w words.txt -e .bak,.old,.zip,.txt -ac -rate 50 -o ffuf.json -of json
ffuf -u https://t/FUZZ -w list -recursion -recursion-depth 2 -maxtime-job 60 # per-job time cap
ffuf -u https://t/ -w vhosts.txt -H "Host: FUZZ" -fs 4242 # vhost discovery
ffuf -u "https://t/script.php?FUZZ=test" -w params.txt -fs 4242 # GET param names
ffuf -u "https://t/?PARAM=VAL" -w params.txt:PARAM -w values.txt:VAL # multi-keyword
ffuf -u https://t/FUZZ -w list -b "PHPSESSID=..." # authenticated- Noise control:
-fs(size),-fw(words),-fc(status),-ac(auto-calibrate the soft-404). Without these, a 200-for-everything catch-all buries real hits. - Defaults: 40 threads (
-t) and no rate cap. Set-rate/-pto stay inside program rules. The default match set is 200–299, 301, 302, 307, 401, 403, 405, 500. -requestreplays a raw request saved from Burp.--input-cmd 'radamsa --seed $FFUF_NUM ...'mutates request bodies. A defaultffufrclives at$XDG_CONFIG_HOME/ffuf/ffufrc, and repeatable CLI flags like-Hare appended to it, not overridden.- Sources: ffuf README, Intigriti ffuf guide, Invadel.
Alternatives: feroxbuster (Rust, recursive by default: feroxbuster -u https://t -w common.txt -x php,txt -d 2 --rate-limit 50), dirsearch (bundled list, good extension handling), Gobuster (dedicated DNS and bucket modes), and Burp Intruder for parameter or IDOR value fuzzing (Suvendu Dash, Invadel, YesWeHack).
4. Backup and variant guessing
Once a core file is known (for example settings.php), try settings.php.bak, settings.bak, settings.php.old, settings_old.php and settings.php~. Mirror hints from JS too: a config/ reference suggests trying config_old/ and config_bak/ (YesWeHack).
5. Triage
405means the path exists with the wrong verb, so retry POST, PUT, DELETE and PATCH (as93). Verb switching also applies to parameter discovery: in the case below, GET param fuzzing found nothing and POST-d "FUZZ=5"found the parameters.- A plain curl loop (
curl -sk -o /dev/null -w "%{http_code}" --max-time 5 "$BASE$p") gives the same three-way read: 404 absent, 405 wrong verb, 401 exists behind auth. Generic wordlists miss framework-specific routes: Flasgger serves its spec at/apispec_1.json, not/swaggeror/openapi.json, and that spec lists only routes with docstrings, so routes found by sweeping still need testing. Follow up withcurl -X OPTIONS -iand readAllowfor unexpected verbs. In zsh don’t name the loop variablepath(it is tied to$PATH) (curl full chain). 401/403: note them, and check whether the same content is reachable unprotected on another host or path. Follow redirects, because the body before a 30x can leak data. Try both/adminand/admin/.- In Burp, Bambdas over proxy history flag anomalies at scale: 3xx responses with a body over 1000 bytes (a missing
exitafter an auth redirect), HTML with more than one</html>, aContent-Lengthmismatch, header names containing spaces (SMTP on 443), JSON served astext/html, and GraphQL at non-standard paths found via aqueryparam containing\n(PortSwigger Bambdas).
Notable cases
- waybackurls → param mining → 4× SQLi.
waybackurls | uro | grep .php, then split CamelCase file names (getTargets.php→Targets/targets) into a parameter list.ffuf -X POST -d "FUZZ=5"foundcommitment,id,goalandlist, all injectable viasqlmap -r req.txt -p commitment --level 5 --risk 3 --tamper=between --no-cast(0xmahmoudJo0). See SQL Injection. - robots.txt →
/backup/*.java.bak→ DB password (Backup-file lab). See Hardcoded Secrets.
Defenses
- Deploy an explicit artifact set. Keep config, logs and data outside the web root. Never edit in place on production, because editors leave
~/.bakfiles. Keep non-prod off the public edge. Enforce authorization on every route (WSTG-CONF-03/04). - Detection signals: per-source 404 ratio (for example >50 req/5 min with >90% 404), many identical-size responses, the UA
Fuzz Faster U Fool v2.x, many distinctHostvalues to one IP (not logged by default in NGINX combined format or IIS), and.git/.envprobes. Alert when one of these is actually served, not on the request. A patient-rate/-prun defeats volume alerts (Invadel).
Related
- Reconnaissance (hub) · Subdomain Enumeration · Asset Discovery · JavaScript Analysis · Google Dorking
- API Discovery for API-specific route and version discovery · Web Fuzzing · Bug Bounty Automation · Secret Scanning
Sources
- Full Chain: Recon to Report with Nothing But curl · original
- ffuf - Fuzz Faster U Fool · original
- FFuF Fuzzer Guide (Intigriti) · original
- ffuf explained: web fuzzing, wordlists, detection · original
- Content Discovery for Bug Bounty · original
- Uncover Hidden Assets with Bug Bounty Recon: Fuzzing and JS Analysis · original
- Recon methodology for bug bounties (as93) · original
- A @TomNomNom Recon Tools Primer · original
- A Deep Dive on Katana Field Extraction · original
- trickest/wordlists · original
- webapp-wordlists · original
- api_wordlist · original
- The Best Wordlists Every Bug Hunter Needs · original
- Lab 3: Source code disclosure via backup files · original
- How I Found multiple SQL Injection with FFUF and Sqlmap · original
- Finding that one weird endpoint with Bambdas · original