CVE-2026-46627: CWE-400: Uncontrolled Resource Consumption in twigphp Twig
Twig, a PHP template language, has a vulnerability (CVE-2026-46627) related to uncontrolled resource consumption in its sandbox feature prior to version 3.26.0. The sandbox does not prevent templates from exhausting CPU, memory, or wall-clock time, even with strict allow-lists. This can allow untrusted templates to cause resource exhaustion. The issue is addressed in version 3.26.0 by clarifying that the sandbox does not protect against resource exhaustion, rather than by implementing a fix.
AI Analysis
Technical Summary
CVE-2026-46627 describes a resource exhaustion vulnerability in the Twig PHP template engine's sandbox prior to version 3.26.0. The sandbox feature, intended to restrict template behavior, does not prevent excessive consumption of CPU, memory, or wall-clock time by templates, even when strict allow-lists are applied. This allows untrusted templates to cause denial-of-service conditions through resource exhaustion. The vendor addressed this issue in version 3.26.0 by documenting the limitation of the sandbox rather than providing a technical fix.
Potential Impact
Untrusted templates executed within the Twig sandbox can cause excessive CPU, memory, or wall-clock time consumption, potentially leading to denial-of-service conditions. This impacts applications that use the Twig sandbox to process untrusted templates, as they may be vulnerable to resource exhaustion attacks.
Mitigation Recommendations
Patch status is not yet confirmed — check the vendor advisory for current remediation guidance. Version 3.26.0 documents that the sandbox does not protect against resource exhaustion, implying no technical fix is provided. Users should consider alternative mitigations such as limiting resource usage at the system or application level, sandboxing execution environments, or avoiding untrusted templates. Monitor vendor communications for any future updates or fixes.
CVE-2026-46627: CWE-400: Uncontrolled Resource Consumption in twigphp Twig
Description
Twig, a PHP template language, has a vulnerability (CVE-2026-46627) related to uncontrolled resource consumption in its sandbox feature prior to version 3.26.0. The sandbox does not prevent templates from exhausting CPU, memory, or wall-clock time, even with strict allow-lists. This can allow untrusted templates to cause resource exhaustion. The issue is addressed in version 3.26.0 by clarifying that the sandbox does not protect against resource exhaustion, rather than by implementing a fix.
CVSS v4.0
Score 7.1high
Affected software
Run on your own infrastructure? Check whether these packages are installed with threat-finder — our free open-source scanner.
Weaknesses
AI-Powered Analysis
Machine-generated threat intelligence
Technical Analysis
CVE-2026-46627 describes a resource exhaustion vulnerability in the Twig PHP template engine's sandbox prior to version 3.26.0. The sandbox feature, intended to restrict template behavior, does not prevent excessive consumption of CPU, memory, or wall-clock time by templates, even when strict allow-lists are applied. This allows untrusted templates to cause denial-of-service conditions through resource exhaustion. The vendor addressed this issue in version 3.26.0 by documenting the limitation of the sandbox rather than providing a technical fix.
Potential Impact
Untrusted templates executed within the Twig sandbox can cause excessive CPU, memory, or wall-clock time consumption, potentially leading to denial-of-service conditions. This impacts applications that use the Twig sandbox to process untrusted templates, as they may be vulnerable to resource exhaustion attacks.
Mitigation Recommendations
Patch status is not yet confirmed — check the vendor advisory for current remediation guidance. Version 3.26.0 documents that the sandbox does not protect against resource exhaustion, implying no technical fix is provided. Users should consider alternative mitigations such as limiting resource usage at the system or application level, sandboxing execution environments, or avoiding untrusted templates. Monitor vendor communications for any future updates or fixes.
Technical Details
- Data Version
- 5.2
- Assigner Short Name
- GitHub_M
- Date Reserved
- 2026-05-15T19:34:14.013Z
- Cvss Version
- 4.0
- State
- PUBLISHED
- Remediation Level
- null
Threat ID: 6a56aea068715ace4342b0cc
Added to database: 07/14/2026, 21:48:16 UTC
Last enriched: 07/14/2026, 22:24:36 UTC
Last updated: 07/14/2026, 22:56:20 UTC
Views: 3
Community Reviews
0 reviewsCrowdsource mitigation strategies, share intel context, and vote on the most helpful responses. Sign in to add your voice and help keep defenders ahead.
Want to contribute mitigation steps or threat intel context? Sign in or create an account to join the community discussion.
Actions
Updates to AI analysis require Pro Console access. Upgrade inside Console → Billing.
Need more coverage?
Upgrade to Pro Console for AI refresh and higher limits.
For incident response and remediation, OffSeq services can help resolve threats faster.
Latest Threats
Check if your credentials are on the dark web
Instant breach scanning across billions of leaked records. Free tier available.