How I Found a Critical Account Takeover via Firebase API Misconfi
An exposed Firebase API key allowed unauthenticated account creation using any email address, and the same key could be used to query account details, trigger verification and password-reset emails, and delete accounts if the attacker held the victim's idToken. The author claims this could lead to account takeover and disruption, though several steps required a valid token or only caused email spam.
The original lives on medium.com
We do not hold its text, 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 Firebase Authentication project was configured to allow unauthenticated sign-up and other identity operations with only the public API key, without requiring email ownership verification or proper authorisation checks.
Impact
An attacker could create accounts with arbitrary email addresses, retrieve account details when holding a valid idToken, spam verification and reset emails, and delete an account only if the victim's idToken was known; the report does not show a full takeover without that token.
What the attacker needed
Exposed Firebase API key; valid idToken for some steps; victim's email address known; victim's idToken known for deletion
The fix
The report recommends requiring email verification before account creation, enforcing stronger authentication and authorisation checks on sensitive endpoints, validating that idTokens belong to the authenticated user, and adding rate limiting and monitoring; it does not state that the issue was…
How it was found
- Capture traffic from the target website with Burp Suite and use JS Miner to find a JavaScript file containing an exposed Firebase API key.
- Refer to the Firebase API documentation and craft cURL commands to interact with the backend using the exposed key.
- Create an account using a victim's email address through the Firebase sign-up endpoint.
- Obtain a valid idToken by creating an account, then query the victim's account information by email.
- Trigger repeated email verification requests for a victim's email address.
- Initiate multiple password reset requests for a known email address, and if the victim's idToken is known, delete the victim's account.
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 Firebase API key is a public identifier that a website's code uses to talk to Google's Firebase login service. If the service is set up loosely, anyone who finds that key can pretend to be the app and create accounts or ask for password resets. This report shows that the key was found in a JavaScript file and that the service accepted requests without checking who was making them.
What is Account takeover?
Getting into someone else's account through a flaw in sign-in, password reset, second factor, single sign-on or session handling.