← See all resources
Subdomain Takeover Attack
Web Attacks • Attack Types

Subdomain Takeover Attack

How misconfigured subdomains can be hijacked by attackers.

Tags

Subdomain TakeoverDNSWeb Security
Download infographic

File: SecPro-ataque-subdomain-takeover.png

What is a subdomain takeover?

A subdomain takeover happens when a subdomain still points via DNS to an external service that no longer exists. The organization decommissioned a site on a hosting provider, CDN or SaaS platform but forgot to delete the CNAME record. That record is left dangling, and anyone who claims that name at the provider receives the subdomain's traffic. There is no intrusion: a gap that was left open simply gets occupied.

Why is it worse than it looks?

Because the attacker controls not just any domain but one belonging to the organization, with all its credibility. They can host entirely believable phishing under the corporate domain, obtain a valid TLS certificate for it, receive cookies scoped to the parent domain's subdomains and, depending on security policy configuration, bypass origin restrictions. A forgotten subdomain becomes an attack platform backed by the company's reputation.

How to detect and prevent it?

Prevention is hygiene: when decommissioning a service, delete the DNS record first and the service second, in that order. Detection means inventorying DNS records periodically and checking which point at destinations returning unclaimed-resource errors. Public certificate logs (Certificate Transparency) help surface forgotten subdomains that do not even appear in the internal inventory.

More from Web Attacks • Attack Types

Explore more infographics

View full catalog

Need help with your cybersecurity? 💬