Manipulating Responses: A Deep Dive into Exploitation => $650
The login flow relied on the client trusting the server's response to an OTP check, so an attacker could replace an error response with a success response and log in without a valid OTP. This allowed authentication bypass for any account.
medium.com
Published on medium.com
Free Article Link: Click for free!
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 client-side application trusted the server's response status and message to decide whether OTP verification succeeded, instead of the server enforcing the check.
Impact
An attacker could bypass OTP-based authentication and log in as any user, potentially taking over accounts.
What the attacker needed
Ability to intercept and modify responses; a previous successful OTP response
How it was found
- Intercept the login request in Burp Suite and enter an incorrect OTP.
- Observe the error response from the server.
- Replace the error message in the response with the success message from a previous valid OTP attempt.
- Forward the modified response and observe that login succeeds despite the wrong OTP.
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 log in with a one-time code, the server tells the app whether the code was right or wrong. Here, the app apparently believed whatever the server said without checking again, so a person could edit the 'wrong code' reply into a 'right code' reply and get in. This is like changing a 'denied' stamp to 'approved' on a form.
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.