Session Hijacking attack (Different Scenario)
A session cookie from an active logged-in session could be replayed by an unauthenticated user to access the victim's account, provided the victim's session was still active. The attacker also needed to replay the X-XHR-Referer value from the original request.
Originally disclosed on HackerOne
- Disclosed after 8 days
Hey I was able to replay a cookie of a current active session and hijack that by replaying the cookie. Now this is different from any conventional vanilla session hijacking because it works even when the user is not logged in. But the condition is that the victim's session must be active at the time of replay
-
Capture a cookie from one account using tamper data just note that you learn the Referer and X-XHR-Referer values
-
Open a new windows click on the same link without logging in. For example in the victim account i clicked on "bugs" so here in order to replay the cookie i have to click on bugs again. Replay the X-XHR value with the other one. Replay the session cookie and you are in. You hacked the account.
I hope this impresses you because i have been trying hard to get you guys impressed. Although i have managed to do with the other ones :) Waiting for your reply
Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.
How it worked
Root cause
Likely the server accepted a session cookie without binding it to the original client or requiring a fresh login, and also relied on a client-supplied X-XHR-Referer header for validation.
Impact
An attacker could hijack an active session and access the victim's account, but only while the victim's session remained active.
What the attacker needed
Victim's session is active; attacker can capture the session cookie; attacker knows the X-XHR-Referer value
How it was found
- Capture a session cookie from one account using a tampering tool, noting the Referer and X-XHR-Referer values.
- Open a new window and click the same link without logging in.
- Replay the X-XHR-Referer value from the captured request.
- Replay the session cookie to gain access to the 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 report has not been written yet. The Original tab links to the source.
When you log in to a website, the site gives your browser a small piece of data called a session cookie so it can remember who you are. If someone else can copy that cookie and send it to the site, the site may treat them as you. This report says that happened, but only while the real user was still logged in.
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.