Discovering a Session Persistence Vulnerability That Led to a $$ Bounty
A session persistence flaw in an OAuth authorisation process allowed a subdomain to retain access to a user's account even after the user revoked the subdomain's access and changed their password. An attacker with access to the subdomain could continue to access the user's account despite these security actions.
In the world of cybersecurity, sometimes the most dangerous vulnerabilities are hidden in plain sight. It all began one evening as I was working on routine bug bounty testing.
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 revocation and password change did not properly invalidate existing sessions or tokens for the subdomain.
Impact
An attacker with access to the subdomain could maintain unauthorised access to a user's account even after the user revokes access and changes their password.
What the attacker needed
Victim has an account on Domain A; victim authorises Subdomain B via OAuth; attacker has access to Subdomain B
The fix
The company acted quickly to fix the vulnerability, but the text does not specify the exact fix.
How it was found
- Log in to Domain A and authorise access to Subdomain B via OAuth.
- Verify that Subdomain B has access to your account.
- Revoke Subdomain B's access from Domain A's OAuth settings.
- Change your password on Domain A.
- Return to Subdomain B and observe that the session remains active.
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.
OAuth lets you use one account to log in to other services. Normally, if you revoke that access, the other service should lose access immediately. Here, the subdomain kept its access even after revocation and a password change, so someone could still get into your account.
What is OAuth / SSO?
Mistakes in OAuth, OpenID Connect, SAML or token handling that leak codes and tokens or link an attacker's identity to a victim's account.