Injection of arbitrary HTML/JavaScript code through the media download URL
Published 3 Oct 2024 · Updated 17 Oct 2024
Is your project on an affected sulu/sulu?
Look after several Laravel or PHP apps? Indie watches up to 15 repos, private ones too, for $5 a month. See Indie
Affected packages
- Affected
- >=2.6.0 <2.6.5
- Fixed in
- 2.6.5
composer require sulu/sulu:^2.6.5- Affected
- >=2.0.0 <2.5.21
- Fixed in
- 2.5.21
composer require sulu/sulu:^2.5.21Details
Impact
This vulnerability allows an attacker to inject arbitrary HTML/JavaScript code through the media download URL in Sulu CMS. It affects the SuluMediaBundle component. The vulnerability is a Reflected Cross-Site Scripting (XSS) issue, which could potentially allow attackers to steal sensitive information, manipulate the website's content, or perform actions on behalf of the victim.
Patches
The problem has not been patched yet. Users should upgrade to patched versions once they become available. Currently affected versions are:
- 2.6.4
- 2.5.20
Workarounds
Until an official patch is released, users can implement additional input validation and output encoding for the 'slug' parameter in the MediaStreamController's downloadAction method. Alternatively, configuring a Web Application Firewall (WAF) to filter potentially malicious input could serve as a temporary mitigation.
References
- GitHub repository: https://github.com/sulu/sulu
- Vulnerable code: https://github.com/sulu/sulu/blob/2.6/src/Sulu/Bundle/MediaBundle/Controller/MediaStreamController.php#L106
Is GHSA-6784-9c82-vr85 in any of your client repos?
Checking one package by hand is fine. Checking it across forty client projects is not. NPMscan reads the lockfiles in every GitHub repo you pick, finds each project with an affected sulu/sulu, and gives you the command that fixes it.
More advisories for sulu/sulu
- MediumCVE-2026-92692Sulu: JCR-SQL2 injection via `categories` query parameter (unauthenticated) · 23 Sept 2026
- MediumCVE-2026-82396Sulu: Stored XSS via media download inline-disposition override · 2 Sept 2026
- MediumCVE-2026-82394Sulu: Fix authorization bypass when creating preview links · 2 Sept 2026
- MediumCVE-2026-82395Sulu: Media move/update authorization bypass (IDOR) · 2 Sept 2026
- LowGHSA-9m6v-8fxc-4r44Sulu: Used API Keys may be available via Admin API · 18 May 2026
- MediumCVE-2026-45701Sulu: Weak Cryptographical usage for API Key generation and Reset Tokens · 18 May 2026
References
- Linkgithub.com/sulu/sulu/security/advisories/GHSA-6784-9c82-vr85
- Advisorynvd.nist.gov/vuln/detail/CVE-2024-47617
- Linkgithub.com/sulu/sulu/commit/a5a5ae555d282e88ff8559d38cfb46dea7939bda
- Linkgithub.com/sulu/sulu/commit/eeacd14b6cf55f710084788140d40ebb00314b29
- Packagegithub.com/sulu/sulu
- Linkgithub.com/sulu/sulu/blob/2.6/src/Sulu/Bundle/MediaBundle/Controller/MediaStreamController.php#L106
Advisory data from OSV.dev (opens OSV.dev in a new tab), refreshed daily.