Exposed Credentials in a Public Repository Leading to Administrat
Login credentials for a CSIRT portal were left in a public repository, and the account they belonged to had full editor-level administrative access. An attacker who found the credentials could log in without MFA or IP restrictions and create users, change roles, edit configurations and upload files.
Published on medium.com
Hello everyone, My name is Fathi Akhdan Dzaky. I’m a high school student (Grade 11) and a cybersecurity enthusiast passionate about security research and responsible disclosure.
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 credentials were committed to a public repository and the matching account was over-privileged, with no MFA or IP restriction to limit the damage.
Impact
An attacker could take over the system, manipulate data, upload malicious files such as webshells, disrupt services and deface the site, because no MFA, IP restriction or login alert stood in the way.
What the attacker needed
Public repository with a .env file; no MFA on the account; no IP restriction on login
The fix
The credentials should be removed from the public repository and rotated, and the account should be given only the access it needs plus MFA and IP restrictions.
How it was found
- Search public repositories for exposed .env configuration files.
- Find credentials that appear to belong to the CSIRT internal systems.
- Try logging in to the CSIRT Portal with those credentials.
- Confirm the login succeeds and the account has editor-level administrative access.
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 .env file is a small settings file that often holds passwords and API keys, and it should never be uploaded to a public code repository. Here one was public, so anyone could read the password inside and use it to log in to an internal admin portal. The account also had far more power than it needed, so one leaked password gave control of the whole system.
What is Leaked secrets?
Keys, tokens or passwords left in public code, apps, logs or responses, that grant real access.