Sulu: Stored XSS via media download inline-disposition override
Impact
Stored Cross Site Scripting (XSS) in the media download endpoint.
The download route (/media/{id}/download/{slug} and its admin variant) accepts the query parameter ?inline=1. When it is present, the response is sent with the header Content-Disposition: inline for any MIME type, which overrides the disposition rules the server would otherwise apply. By default, HTML and other scriptable uploads are not blocked, the file is served on the application origin with its stored Content-Type, and no X-Content-Type-Options or Content-Security-Policy header is sent. Because of this, an attacker can upload an HTML file and build a link that runs their own JavaScript in the context of the Sulu origin.
Every installation where users who are not fully trusted can upload media is affected. This includes editors who hold the media add permission. Such an editor can store a payload that runs in the authenticated session of anyone who opens the link, including an administrator, which allows theft of the session and credentials and lets the attacker act as the victim.
The problem is present on the 2.6 and 3.0 branches and goes back to the introduction of the ?inline override in 2017. It is not the same as CVE-2024-47617, which was a reflected XSS through the slug and is already fixed.
Patches
Fixed in 2.6.25 and 3.0.8. The download route now forces Content-Disposition: attachment for MIME types a browser renders as a document (text/html, application/xhtml+xml, text/xml, application/xml), even when ?inline=1 is requested. Inline viewing is unchanged for safe types such as PDF and images.
Workarounds
Block scriptable uploads by MIME type through sulu_media.upload.blocked_file_types. This stops new uploads only, so existing media has to be reviewed separately.
sulu_media:
upload:
blocked_file_types: [text/html, application/xhtml+xml, image/svg+xml, text/xml, application/xml, text/javascript, application/javascript]
At the web server or reverse proxy, force Content-Disposition: attachment and add X-Content-Type-Options: nosniff and a restrictive Content-Security-Policy on the paths /media/*/download/* and /admin/media/*/download/*.
Serve uploaded media from a separate origin that does not share the application cookies.
Restrict the media upload permission to trusted users and keep the default SVG sanitizer enabled.
Affected software
Click a technology to see all vulnerabilities affecting it.
| Platform | Package | Vulnerable versions | Fixed in |
|---|---|---|---|
| Composer package | sulu/sulu | < 2.6.25, >= 3.0.0-alpha1, < 3.0.8 | 2.6.25, 3.0.8 |
References
- https://github.com/sulu/sulu/security/advisories/GHSA-pp4x-ccxq-6r33
- https://nvd.nist.gov/vuln/detail/CVE-2026-82396
- https://github.com/sulu/sulu/commit/d061094f5b7bb1d5e974544fce30bede9c7adf8e
- https://github.com/sulu/sulu
- https://github.com/sulu/sulu/releases/tag/2.6.25
- https://github.com/sulu/sulu/releases/tag/3.0.8
- CVSS vector
CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:C/C:L/I:L/A:N- Weakness (CWE)
CWE-79- Platform
- Composer
- Package
sulu/sulu- Disclosed
- 02.09.2026
- Updated
- 11.10.2026 10:22
Sources and licenses
OSV / GitHub Advisory Database - GHSA-pp4x-ccxq-6r33 - CC BY 4.0
Vulnerability history: sulu/sulu
All published vulnerabilities of this package (Composer package), newest first. Shows whether this is a one-off slip or a package that needs watching.
- Total entries
- 18
- First → latest
- 08.2020 09.2026
- Without a fix
- 0
- Exploited in attacks
- 0
Severity breakdown
- High 2
- Medium 14
- Low 2
Disclosures per year
- 2020: 1
- 2021: 4
- 2022: 0
- 2023: 1
- 2024: 4
- 2025: 1
- 2026: 7
-
Sulu: Stored XSS via media download inline-disposition override this entry
Know which vulnerabilities affect your application
With the DockRay integration and software inventory enabled, DockRay checks reported component versions against known vulnerabilities and notifies you about confirmed matches. Coverage depends on the supported technology and available advisory data.