Account Takeover via Hidden Parameters in BBP
A hidden parameter on the login page accepted a redirect URL and, after login, sent the authentication token to that URL. An attacker could craft a login link that delivered the victim's token to their own server, allowing account takeover.
How you all doing. In this article, Iām going to talk about a Open redirect bug I discovered in an self hosted bug bounty program which i m going to represent as redacted that allowed me to get paid 200$ in bounty.
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 login page's redirect parameter was not restricted to trusted destinations and the authentication token was passed in the redirect URL.
Impact
An attacker could steal a victim's authentication token and take over their account.
What the attacker needed
Victim clicks a crafted login link; attacker has a server to receive the token
The fix
The redirect parameter should be restricted to trusted destinations and the token should not be sent in a redirect URL.
How it was found
- Find the register page using search engine dorks and create an account.
- Run parameter discovery tools on the login page and find the r_url parameter.
- Try a redirect to an external collaborator server, which is rejected.
- Bypass the check by using a protocol-relative URL starting with double slash.
- Log in and observe the collaborator server receiving a request containing the token.
- Use the received token in a cookie editor to access the dashboard.
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, the site gives your browser a secret token that proves who you are. The login page had a hidden setting that told it where to send you afterwards, and it sent that secret token along with the redirect. An attacker could make the redirect point to their own server, so the victim's token would arrive there and the attacker could use it to log in as the victim.
What is Open redirect?
A trusted site forwards users to any address an attacker picks; rarely paid alone, often the missing link in a chain.