Unique OAuth Misconfiguration That Could Lead to Account Takeover
The application restricted changing the email address for Google OAuth accounts only in the frontend, while the backend accepted email changes for any account. An attacker with temporary access to an OAuth session could rebind the account to an attacker-controlled email, potentially leading to account takeover.
medium.com
Published on medium.com
I am Ankit Rathva and i am a student of MCA 2nd year, I am an ethical hacker and security researcher with a passion for finding logic, authorization, and data-integrity flaws in web applications. As a bug bounty hunter and red teamer, he combines hands-on testing, forensic analysis, and careful disclosure to help…
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 with temporary access to an OAuth session could permanently rebind the account to an attacker-controlled email, potentially leading to account takeover and breaking authentication trust.
What the attacker needed
Temporary access to an OAuth session; ability to intercept HTTP requests; OTP verification completed
How it was found
- Create a normal email/password account and change its email while intercepting the request to see the format.
- Log in with the Google OAuth account and intercept a profile update request.
- Replace the request body with old and new email parameters, using an attacker-controlled new email.
- Forward the request and complete OTP verification.
- Observe that the OAuth account's email changed while it remained linked to Google.
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 Google, the app trusts Google to confirm who you are. The app tried to stop Google users from changing their email address, but only hid the button on the website; the server still accepted the change. So someone who briefly got into a Google-linked account could swap the email to one they control and keep access.
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.