From Subtle IDOR to Full Account Takeover (Including Admin Access
An endpoint used during signup returned another user's username and password when the numeric id parameter was incremented, and setting it to 1 returned the admin's credentials. The attacker could log in as any user, including the administrator, and read private data such as name, email, phone and bank details.
Published on medium.com
So few days back in an weekend I was having coffee and feeling bored , so I thought to hack something for fun (The website was into my bucket list ) and it turned into the discovery of a subtle yet critical security flaw in a website .
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 the endpoint trusted a user-supplied numeric id and returned stored credentials without checking that the requester owned that account.
Impact
An attacker could take over any user account, including the administrator's, and access private information such as name, email, phone number and bank details.
What the attacker needed
Ability to register an account; guessable numeric account id
How it was found
- Register a new account on the website.
- Observe the signup request to an endpoint containing an id parameter.
- Change the id value to the next number and receive another user's credentials.
- Log in with those credentials and view the other user's private information.
- Change the id to 1 and receive the admin's credentials.
- Log in as the admin.
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.
When you sign up, the site calls a link that includes a number identifying your account. The author changed that number by one and the site sent back a different person's login details instead of refusing. Because the number was easy to guess, the same trick reached the administrator account.
What is IDOR?
One user can read or change another user's data, usually by changing an identifier the server trusts without checking who is asking. One of the most paid bug classes on web programs.