Stored XSS On Statement
The profile statement field on Gratipay did not sanitise Markdown input, allowing an attacker to store a link with a javascript: URL. When a visitor clicked that link, the script ran in their browser and could read cookies.
- Triaged in 14 hours
- Fixed in 9 days
- Paid in 6 months
- Disclosed after 9 days
Hello, I've Found a Stored Cross-Site Scripting (XSS) In Gratipay.com .. This XSS is in The Statement, It Happens Because You're Not Sanitizing This From Markdown Malicious Codes.
##Steps To Reproduce :
- Login To Your Account At Gratipay.com
- Go To Your Profile Page .. And Click Edit Statement
- Enter Any Of These 2 Payload :
[notmalicious](javascript:window.onerror=alert;throw%20document.cookie)<javascript:alert(document.cookie)>
- Click Save
Now You'll See 2 Links (See Links.png) .. Click On Any Of These 2 Links And The XSS Payload Will Be Triggered :)
Also This is Dangerous Because The Profile's Statement is Public .. So Anyone Visit The Attaker's Profile And Click On This Malicious Link, XSS Will Be Triggered On His Browser.
Take a Look At My Profile On Gratipay : https://gratipay.com/~geekpero/.
Please Let Me Know If You Need Any Information.
References About Markdown XSS:
- http://stackoverflow.com/questions/1690601/markdown-and-xss
- https://michelf.ca/blog/2010/markdown-and-xss/
Best Regards, Ebram Marzouk
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 Markdown renderer allowed javascript: URLs in links without sanitising them.
Impact
An attacker could store a malicious link in their public profile statement, and any visitor who clicked it would run the attacker's script, which could read their cookies.
What the attacker needed
A free account; victim clicks a link
How it was found
- Log in to your account on Gratipay.
- Go to your profile page and click Edit Statement.
- Enter a Markdown link or HTML tag that uses a javascript: URL.
- Click Save.
- Click the resulting link to trigger the script.
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.
A stored cross-site scripting (XSS) bug lets an attacker save harmful code on a website, and that code runs in the browser of anyone who views it. Here, the profile statement accepted a link that started with 'javascript:' instead of a normal web address, so clicking it ran the attacker's script. Because the statement is public, any visitor who clicked the link could be affected.
What is XSS?
Script an attacker supplies runs in another user's browser, on the target's origin, with that user's session.