How Blind XSS Leading to Sensitive Token Disclosure
A contact form on the target site was vulnerable to blind cross-site scripting, so a payload submitted through it executed in an internal staff member's browser. The payload captured the contents of that browser's local storage, which held a JWT token, a Firebase token, internal endpoints and a user ID.
medium.com
Published on medium.com
I want to share how I discovered a Blind XSS in Contact Form,I came across a target let’s call it example.com , while I discovering the main web I saw a button (if you need more information contact us) So I press on it and give me this :
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 contact form stored the submitted message without sanitising it and later rendered it in an internal staff-facing page, allowing script execution in that context.
Impact
An attacker could execute script in an internal staff member's browser and steal tokens and internal endpoint details, which could lead to further access; the text does not show what was done with the tokens.
What the attacker needed
A contact form that reaches internal staff; victim (staff) opens the message; attacker uses an external callback service
How it was found
- Find the contact form on the target site.
- Take a blind XSS payload from a callback service and submit it in all input fields.
- Wait for the callback service to report that the payload executed.
- Check the captured data and find tokens and endpoints in local storage.
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 contact form sends whatever you type to staff inside the company. If the form does not clean up what you type, a small script can run inside the staff member's browser when they read your message. That script can read data the staff member's browser has stored, such as login tokens, and send it back to the attacker.
What is XSS?
Script an attacker supplies runs in another user's browser, on the target's origin, with that user's session.