Skip to content
Subdomain takeover Write-up Intermediate

Floating Domains – Taking Over 20K DigitalOcean Domains via a Lax Domain Import System

DigitalOcean's DNS hosting allowed any user to add any domain to their account without verifying ownership, and if the domain's nameservers still pointed to DigitalOcean after deletion, an attacker could re-add it and control its DNS. The author took over about 19,500 domains this way and sinkholed their traffic.

Matthew Bryant Follow

Published on thehackerblog.com

EDIT: DigitalOcean seems to be getting a lot of flak from this post so I’d just like to point out that I feel DigitalOcean’s reaction in this case was entirely justified (they saw an anomaly and they put a stop to it). The only thing I’d wish was done differently would be that the domains were deleted from my account…

Matthew Bryant (@IAmMandatory), on thehackerblog.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 domain import system used shared, non-unique nameservers and did not verify domain ownership, so a deleted domain could be re-added by anyone.

Impact

An attacker could take over thousands of domains and redirect their traffic, though the author only sinkholed the traffic and DigitalOcean later locked the account.

What the attacker needed

A DigitalOcean account; victim domain uses DigitalOcean nameservers; victim deleted domain but kept nameservers

The fix

The text does not state a fix; the author suggests using unique nameservers for each domain import to prevent takeover.

How it was found

  1. Obtain zone files for .com and .net to list all domains using DigitalOcean nameservers.
  2. Query each domain's NS record against DigitalOcean's nameserver to find those returning REFUSED.
  3. Add the vulnerable domains to a DigitalOcean account via their API.
  4. Add a DNS A record for each domain pointing to a sinkhole server to observe traffic.

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.

When you use a company to host your website's address book (DNS), you point your domain to their name servers. DigitalOcean let anyone claim any domain in their system without proving they owned it. If the real owner later removed the domain but forgot to change the name servers, someone else could claim it and redirect the website's visitors.

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 Matthew Bryant

View all

6 more disclosed reports, best first.

More from DigitalOcean

View all

The newest disclosed reports for this program.

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.