Unclaimed Github Repository Takeover on https://www.data.gov/labs
Two links on the data.gov labs page pointed to a GitHub Pages site whose repository name was unclaimed, so anyone could register the matching GitHub account and publish content there. An attacker could then serve malicious content to visitors who followed those links.
Originally disclosed on HackerOne
- Triaged in 2 hours
- Fixed in 9 days
- Paid in 2 days
- Disclosed after 4 months
Hello Security Team,
I found a Vulnerability in your website where in one of your domain https://www.data.gov/labs there was Description about Simple API in which two links were pointing to https://simple-api.github.io/api-offices/ but after visiting this URL i got an 404 error where it shown like page not found.
Steps were used to claim these repository :-
- this domain was available to claim.
- registered for new github account
- used username "simple-api"
- created a master-branch of repository with "api-offices"
- created a simple index.html file.
Impact
There is impact where when victim visitor's visit the website they see "Simple API" section for information if they click on below options
- Source Code and Documentation
- Remote Hosted Tool
they will get into attackers repository, and attacker can upload any malicious content on it which can harm your organisation.
Attachments




Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.
How it worked
Root cause
Likely the organisation stopped maintaining the GitHub account or repository that its public links pointed to, without updating or removing those links.
Impact
Visitors following the two links from the data.gov labs page could be sent to attacker-controlled content, which could be used to harm the organisation or its users.
What the attacker needed
The linked GitHub username is unclaimed; a free GitHub account; victim clicks the affected links
The fix
The links should be updated or the repository reclaimed to prevent takeover.
How it was found
- Notice that the linked GitHub Pages site returned a not-found error.
- Check that the matching GitHub username was available to register.
- Register a new GitHub account with that username.
- Create a repository with the expected name and a master branch.
- Add a simple index page so the link now resolves to attacker-controlled content.
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 report has not been written yet. The Original tab links to the source.
A website can link to pages hosted elsewhere, such as on GitHub. If the account or repository behind that link is no longer owned by the organisation, someone else can register the same name and put their own content there. Visitors who trust the original site would then be sent to the attacker's page.
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.