Skip to main content
Press slash or control plus K to focus the search. Use the arrow keys to navigate results and press enter to open a threat.
Reconnecting to live updates…

CVE-2026-46627: CWE-400: Uncontrolled Resource Consumption in twigphp Twig

0
High
VulnerabilityCVE-2026-46627cvecve-2026-46627cwe-400
Published: 07/14/2026 (07/14/2026, 21:15:17 UTC)
Source: CVE Database V5
Vendor/Project: twigphp
Product: 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

Attack Vector
Network
Attack Complexity
Low
Attack Requirements
None
Privileges Required
Low
User Interaction
None
Vuln. Confidentiality
None
Vuln. Integrity
None
Vuln. Availability
High
Subsq. Confidentiality
None
Subsq. Integrity
None
Subsq. Availability
None
CVSS:4.0/AV:N/AC:L/AT:N/PR:L/UI:N/VC:N/VI:N/VA:H/SC:N/SI:N/SA:N

Affected software

Packagistmore threats →ai
twig/twig
pkg:composer/twig/twig
Affected versions
<3.26.0

Run on your own infrastructure? Check whether these packages are installed with threat-finder — our free open-source scanner.

AI-Powered Analysis

Machine-generated threat intelligence

AILast updated: 07/14/2026, 22:24:36 UTC

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.

Pro Console: star threats, build custom feeds, automate alerts via Slack, email & webhooks.Upgrade to Pro

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 reviews

Crowdsource mitigation strategies, share intel context, and vote on the most helpful responses. Sign in to add your voice and help keep defenders ahead.

Sort by
Loading community insights…

Want to contribute mitigation steps or threat intel context? Sign in or create an account to join the community discussion.

Actions

PRO

Updates to AI analysis require Pro Console access. Upgrade inside Console → Billing.

Please log in to the Console to use AI analysis features.

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

Breach by OffSeqOFFSEQFRIENDS — 25% OFF

Check if your credentials are on the dark web

Instant breach scanning across billions of leaked records. Free tier available.

Scan now
OffSeq TrainingCredly Certified

Lead Pen Test Professional

Technical5-day eLearningPECB Accredited
View courses