CVE-2026-46639: CWE-693: Protection Mechanism Failure in twigphp Twig
Twig versions from 3.24.0 up to but not including 3.26.0 contain a vulnerability where object-destructuring assignment compiles CoreExtension::getAttribute() with the sandbox argument hardcoded to false. This disables property and method policy checks, allowing an attacker with write access to a sandboxed Twig template to read public properties or invoke public getters on objects passed to the template engine. The issue is fixed in version 3.26.0.
AI Analysis
Technical Summary
The vulnerability in Twig (CVE-2026-46639) affects versions 3.24.0 through 3.25.x, where the object-destructuring assignment compiles CoreExtension::getAttribute() with the sandbox argument set to false. This disables the sandbox's property and method policy enforcement, enabling an attacker who can write to a sandboxed Twig template to bypass restrictions and access public properties or invoke public getters on objects. This undermines the sandbox protection mechanism (CWE-693). The vulnerability is resolved in Twig version 3.26.0.
Potential Impact
An attacker with write access to a sandboxed Twig template can bypass sandbox restrictions to read public properties or invoke public getters on objects passed to the template engine. This could lead to unauthorized information disclosure within the application context. The vulnerability does not require user interaction and has a low attack complexity but requires some level of privilege (write access to templates).
Mitigation Recommendations
Upgrade Twig to version 3.26.0 or later, where this vulnerability is fixed. Patch status is confirmed by the vendor advisory indicating the fix in 3.26.0. No other mitigations are specified or effective given the nature of the vulnerability.
CVE-2026-46639: CWE-693: Protection Mechanism Failure in twigphp Twig
Description
Twig versions from 3.24.0 up to but not including 3.26.0 contain a vulnerability where object-destructuring assignment compiles CoreExtension::getAttribute() with the sandbox argument hardcoded to false. This disables property and method policy checks, allowing an attacker with write access to a sandboxed Twig template to read public properties or invoke public getters on objects passed to the template engine. The issue is fixed in version 3.26.0.
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
The vulnerability in Twig (CVE-2026-46639) affects versions 3.24.0 through 3.25.x, where the object-destructuring assignment compiles CoreExtension::getAttribute() with the sandbox argument set to false. This disables the sandbox's property and method policy enforcement, enabling an attacker who can write to a sandboxed Twig template to bypass restrictions and access public properties or invoke public getters on objects. This undermines the sandbox protection mechanism (CWE-693). The vulnerability is resolved in Twig version 3.26.0.
Potential Impact
An attacker with write access to a sandboxed Twig template can bypass sandbox restrictions to read public properties or invoke public getters on objects passed to the template engine. This could lead to unauthorized information disclosure within the application context. The vulnerability does not require user interaction and has a low attack complexity but requires some level of privilege (write access to templates).
Mitigation Recommendations
Upgrade Twig to version 3.26.0 or later, where this vulnerability is fixed. Patch status is confirmed by the vendor advisory indicating the fix in 3.26.0. No other mitigations are specified or effective given the nature of the vulnerability.
Technical Details
- Data Version
- 5.2
- Assigner Short Name
- GitHub_M
- Date Reserved
- 2026-05-15T20:11:54.584Z
- Cvss Version
- 4.0
- State
- PUBLISHED
- Remediation Level
- null
Threat ID: 6a56aea268715ace4342b107
Added to database: 07/14/2026, 21:48:18 UTC
Last enriched: 07/14/2026, 22:19:29 UTC
Last updated: 07/14/2026, 22:27:32 UTC
Views: 2
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.