Filesatck Upload Advisory Summary
The FileStack Upload application allowed uploading SVG files containing JavaScript, which executed when the uploaded file was viewed in a browser. An attacker could run JavaScript in the context of the cdn.filestackcontent.com subdomain and any domain that loads the image as SVG.
Published on bishopfox.com
The following document describes identified vulnerabilities in the FileStack Upload application.
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 application did not sanitise or restrict uploaded SVG files, allowing embedded JavaScript to execute when the file was served and rendered as SVG.
What the attacker needed
Ability to upload files to FileStack; victim visits the uploaded SVG URL
The fix
The vendor did not treat this as a vulnerability, so no fix was applied; the report recommends displaying SVG images only via <img> tags, using a strong CSP, sandboxing iframes, and stripping JavaScript from SVGs.
How it was found
- Craft an SVG image that includes JavaScript code.
- Upload the SVG image to FileStack.
- Visit the resulting URL in a browser to execute the JavaScript payload.
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.
Cross-site scripting (XSS) is when a website lets an attacker sneak JavaScript code into a page that other people view. Here, the file upload service accepted SVG image files that contained JavaScript, and when someone opened the uploaded file directly in a browser, that code ran. The attacker could then do things like read information available to that website in the victim's browser.
What is XSS?
Script an attacker supplies runs in another user's browser, on the target's origin, with that user's session.