Finding more hostnames is finding more attack surface. Ffuf handles both DNS subdomain brute-forcing and virtual host (vhost) enumeration — and the difference between them matters.

Subdomain vs VHost

Subdomain is a DNS concept. admin.target.htb has (or doesn’t have) a public DNS record pointing to an IP. If the record exists, a browser can reach it by name.

Virtual Host is a server-side configuration concept. One web server with one IP hosts multiple sites. When a request arrives, the server looks at the Host: header and routes to the matching site config. A vhost doesn’t need a public DNS record — it just needs the right Host: value in the request.

Why both matter for an engagement:

  • A DNS fuzz finds sites the internet can see
  • A vhost fuzz finds internal sites that resolve but aren’t advertised in DNS — admin panels, dev environments, old staging sites

Always run both.

DNS Subdomain Fuzzing

ffuf -w /opt/useful/seclists/Discovery/DNS/subdomains-top1million-5000.txt:FUZZ \
     -u https://FUZZ.target.htb/

This only finds subdomains that resolve. If the DNS record doesn’t exist, the connection fails and ffuf shows nothing.

Useful DNS wordlists

Discovery/DNS/subdomains-top1million-5000.txt     fast first pass
Discovery/DNS/subdomains-top1million-20000.txt    broader
Discovery/DNS/subdomains-top1million-110000.txt   exhaustive
Discovery/DNS/namelist.txt                        legacy DNS list
Discovery/DNS/bitquark-subdomains-top100000.txt   frequency-sorted real-world
Discovery/DNS/fierce-hostlist.txt                 names Fierce uses

VHost Fuzzing

This is where the DNS record doesn’t need to exist — you set the Host: header explicitly:

ffuf -w /opt/useful/seclists/Discovery/DNS/subdomains-top1million-5000.txt:FUZZ \
     -u http://target.htb/ \
     -H 'Host: FUZZ.target.htb'

You'll get 200 OK for everything

The server returns the default site’s homepage for any unknown Host: value. Every wordlist entry looks like a hit. Filter by response size, words, or lines against the default response.

Baseline the default response

Send one request with a clearly nonsense Host value and record the response size:

curl -s -H 'Host: aaaaaaaa.target.htb' http://target.htb/ | wc -c
# 900

Then filter that size out:

ffuf -w /opt/useful/seclists/Discovery/DNS/subdomains-top1million-5000.txt:FUZZ \
     -u http://target.htb/ \
     -H 'Host: FUZZ.target.htb' \
     -fs 900

Anything with a different size is a vhost serving different content.

When Each Wins

  • Subdomain fuzz — External-facing, DNS-published services. Use on bug bounty scope, public-facing engagements, cloud assets.
  • VHost fuzz — Internal services, dev/staging on the same IP, HTB-style boxes. Also use whenever you have a single IP with no clear DNS answers to pull from.

In practice, run subdomain fuzz first (fast, cheap, and tells you what’s public). Then run vhost fuzz on every unique IP the subdomains resolved to — you often discover a dev or admin vhost sharing the IP of a production site.

Adding Discovered VHosts to /etc/hosts

Once you’ve found admin.target.htb via vhost fuzz:

echo '10.10.10.10 admin.target.htb' | sudo tee -a /etc/hosts

Now your browser and all subsequent ffuf runs can target the vhost directly without manual Host-header surgery.

Catching HTTPS Vhosts (SNI)

On TLS, the client sends the hostname in the SNI field as well as the Host: header. For HTTPS vhost fuzzing, ffuf handles both automatically when you use -u https://... with an -H 'Host: FUZZ...' — but some servers key off SNI only. If vhost results look wrong, retest with direct hostnames on the URL (via /etc/hosts) rather than Host-header override.

Filter Tuning for VHost Scans

Default response size isn’t always a clean filter — the application might inject the Host value into the page, changing the size per request. In that case:

# filter by word count instead
ffuf ... -fw 423
 
# or by lines
ffuf ... -fl 56
 
# or by regex on body content
ffuf ... -fr 'Welcome to the default site'

Use multiple filters together

-fs 900 -fw 423 is stricter than either alone. If one filter has edge cases, combining filters narrows results to actual anomalies.

Real Example

FirstHunter@htb[/htb]$ ffuf -w /opt/useful/seclists/Discovery/DNS/subdomains-top1million-5000.txt:FUZZ \
    -u http://academy.htb:PORT/ -H 'Host: FUZZ.academy.htb' -fs 900

________________________________________________
 :: Method           : GET
 :: URL              : http://academy.htb:PORT/
 :: Header           : Host: FUZZ.academy.htb
 :: Filter           : Response size: 900
________________________________________________

admin                   [Status: 200, Size: 1256, Words: 510, Lines: 72]

One hit. admin.academy.htb is a vhost the server serves but DNS doesn’t publish. Add it to /etc/hosts and continue with directory fuzzing against the new vhost.