Stored 'undefined' Cross-site Scripting
A stored cross-site scripting flaw existed in the profile 'BIO' field, where a crafted SVG payload did not trigger immediately but did after the user edited and saved other profile fields, displaying the word 'undefined'. An attacker could use this to run script in a victim's browser when the profile is saved again.
Originally disclosed on HackerOne
- Disclosed after 4 days
Hello KhanAcademy Security Team,
I'm rootbakar, I found an XSS bug on 'BIO' in the profile, I used payload XSS "/><svg/on<script>load=prompt(document.domain);>"/><svg/on<script>load= prompt (document.cookie);> after I save it appears there is no trigger from the XSS, but when I try to change one of the values in the profile form and when I save it again an XSS trigger appears but with the words 'undefined'. Every time I want to change both 'REAL NAME' and 'LOCATION' and when I press the save button again and after a few seconds an XSS trigger appears with the words 'undefined'
PoC This is Video Link https://youtu.be/WGeaclSo_5A (Not Public Video)
Best Regards,
RootBakar
Impact
Displayed 'undefined' XSS after user repeated click SAVE button
Attachments



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 profile bio field did not properly sanitise or encode user-supplied HTML/SVG before storing and re-rendering it.
Impact
Script runs in the user's browser when they save their profile again, showing an 'undefined' prompt.
What the attacker needed
A user account; victim edits and saves profile
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.
XSS is when a site runs attacker-supplied script. Here the profile biography field accepted a malicious SVG element, and the site later ran it when the profile was saved again.
What is XSS?
Script an attacker supplies runs in another user's browser, on the target's origin, with that user's session.