MediumGHSA-4qrp-27r3-66fj
Improper sanitize of SVG files during content upload ('Cross-site Scripting') in sylius/sylius
Affected versions
before 1.9.10, 1.10.0 to before 1.10.11, 1.11.0 to before 1.11.2 - fixed in 1.9.10Details
### Impact There is a possibility to upload an SVG file containing XSS code in the admin panel. In order to perform an XSS attack, the file itself has to be opened in a new card (or loaded outside of the IMG tag). The problem applies both to the files opened on the admin panel and shop pages. ### Patches The issue is fixed in versions: 1.9.10, 1.10.11, 1.11.2, and above. ### Workarounds If there is a need to upload an SVG image type, on-upload sanitization has to be added. The way to achieve this is to require a library that will do the trick: ``` composer require enshrined/svg-sanitize ```
References
- https://nvd.nist.gov/vuln/detail/CVE-2022-24749
- https://github.com/Sylius/Sylius/security/advisories/GHSA-4qrp-27r3-66fj
- https://nvd.nist.gov/vuln/detail/CVE-2022-24749
- https://github.com/Sylius/Sylius
- https://github.com/Sylius/Sylius/releases/tag/v1.10.11
- https://github.com/Sylius/Sylius/releases/tag/v1.11.2
- https://github.com/Sylius/Sylius/releases/tag/v1.9.10
Is your site exposed?Run a free passive scan. See your platform, versions and the issues on your surface in under a minute.
Check if my site is affected