Skip to content
XXE Write-up Advanced

can I speak to your manager? hacking root EPP servers to take control of zones

The CoCCA registry software's built-in EPP server parsed XML with external entities enabled, so an unauthenticated attacker could read files from the server. A second pre-authentication servlet allowed path traversal to download any file, and together these exposed SSH keys and database backups, letting the researchers control the DNS zones of many ccTLDs.

Sam Curry Follow

Published on hackcompute.com

Over the last few decades, the internet has been built upon specifications and protocols that often get forgotten about over time. Our research has often been focused on high impact targets (such as Web Hackers vs.

Sam Curry (@samwcyo), Brett Buerhaus (@bbuerhaus), Rhys Elsmore (@rhyselsmore), Shubham Shah (@infosec_au), on hackcompute.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

The XML parser used by the EPP server was created without disabling external entities or DTDs, and a separate servlet concatenated user input into a file path without validation.

Impact

An attacker could read any file on the server, including SSH private keys and central backup credentials, and thereby control the nameservers for every domain in the affected ccTLDs and transfer domains they did not own.

What the attacker needed

Network access to EPP port 700; no authentication needed for the XXE; no account needed for the file disclosure

The fix

The vendor's latest version of the software contains patches for all the vulnerabilities, and the affected EPP servers were patched.

How it was found

  1. Modify an EPP client and craft an XML message containing an external entity definition.
  2. Collect a list of hosts with port 700 open and send the crafted message to each EPP server.
  3. Observe the file contents reflected in the error response, or receive an out-of-band callback.
  4. Request the cities servlet with a traversal sequence in the country parameter to download arbitrary files.
  5. Use the retrieved SSH key and backup credentials to confirm access to registry systems.

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 registry is the organisation that runs a whole top-level domain such as .ai, and registrars (the shops where you buy a domain) talk to it through a protocol called EPP, which sends XML messages. XML has a feature called external entities that lets a document pull in content from elsewhere, and if the parser is not told to refuse this, an attacker can make it read local files. Here that flaw, plus a second bug that let anyone fetch files by manipulating a path, gave access to private keys and backups for entire country domains.

What is XXE?

An XML parser resolves entities the attacker defines, reading local files or making the server send requests.

Similar reports

View all

Same bug class and techniques, clearest first.

XML external entities (XXE)

The lesson behind this report.

An XML parser resolves entities the attacker defines, reading local files or making the server send requests.