CVE-2026-46637

Twig: HTML-output filters in twig/* extras incorrectly declared `is_safe => ['all']`

Published Jul 14, 2026 CVSS 4.0 · 5.1 Medium EPSS < 1% KEV · Not listed
Description
Twig is a template language for PHP. Prior to 3.26.0, several filters in twig/markdown-extra and twig/cssinliner-extra are registered with is_safe => [all], causing Twig to treat plain text or HTML output as safe in HTML, JavaScript, CSS, URL, and other contexts where the output is not properly escaped. This issue is fixed in version 3.26.0.

Remediation

No solution or workaround provided in the CVE record

Tracking

Sign in to view the affected projects.

Advisories

Source ID Title
Debian DSA Debian DSA DSA-6311-1 php-twig security update
Debian DSA Debian DSA DSA-6320-1 php-twig security update
Github GHSA Github GHSA GHSA-jv8m-2544-3pg3 Twig: HTML-output filters in twig/* extras incorrectly declared `is_safe => ['all']`
History
Type Values Removed Values Added
First Time appeared Twig
Twig cssinliner-extra
Twig markdown-extra
Twigphp
Twigphp twig
Vendors & Products Twig
Twig cssinliner-extra
Twig markdown-extra
Twigphp
Twigphp twig
Type Values Removed Values Added
Metrics ssvc

{'options': {'Automatable': 'no', 'Exploitation': 'none', 'Technical Impact': 'partial'}, 'version': '2.0.3'}

Type Values Removed Values Added
Description Twig is a template language for PHP. Prior to 3.26.0, several filters in twig/markdown-extra and twig/cssinliner-extra are registered with is_safe => [all], causing Twig to treat plain text or HTML output as safe in HTML, JavaScript, CSS, URL, and other contexts where the output is not properly escaped. This issue is fixed in version 3.26.0.
Title Twig: HTML-output filters in twig/* extras incorrectly declared `is_safe => ['all']`
Weaknesses CWE-116
References
Metrics cvssV4_0

{'score': 5.1, 'vector': 'CVSS:4.0/AV:N/AC:L/AT:N/PR:L/UI:P/VC:N/VI:N/VA:N/SC:L/SI:L/SA:N'}

Weaknesses

Sources

Status
PUBLISHED
Assigner
GitHub_M
Published
Updated
Jul 16, 2026, 3:05 PM
Reserved
May 15, 2026, 8:11 PM
Status
Analyzed
Published
Jul 14, 2026, 10:16 PM
Modified
Jul 16, 2026, 4:19 PM