Account Takeover - Smoking with ‘null’
The login endpoint that accepted an emailed token also accepted a JSON null value in place of the token, so any request with a null token was treated as a successful login. An attacker could log in as any account, including the company's support account, without knowing the token.
Published on shahjerry33.medium.com
Hello everyone I want to share one of my recent findings for which I was paid $50 because it was the highest amount they were offering. I found an interesting account takeover using JSON null value.
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
Impact
An attacker could take over any account, including the company's support account, without possessing a valid token.
What the attacker needed
A registered email address; ability to intercept the login request
The fix
The login endpoint should reject null or missing token values and only accept a token that exactly matches the one issued to that account.
How it was found
- Register a normal account on the signup page.
- Choose the 'Login with Token' option and capture the login request.
- Send the request to a repeater tool and set the token parameter value to null.
- Observe that the login succeeds without a valid token.
- Repeat against the support email address, which was already registered, to take over that 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.
Many websites send you a one-time code by email to log in. This site checked the code badly: if you sent the word null (a special 'nothing' value in JSON, a common data format) instead of a real code, the site accepted it as correct. That meant anyone could log in as anyone else, including the company's own support account.
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.