CVE-2026-46636: twigphp Twig · Template Injection
Affects twigphp TwigSource CVE Database V5
Not known to be exploited · CVSS 8.7 High : upgrade to 3.27.0 soon.
Data as of 4 Dec 2026, 18:37 UTC
- EPSS
- 0.3% chance of exploitation in 30 days – higher than 31% of CVEsExploit Prediction Scoring System: the likelihood attackers will use this flaw soon.
- Patch
- Available – fixed in 3.27.0
CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:N/VA:N/SC:N/SI:N/SA:NExploitation evidence
Disclosed: evidence found.
CVE published 4 Sep 2026
Detectable: no evidence on record.
No public nuclei template indexed
Weaponized: 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 5 Dec 2026.
What to do
Upgrade twigphp Twig to 3.27.0.
Affected software
| Product | Affected | Fixed in |
|---|---|---|
| twigphpTwig | Affected
| Fixed in
|
AI-suggested
Upgrade Twig to version 3.27.0 or later, where this vulnerability has been fixed. No other mitigations are indicated or recommended by the vendor advisory. Patch status is confirmed by the vendor advisory stating the issue is resolved in 3.27.0.
Description
Twig versions from 1.0.0 up to but not including 3.27.0 contain a vulnerability where the SecurityPolicy::checkMethodAllowed() function unconditionally allows all method calls on instances of Twig\Markup and its subclasses. This flaw allows sandboxed templates to access every public method of Markup-derived objects, bypassing configured method restrictions. The issue was fixed in version 3.27.0.
References
- github.com/twigphp/Twig/security/advisories/GHSA-64jr-qjx4-w2fh (opens in a new tab)
- security-tracker.debian.org/tracker/CVE-2026-46636 (opens in a new tab)
- security-tracker.debian.org/tracker/DSA-6311-1 (opens in a new tab)
- symfony.com/blog/cve-2026-46636-sandbox-filter-tag-and-function-allow-list-bypass-when-sandbox-state-changes-between-renders (opens in a new tab)
- github.com/twigphp/Twig/releases/tag/v3.27.0 (opens in a new tab)