CVE Catalog

CVE-2026-46628

MediumCVSS 5.4
Published: Updated: Translated: NVD NIST

Exploitation Probability (EPSS)

Low risk
0.17%

7th percentile - higher than 7% of all known CVEs

Summary

In the Twig template language for PHP, the deprecated spaceless filter is registered as safe for HTML, causing Twig autoescaping to emit attacker-controlled markup unescaped when spaceless is applied to untrusted input. This issue is fixed in version 3.26.0.

Risk Assessment

An attacker can inject malicious HTML/JavaScript code into templates, leading to Cross-Site Scripting (XSS) attacks and potential data theft or session hijacking.

Recommendation

Immediately upgrade Twig to version 3.26.0 or later. Avoid using the deprecated spaceless filter in templates.

Other vulnerabilities in Twig

See all
Original NVD description (English source)

Twig is a template language for PHP. Prior to 3.26.0, the deprecated spaceless filter is registered as safe for HTML, causing Twig autoescaping to emit attacker-controlled markup unescaped when spaceless is applied to untrusted input. This issue is fixed in version 3.26.0.

Vulnerability data from NVD (NIST) · CISA KEV · EPSS