How I Earned a 4-Digit Bounty: Complete Account Takeover via Insecure Session Cookie
The session cookie lacked the Secure flag, so it could be sent over unencrypted HTTP and intercepted by a man-in-the-middle. An attacker who captured the cookie could authenticate as the victim and access private documents and workspace data.
Published on adityasunny06.medium.com
The original lives on adityasunny06.medium.com
We do not hold its text, 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 session cookie was set without the Secure attribute, allowing it to be transmitted over plain HTTP.
Impact
An attacker who intercepts the cookie could take over the account, read private documents and workspace details, and terminate the victim's session.
What the attacker needed
Victim on unencrypted HTTP connection; attacker on same network; no account needed for attacker
The fix
The cookie was fixed by adding the Secure and SameSite=Lax attributes.
How it was found
- Create a test account and explore the application.
- Configure Burp Suite to intercept HTTP traffic.
- Capture the login response and observe the Set-Cookie header.
- Extract the session cookie from the browser.
- Use the cookie to authenticate to the API and access private documents.
- Test session termination by sending a DELETE request with the cookie.
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.
A session cookie is a small piece of data your browser sends to a website to prove you are logged in. The Secure flag tells the browser to send that cookie only over encrypted HTTPS connections. Without it, someone on the same network could read the cookie and use it to log in as you.
What is Info disclosure?
Data the application should keep private (personal data, internal details, other users' records) reaches someone it should not.