GHSA-mmpx-jh39-wrv6: FileBrowser Vulnerable to Stored XSS via SVG File in Public Share (Missing CSP Header)
Summary FileBrowser Quantum serves inline SVG files without a Content-Security-Policy header, allowing embedded JavaScript in SVG files to execute when accessed via public share links. Verified on v1.3.0-stable. Affected product - Product: FileBrowser Quantum (gtsteffaniak/filebrowser) - Verified version: v1.3.0-stable - Docker image: gtstef/filebrowser:latest - Affected endpoint: GET…
Published May 7, 2026
Affected packages
github.com/gtsteffaniak/filebrowser
- Ecosystem
- Go
- Affected
- < 0.0.0-20260501184955-6bfc3974192e
- Fixed in
- 0.0.0-20260501184955-6bfc3974192e
- Check
go list -m github.com/gtsteffaniak/filebrowser
Advisory details
From the GitHub Advisory Database (CC BY 4.0).
Summary
FileBrowser Quantum serves inline SVG files without a Content-Security-Policy header, allowing embedded JavaScript in SVG files to execute when accessed via public share links.
Verified on v1.3.0-stable.
Affected product
- Product: FileBrowser Quantum (
gtsteffaniak/filebrowser) - Verified version: v1.3.0-stable
- Docker image: gtstef/filebrowser:latest
- Affected endpoint:
GET /public/api/resources/download?hash=HASH&inline=true - CWE: CWE-79 — Cross-site Scripting (Stored)
Impact
- Stored XSS — Malicious SVG persists and executes for every visitor to the share link
- No authentication required to trigger — Public share links are accessible to anyone
- Session hijacking — If authenticated users click the link, their session can be stolen
- Phishing — Attacker can redirect or overlay fake login forms
Reproduction
- Login as any user with upload permission
- Upload SVG file: ``
xml <svg xmlns="http://www.w3.org/2000/svg"> <script>alert(document.domain)</script> </svg>`` - Create public share for the file
- Access the share link with
?inline=true - JavaScript executes in browser
Root cause
The inline download endpoint returns SVG files with:
Content-Type: image/svg+xml
Content-Disposition: inline; filename="xss.svg"
X-Content-Type-Options: nosniffBut no CSP header to block script execution. The upstream project (filebrowser/filebrowser) mitigates this with:
Content-Security-Policy: script-src 'none'Suggested fix
Add CSP header on inline file downloads:
w.Header().Set("Content-Security-Policy", "script-src 'none'")This matches the upstream filebrowser/filebrowser implementation.
Credited to MuxiLyuLucy.
References
How this page is made: the data panel comes from the GitHub Advisory Database, CISA’s KEV catalog, the NVD and FIRST EPSS, and updates twice a day. No analysis has been written for this entry yet. Methodology
More Go vulnerabilities
All Go entriesGHSA-r4v7-6wcg-ghj5
FileBrowser: Missing Rate Limiting on Authentication Endpoint Enables Brute Force Attacks
medium6.5Jun 25, 2026CVE-2026-46410
FileBrowser Quantum: unauthenticated user share share info
high8.7May 19, 2026CVE-2026-44542
FileBrowser Public Share DELETE API Path Traversal Allows Unauthenticated Arbitrary File Deletion
critical9.1May 7, 2026CVE-2026-30934
FileBrowser Quantum: Stored XSS in public share page via unsanitized share metadata (text/template misuse)
high8.9Mar 9, 2026
