Skip to content
Subdomain takeover Write-up Beginner

Subdomain Take Over Worth 100£

A subdomain pointed to a GitHub Pages site that was no longer in use, creating a potential subdomain takeover. The attacker could not actually claim the subdomain, but the company still paid a reward and fixed the dangling DNS record.

c0d3x27 Follow

Published on web.archive.org

Bounty$100 View original

{{media:0}}

c0d3x27, on web.archive.org

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.

Written with AI from the full original report and checked against it passage by passage; anything it could not back up was removed or toned down. The original is the record. 6 min read.

Context

This is a short account of a subdomain takeover report that ended in a payout of £100 even though the subdomain was never actually taken over. The target is given as thesenuts.org (a fake name used in the write-up), and the website in question was linked to github.com. The author describes it as "not the typical STO you will read about on the internet": the outcome depended as much on luck and on the people handling the report as on the technical finding itself.

The write-up opens with a general definition of account takeover, which is the broader category the author places the finding in:

Account takeover is a form of identity theft and fraud, where a malicious third party successfully gains access to a user's account credentials.

Image for post
Photo by 金 运 on Unsplash From the original on web.archive.org

Photo by 金 运 on Unsplash

Setup

The author states no tooling, no versions and no specific reconnaissance method. What the report does establish as preconditions:

  1. A page under the target's domain was returning an error, which the author read as a sign that the page was no longer in use.
  2. The website was linked to github.com.
  3. The DNS record for the page had not been removed after the organisation stopped using it.

No accounts, roles or credentials are described beyond the author's own bug bounty activity and, later, the intention to create a github.com account.

Finding it

The author is candid that subdomain takeovers were the class of bug they avoided most when starting out, precisely because success depends on a degree of luck. The finding here came from noticing that a page was serving an error, which the author read as a possible account takeover. In the author's words, thesenuts.io was not being used by thesenuts.org, and the DNS for these pages had not been deleted.

Image for post
Image for post From the original on web.archive.org

The reasoning is the standard dangling-DNS pattern: when an organisation stops using a hosted page, the first thing most of them do is delete the DNS record, which is good practice and avoids this kind of attack. In this case they did not.

Image for post
Image for post From the original on web.archive.org

Exploitation

Step 1: Report without taking over

After many attempts, at 4 am, the author reported the issue without having taken the subdomain over. The report was submitted on Mar 29, 2020 at 4:30 am. The author notes that this omission later came back to haunt them.

Step 2: The triager's request

After a month and some days of waiting, a response arrived. The report was opened by the triager on Mar 30, 2020 and sent to the Thesenuts.org team. The triager then asked the author to go ahead and actually take over the subdomain. The author describes this request as coming "for some unknown and weird reason".

Step 3: The attempted takeover

The stated plan was to create a github.com account and link thesenuts.io to it. The author states plainly that this was not possible, and points to the later explanation for why. No request, response, header or payload from this attempt is reproduced in the report.

Step 4: Waiting instead of escalating

Fifteen more days passed since the triager's request, which the author ignored for what they call obvious reasons: they simply could not do what was asked. After further attempts and some social engineering, the author decided to wait for the company's verdict rather than push further. On April 20, 2020 the triager said the report had been forwarded 21 days earlier to the Thesenuts.org team for review.

Step 5: The company's answer

On May 6, 2020 a member of the Thesenuts.org team responded. They explained that they had been busy with the pandemic, which is why reports for the organisation had been delayed.

Image for post
Image for post From the original on web.archive.org

The same person then explained in explicit detail what the problem was with thesenuts.github.io and why the author could not claim it.

Image for post
Image for post From the original on web.archive.org

Step 6: The payout

The author calls the reward the best part of the story: the person was generous enough to pay for the report.

Image for post
Image for post From the original on web.archive.org

The conclusion drawn from the exchange is that the account was not vulnerable to subdomain takeover, but that DNS cleanup was still required.

Root cause

The report does not describe the underlying configuration in enough detail to pin down a code-level cause. What it does establish is that a DNS record for a page the organisation no longer used was left in place, pointing at a GitHub-hosted service, and that the page returned an error. The author's reading is that the missing DNS cleanup was the problem, and the company explained why the subdomain could not be claimed. The exact mechanism is not given in the report.

Impact

The author frames the finding as a possible account takeover when first reported, but the final verdict from the company was that the account was not vulnerable to subdomain takeover. The residual issue was the missing DNS cleanup. The report does not describe what an attacker could have done with the dangling record, and the author's own conclusion is that this was "more a situation where I got lucky than a vulnerability itself".

Fix

The author's stated position is that deleting DNS records for pages that are no longer used is the practice that prevents this class of attack, and that in this case it had not been done. The author's conclusion was that the account was not vulnerable but DNS cleanup was still required.

Variants to test

The report gives no payloads or tooling, so the following are general directions rather than steps taken in this case:

  1. Dangling records to third-party hosting. Look for DNS entries pointing at services the organisation no longer uses. A positive result is a hostname that resolves to a provider error page while the record still exists.
  2. Records pointing at GitHub-hosted content. The report specifically involves a page linked to github.com. A positive result would be a hostname whose backing GitHub resource is unclaimed and can be registered by you; in this case that step was not possible.
  3. Error pages on unused subdomains. The author's entry point was an error page. A positive result is a subdomain serving a provider-specific "not found" or unconfigured response rather than content from the organisation.
  4. DNS hygiene checks after decommissioning. Where an organisation has retired a service, check whether the corresponding records were removed. A positive result is a record that outlives the service it pointed to.

Timeline

Date Event
Mar 29, 2020 4:30 am Issue reported
Mar 30, 2020 Report opened by triager and sent to Thesenuts.org
April 20, 2020 Triager states the report was forwarded 21 days earlier to the Thesenuts.org team
May 6, 2020 Thesenuts.org team member responds; same day the author is paid and the issue is fixed

Conclusion

The author's takeaway is about process as much as technique. Having ignored the triager's request to exploit, they were lucky the report was not closed outright, and luckier still to reach the right person at the company, who paid for the attempt. The advice offered is to wait for the company's own decision rather than treat a triager's instruction as final, on the grounds that companies often act differently from what a triager tells you, and that getting a report in front of the company raises the chances of a reward considerably. The author puts that figure at "at least 90%".

Written with AI from the full original report and checked against it passage by passage; anything it could not back up was removed or toned down. The original is the record. 7 min read.

What happened, in plain words

This is the story of a security report that earned the author £100 even though the problem was never actually exploited. The target is called thesenuts.org in the write-up, which the author says is a fake name. A page under that domain was linked to github.com, and the author suspected it could be taken over by someone else. In the end, the account was not actually vulnerable, but the author was still paid for the report.

The author is honest that luck played a large part. They describe it as "not the typical STO you will read about on the internet", and their own conclusion is that it was "more a situation where I got lucky than a vulnerability itself". So as you read, keep in mind that the lesson here is as much about how to behave during a report as about the technical finding.

The write-up opens with a definition of the broader category the author places the finding in:

Account takeover is a form of identity theft and fraud, where a malicious third party successfully gains access to a user's account credentials.

In plain terms: account takeover means somebody else gets into an account that is not theirs, usually by obtaining the login details. The author uses this as the umbrella term, even though what they actually found was a related but different problem, a subdomain takeover.

Image for post
Photo by 金 运 on Unsplash From the original on web.archive.org

Photo by 金 运 on Unsplash

Subdomain Take Over (STO)

Before the story, a quick explanation of the vulnerability class, because everything that follows depends on it.

A domain is the name people type to reach a website, like example.org. A subdomain is a name that sits in front of it, like shop.example.org or blog.example.org. Each subdomain is really just an entry in a directory called DNS (the Domain Name System), which tells browsers which server to contact when someone types that name. Think of DNS as a phone book: the name is the person, and the entry is their phone number.

Organisations often do not run every subdomain on their own machines. Instead they point the DNS entry at a service run by somebody else, for example a hosting provider that serves a blog or a documentation site. The provider recognises the incoming name and serves the right content.

A subdomain takeover happens when the organisation stops using that outside service but forgets to remove the DNS entry. The name still points at the provider, but nobody at the provider is claiming it any more. If an attacker can register that same name with the provider, the provider will start serving the attacker's content under the organisation's subdomain. Visitors see the organisation's name in the address bar, which makes phishing and other tricks far more convincing.

The everyday comparison: you cancel your membership at a gym but leave your locker key with the reception desk. Anyone who asks for that locker can now use it, and the locker still has your name on it.

The author admits that subdomain takeovers were the kind of bug they avoided most when starting out, precisely because success depends on a degree of luck. This particular case, they say, was not the typical one.

Storytelling, Thesenuts.org, and The outcome

After a month and some days of waiting, a response finally arrived on the report. The report was about a possible subdomain takeover on thesenuts.org, and the website involved was linked to github.com. GitHub, if you have not met it, is a website where people store and share code and project pages; it can also host simple websites for its users.

I cant remember the exact details at the moment being, but I will try to explain my best what really happened with this report.

Image for post
Image for post From the original on web.archive.org

That note matters: the author is reconstructing events from memory, so some fine detail is missing.

How-To

To report a subdomain takeover, the usual expectation is that you demonstrate it: you actually take the subdomain over, so the company can see the problem is real. The author did not do that. After many attempts, at 4 am, they submitted the report without having taken the subdomain over. Reading the reply, they say, this omission came back to haunt them.

After the report was forwarded to the Thesenuts team, the triager asked the author to go ahead and actually take over the subdomain. A triager is the person at the bug bounty platform who reads incoming reports first, checks they make sense, and passes them on to the company. The author calls this request strange and unexplained.

The stated plan was to create a github.com account and link thesenuts.io to it. The author states plainly that this was not possible, and points to the later explanation for why. No request, response, header or payload from this attempt appears in the report.

Why I Reported Thesenuts.org 1.0

The entry point was simple: the page was giving an error. The author read that error as a sign of a possible account takeover. Thesenuts.io was not being used by thesenuts.org.

The reasoning is the standard dangling-DNS pattern. When an organisation stops using a hosted page, the first thing most of them do is delete the DNS record, which is good practice and avoids this kind of attack. In this case they did not.

Image for post
Image for post From the original on web.archive.org

Thesenuts.org 2.0

Fifteen more days passed since the triager's request, which the author ignored for what they call obvious reasons: they simply could not do what was asked. After further attempts and some social engineering, they decided to wait for the company's verdict rather than push further. Social engineering here means trying to reach the right person through persuasion and communication rather than through technical means.

On April 20, 2020 the triager said the report had been forwarded 21 days earlier to the Thesenuts.org team for review. Finally, after two weeks, someone from Thesenuts.org got back to the author. They explained that they had been busy with the pandemic, which is why reports for the organisation had been delayed.

Image for post
Image for post From the original on web.archive.org

The Outcome

The same person then explained in explicit detail what the problem was with thesenuts.github.io and why the author could not claim it.

Image for post
Image for post From the original on web.archive.org

The Reward

The author calls the reward the best part of the story: the person was generous enough to pay for the report.

Image for post
Image for post From the original on web.archive.org

The conclusion drawn from the exchange is that the account was not vulnerable to subdomain takeover, but that DNS cleanup was still required.

Timeline

Date Event
Mar 29, 2020 4:30 am Issue reported
Mar 30, 2020 Report opened by triager and sent to Thesenuts.org
April 20, 2020 Triager states the report was forwarded 21 days earlier to the Thesenuts.org team
May 6, 2020 Thesenuts.org team member responds; same day the author is paid and the issue is fixed

Conclusion

The author's takeaway is about process as much as technique. Having ignored the triager's request to exploit, they were lucky the report was not closed outright, and luckier still to reach the right person at the company, who paid for the attempt.

The advice offered is to wait for the company's own decision rather than treat a triager's instruction as final, on the grounds that companies often act differently from what a triager tells you. If you are lucky enough to get the triagers to send your report to the company, the author puts your chances of a reward at "at least 90%".

Was it worth the wait? In the author's words: "Heck Yes."

Glossary

  • Account takeover: when someone else gains access to an account that is not theirs, usually by obtaining the login details.
  • Bug bounty: a programme where organisations pay people for reporting security problems to them.
  • DNS: the Domain Name System, the directory that maps names like example.org to the servers that answer for them.
  • DNS record: a single entry in that directory, for example the one that says which server a subdomain points at.
  • Dangling DNS: a DNS record that still points at an outside service the organisation no longer uses.
  • Domain: the main name of a website, like example.org.
  • GitHub: a website for storing and sharing code and project pages, which can also host simple websites.
  • Pandemic: the public health situation the company cited as the reason reports were delayed.
  • Payload: the specific piece of input or request used to demonstrate a vulnerability.
  • Social engineering: persuading people to do something or give information through communication rather than technical means.
  • Subdomain: a name that sits in front of a domain, like shop.example.org.
  • Subdomain takeover (STO): claiming an outside service that an organisation's subdomain still points at, so that your content is served under their name.
  • Triager: the person at a bug bounty platform who first reads a report, checks it, and forwards it to the company.

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.