Subdomain takeover — dangling CNAME

What it is

Your domain’s DNS contains a CNAME record pointing to an abandoned cloud service. A typical scenario:

  1. Years ago, someone created blog.example.cz with a CNAME to example-blog.herokuapp.com.
  2. The Heroku app was deleted long ago, but nobody removed the CNAME from DNS.
  3. An attacker registers on Heroku, creates an app named example-blog, and takes over your subdomain.

Why it’s a problem

The attacker is now serving content under your domain name — and both users and search engines trust them as they trust you. Specifically, they can:

This isn’t theoretical. Heroku, AWS S3, GitHub Pages, Azure CDN, Shopify, and other services all allow “register-and-take-over” unless the specific service is secured with pinning (many don’t do this).

How to fix it

Step 1 — confirm the problem is real

You know the specific subdomain from the report. Open it in your browser:

Step 2 — decide

Step 3 — regular hygiene

Subdomain takeover happens because you forget to clean up DNS. Put in place:

Watch out for inherited old marketing subdomains

landing.example.cz from a five-year-old campaign, hosted on a cancelled Unbounce. old-blog.example.cz from a migration to Medium. These are the classic targets.

References