Skip to content
Subdomain takeover Write-up Beginner

Subdomain Takeover: My $450 Win & How You Can Do It Too

A subdomain pointed to a deleted Vercel project via a still-active CNAME record, allowing an attacker to claim the project name and host arbitrary content under the victim's domain. The attacker could then use the subdomain for phishing or impersonation.

ehteshamulhaq198 Follow

Published on ehteshamulhaq198.medium.com

Free Article Link: Click for free!

Ehtesham Ul Haq, on ehteshamulhaq198.medium.com

The full write-up lives on its author's site

It belongs to its author, so we link to it rather than copy it. The other two tabs are our own rewrites, checked against it.

Not written yet. The AI write-up for this write-up has not been written yet. The Original tab links to the source.

How it worked

Root cause

Likely the DNS CNAME record for the subdomain was not removed after the third-party Vercel project was deleted, leaving a dangling pointer that anyone could claim.

Impact

An attacker could host arbitrary content, such as a phishing login page, under the victim's domain, enabling impersonation and other malicious activities.

What the attacker needed

Subdomain with dangling CNAME to third-party; third-party service allows claiming the name; no account needed on victim side

The fix

The issue was fixed after being reported to the security team.

How it was found

  1. Find subdomains of the target using subdomain enumeration tools.
  2. Resolve the subdomains and filter for CNAME records pointing to third-party services like Vercel, Heroku, GitHub, S3, or WordPress.
  3. Scan the subdomains with Nuclei takeover templates to detect unclaimed services.
  4. Manually verify each candidate by visiting the subdomain and checking for error messages indicating the service is unclaimed, and by visiting the CNAME target directly to confirm it is dead.
  5. Claim the unclaimed service (in this case, the Vercel project name) and confirm that the victim subdomain now points to the attacker's content.

Explained by bugbounty.wiki with AI from the original and checked against quotes from it; it can still be wrong. Read the original before relying on a detail.

Not written yet. The AI write-up for this write-up has not been written yet. The Original tab links to the source.

A subdomain is a part of a website address, like blog.example.com. Sometimes a company points a subdomain to an external service (like Vercel) but later deletes the service without removing the DNS record that says 'this subdomain belongs to that service'. An attacker can then sign up for that service using the same name and take control of the subdomain, letting them show their own content on the company's domain.

What is Subdomain takeover?

A company's DNS still points at a cloud service it no longer uses, so anyone can claim it and serve content on the company's domain.

More by ehteshamulhaq198

View all

1 more disclosed report, best first.

Similar reports

View all

Same bug class and techniques, clearest first.

Subdomain takeover

The lesson behind this report.

A company's DNS still points at a cloud service it no longer uses, so anyone can claim it and serve content on the company's domain.