CVE-2026-46633: Php twig · Twig is a template language for PHP
Affects php-twigSource GCVE Database
Not known to be exploited · CVSS 8.7 High · fixed in 3.26.0 : patch php-twig soon.
Data as of 26 Oct 2026, 10:12 UTC
- EPSS
- 0.6% chance of exploitation in 30 days – higher than 52% of CVEsExploit Prediction Scoring System: the likelihood attackers will use this flaw soon.
- Patch
- Available – fixed in 3.26.0
CVSS:4.0/AV:N/AC:L/AT:N/PR:L/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:NExploitation evidence
Disclosed: evidence found.
CVE published 14 Jul 2026
Detectable: no evidence on record.
No public nuclei template indexed
Weaponised: no evidence on record.
No public exploit code indexed in Metasploit or Exploit-DB
Exploited in the wildExploited: no evidence on record.
Not in CISA KEV and no source reports exploitation
Observed by OffSeq MirageSeen by Mirage: no evidence on record.
No attack traffic recorded by OffSeq Mirage sensors
A missing step is not evidence of safety. Sources: cve.org (opens in a new tab), the Metasploit, Exploit-DB and nuclei-templates index as of 26 Oct 2026.
What to do
Affected software
| Product | Affected | Fixed in |
|---|---|---|
Ubuntu 26.10php-twigpkg:deb/ubuntu/php-twig?arch=source&distro=stonkingOther threats | Affected
| Fixed in– |
Ubuntu Pro 26.04 LTSphp-twigpkg:deb/ubuntu/php-twig?arch=source&distro=esm-apps/resoluteOther threats | Affected
| Fixed in– |
Ubuntu 25.10php-twigpkg:deb/ubuntu/php-twig?arch=source&distro=questingOther threats | Affected
| Fixed in– |
Ubuntu Pro 24.04 LTSphp-twigpkg:deb/ubuntu/php-twig?arch=source&distro=esm-apps/nobleOther threats | Affected
| Fixed in– |
Ubuntu Pro 22.04 LTSphp-twigpkg:deb/ubuntu/php-twig?arch=source&distro=esm-apps/jammyOther threats | Affected
| Fixed in– |
Ubuntu Pro 20.04 LTSphp-twigpkg:deb/ubuntu/php-twig?arch=source&distro=esm-apps/focalOther threats | Affected
| Fixed in– |
Check your own hosts for these packages with threat-finder (opens in a new tab), our free open-source scanner.
AI-suggested
A fix is available in Twig version 3.26.0 and later. Users should upgrade to version 3.26.0 or newer to remediate this vulnerability. No additional mitigation steps are indicated by the vendor advisory.
Description
Twig, a PHP template language, has a critical vulnerability in versions prior to 3.26.0. The Compiler::string() method does not properly escape single quotes in template names used in {% use %} tags inside PHP single-quoted string literals. This flaw allows crafted template names to inject arbitrary PHP code into the compiled cache file. The vulnerability is fixed starting with version 3.26.0.
References
- ubuntu.com/security/CVE-2026-46633 (opens in a new tab)
- cve.org/CVERecord?id=CVE-2026-46633 (opens in a new tab)
- symfony.com/blog/cve-2026-46633-php-code-injection-via-use-template-name (opens in a new tab)
- github.com/twigphp/Twig/commit/679447fa29083043665482ccf7d64372472621b8 (opens in a new tab)
- github.com/twigphp/Twig/commit/e9ff55f6910832428e48a35b2e0748189ad49ae3 (opens in a new tab)
- github.com/twigphp/Twig/releases/tag/v3.26.0 (opens in a new tab)
- github.com/twigphp/Twig/security/advisories/GHSA-7p85-w9px-jpjp (opens in a new tab)