Contao Vulnerable to Cross-Site Scripting (XSS) through SVG uploads
Package
Affected versions
>= 4.0.0, < 4.13.54
>= 5.3.0, < 5.3.30
>= 5.4.0, < 5.5.6
Patched versions
4.13.54
5.3.30
5.5.6
Description
Published by the National Vulnerability Database
Mar 18, 2025
Published to the GitHub Advisory Database
Mar 18, 2025
Reviewed
Mar 18, 2025
Last updated
Mar 19, 2025
Impact
Users can upload SVG files with malicious code, which is then executed in the back end and/or front end.
Patches
Update to Contao 4.13.54, 5.3.30 or 5.5.6.
Workarounds
Remove
svg,svgz
from the allowed upload file types in the system settings and fromcontao.editable_files
in theconfig.yaml
.References
https://contao.org/en/security-advisories/cross-site-scripting-through-svg-uploads
For more information
If you have any questions or comments about this advisory, open an issue in contao/contao.
References