Why I Stopped Ignoring Open Redirects (A Zero-Click ATO Story)
The SSO redirect_uri whitelist allowed any AcmeCorp subdomain, and a reflected XSS on a support subdomain let an attacker steal the OAuth authorization code. An attacker could take over a victim's account with a single crafted link.
It was 2 AM, and all I had found after four hours of probing a private SaaS program was a standard Open Redirect on their login endpoint. Usually, open redirects are the participation trophies of bug 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 OAuth redirect_uri whitelist was too broad, accepting any subdomain, and one of those subdomains had an unpatched reflected XSS.
Impact
An attacker could achieve zero-click account takeover of any logged-in user.
What the attacker needed
Victim is logged in or logs in; victim clicks a crafted link; attacker controls a server to receive the code
How it was found
- Craft a link to the legitimate SSO with redirect_uri set to the XSS payload on the help subdomain.
- The victim clicks the link, which appears safe because it points to the SSO domain.
- If the victim is logged in, the SSO generates an OAuth code and redirects to the payload.
- The XSS executes and sends the OAuth code to the attacker's server.
- The attacker exchanges the code for a session token and logs into the victim's 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.
An open redirect lets a website send you to another address after login. Here, the login system trusted any company subdomain, and one of those subdomains had a script injection flaw. Together, an attacker could steal the login code and access the victim's account.
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.