Stored XSS through SVG file upload with filter bypass
The application allowed an SVG file to be uploaded with a .png extension and an image/svg+xml content type, bypassing inline-rendering checks. A parser differential in the SVG sanitizer caused a fallback that only removed script tags, leaving event handlers intact, so an attacker could store an SVG that executes JavaScript when viewed.
github.com
Published on github.com
freescout-help-desk published GHSA-cvr8-cw5c-5pfw Mar 17, 2026
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
Impact
Any authenticated user could store a URL that, when visited by another user or administrator, executes JavaScript in their browser and performs actions on their behalf.
What the attacker needed
Authenticated user account; victim visits the crafted URL
The fix
The issue was fixed in version 1.8.209.
How it was found
- Send a multipart upload request to the conversation upload endpoint with a valid session and CSRF token.
- Set the filename to an allowed extension such as .png and the part's Content-Type to image/svg+xml.
- Include an SVG body with an onload handler and a comment-wrapped PHP-like tag to trigger the sanitizer fallback.
- Receive a success response containing a URL to the stored file.
- Visit the returned URL in a browser to trigger the JavaScript.
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 website let people upload files and tried to block dangerous ones by checking the file name and type. The attacker uploaded a file that looked like a harmless image to those checks but was actually a script. When someone opened the file, the script ran in their browser and could act as them.
What is XSS?
Script an attacker supplies runs in another user's browser, on the target's origin, with that user's session.