{"description":"Trending threats, MITRE ATT\u0026CK coverage, and detection metadata. Fed continuously.","favicon":"https://feed.craftedsignal.io/favicon-32x32.png","feed_url":"https://feed.craftedsignal.io/products/twig/feed.json","home_page_url":"https://feed.craftedsignal.io/","icon":"https://feed.craftedsignal.io/apple-touch-icon.png","items":[{"_cs_actors":[],"_cs_cpes":[],"_cs_cves":[],"_cs_exploited":false,"_cs_has_poc":false,"_cs_poc_references":[],"_cs_products":["twig/twig (\u003e= 3.24.0, \u003c 3.26.0)"],"_cs_severities":["high"],"_cs_tags":["twig","sandbox-bypass","cve-2026-46639"],"_cs_type":"advisory","_cs_vendors":["Twig"],"content_html":"\u003cp\u003eTwig versions 3.24.0 to 3.26.0 contain a sandbox bypass vulnerability (CVE-2026-46639) due to the object-destructuring assignment syntax introduced in version 3.24.0. This syntax generates a call to \u003ccode\u003eCoreExtension::getAttribute()\u003c/code\u003e with the \u003ccode\u003e$sandboxed\u003c/code\u003e argument hardcoded to \u003ccode\u003efalse\u003c/code\u003e, effectively disabling property and method policy checks. An attacker with write access to a sandboxed Twig template can exploit this to read any public property or invoke any public getter on objects passed to the template engine, bypassing the intended \u003ccode\u003eSecurityPolicy\u003c/code\u003e restrictions. The exploit requires only the \u003ccode\u003e{% do %}\u003c/code\u003e tag to be in \u003ccode\u003eallowedTags\u003c/code\u003e, a common configuration in many Twig deployments. This bypass allows attackers to potentially gain sensitive information or execute arbitrary code depending on the objects passed to the template.\u003c/p\u003e\n\u003ch2 id=\"attack-chain\"\u003eAttack Chain\u003c/h2\u003e\n\u003col\u003e\n\u003cli\u003eAn attacker gains write access to a Twig template file within a sandboxed environment.\u003c/li\u003e\n\u003cli\u003eThe attacker injects a Twig template containing an object-destructuring assignment expression, such as \u003ccode\u003e{% set { foo, bar } = my_object %}\u003c/code\u003e.\u003c/li\u003e\n\u003cli\u003eThe Twig template engine parses and compiles the modified template.\u003c/li\u003e\n\u003cli\u003eDuring compilation, the \u003ccode\u003eObjectDestructuringSetBinary::compile()\u003c/code\u003e function is invoked.\u003c/li\u003e\n\u003cli\u003e\u003ccode\u003eObjectDestructuringSetBinary::compile()\u003c/code\u003e generates a call to \u003ccode\u003eCoreExtension::getAttribute()\u003c/code\u003e with the \u003ccode\u003e$sandboxed\u003c/code\u003e argument set to \u003ccode\u003efalse\u003c/code\u003e.\u003c/li\u003e\n\u003cli\u003eWhen the template is rendered, the \u003ccode\u003egetAttribute()\u003c/code\u003e function is executed without enforcing the sandbox's property and method access restrictions.\u003c/li\u003e\n\u003cli\u003eThe attacker is able to read public properties and invoke public getters of \u003ccode\u003emy_object\u003c/code\u003e that would normally be blocked by the \u003ccode\u003eSecurityPolicy\u003c/code\u003e.\u003c/li\u003e\n\u003cli\u003eThe attacker leverages the ability to access sensitive data or trigger unintended behavior, potentially escalating privileges or gaining further access to the system.\u003c/li\u003e\n\u003c/ol\u003e\n\u003ch2 id=\"impact\"\u003eImpact\u003c/h2\u003e\n\u003cp\u003eSuccessful exploitation of this vulnerability (CVE-2026-46639) allows attackers to bypass the Twig sandbox, potentially leading to information disclosure or arbitrary code execution. The number of affected installations is unknown, but any Twig application using versions 3.24.0 to 3.26.0 with a sandboxed environment is vulnerable if an attacker can modify the template files. The primary impact is a loss of confidentiality and integrity within the application, as attackers can access sensitive data or modify application behavior.\u003c/p\u003e\n\u003ch2 id=\"recommendation\"\u003eRecommendation\u003c/h2\u003e\n\u003cul\u003e\n\u003cli\u003eUpgrade to Twig version 3.26.0 or later to patch CVE-2026-46639.\u003c/li\u003e\n\u003cli\u003eImplement strict access controls to prevent unauthorized modification of Twig template files.\u003c/li\u003e\n\u003cli\u003eDeploy the Sigma rule \u003ccode\u003eDetect Twig Sandbox Bypass via getAttribute\u003c/code\u003e to detect exploitation attempts based on the vulnerable \u003ccode\u003egetAttribute()\u003c/code\u003e calls.\u003c/li\u003e\n\u003c/ul\u003e\n","date_modified":"2026-05-21T21:32:33Z","date_published":"2026-05-21T21:32:33Z","id":"https://feed.craftedsignal.io/briefs/2026-05-twig-sandbox-bypass/","summary":"A vulnerability in Twig versions 3.24.0 to 3.26.0 (CVE-2026-46639) allows an attacker with write access to a sandboxed Twig template to bypass security policy restrictions by exploiting object-destructuring assignment to read any public property or invoke any public getter on objects passed to the template engine.","title":"Twig Sandbox Bypass via Object Destructuring Assignment (CVE-2026-46639)","url":"https://feed.craftedsignal.io/briefs/2026-05-twig-sandbox-bypass/"},{"_cs_actors":[],"_cs_cpes":[],"_cs_cves":[],"_cs_exploited":false,"_cs_has_poc":false,"_cs_poc_references":[],"_cs_products":["twig/twig (\u003c 3.26.0)"],"_cs_severities":["critical"],"_cs_tags":["code-injection","twig","rce"],"_cs_type":"advisory","_cs_vendors":["Composer"],"content_html":"\u003cp\u003eA critical code injection vulnerability, tracked as CVE-2026-46633, affects Twig versions before 3.26.0. The vulnerability stems from insufficient escaping of single quotes within the \u003ccode\u003eCompiler::string()\u003c/code\u003e function when handling template names in \u003ccode\u003e{% use %}\u003c/code\u003e tags. Specifically, the \u003ccode\u003eCompiler::string()\u003c/code\u003e function escapes characters like \u003ccode\u003e\u0026quot;\u003c/code\u003e and \u003ccode\u003e$\u003c/code\u003e but fails to escape single quotes, which are later used within a PHP single-quoted string literal in \u003ccode\u003eModuleNode::compileConstructor()\u003c/code\u003e. This oversight allows an attacker to inject arbitrary PHP code by including a single quote in the template name passed to the \u003ccode\u003e{% use %}\u003c/code\u003e tag. The injected code is then executed when the compiled Twig cache file is loaded, bypassing the configured \u003ccode\u003eSecurityPolicy\u003c/code\u003e and leading to remote code execution. The \u003ccode\u003e{% use %}\u003c/code\u003e tag is unconditionally allowed regardless of the \u003ccode\u003eallowedTags\u003c/code\u003e configuration, making this vulnerability reachable even from sandboxed templates.\u003c/p\u003e\n\u003ch2 id=\"attack-chain\"\u003eAttack Chain\u003c/h2\u003e\n\u003col\u003e\n\u003cli\u003eAttacker crafts a malicious Twig template containing a \u003ccode\u003e{% use %}\u003c/code\u003e tag.\u003c/li\u003e\n\u003cli\u003eThe template name within the \u003ccode\u003e{% use %}\u003c/code\u003e tag includes a single quote followed by arbitrary PHP code, e.g., \u003ccode\u003e{% use 'x' . phpinfo() . 'y' %}\u003c/code\u003e.\u003c/li\u003e\n\u003cli\u003eThe Twig template is rendered using a vulnerable version of Twig (\u0026lt;3.26.0).\u003c/li\u003e\n\u003cli\u003eDuring compilation, the \u003ccode\u003eModuleNode::compileConstructor()\u003c/code\u003e function processes the \u003ccode\u003e{% use %}\u003c/code\u003e tag and uses \u003ccode\u003eCompiler::string()\u003c/code\u003e to escape the template name.\u003c/li\u003e\n\u003cli\u003e\u003ccode\u003eCompiler::string()\u003c/code\u003e fails to escape the single quote, allowing the attacker to break out of the surrounding PHP single-quoted string literal.\u003c/li\u003e\n\u003cli\u003eThe malicious PHP code is written into the compiled Twig cache file.\u003c/li\u003e\n\u003cli\u003eThe compiled Twig cache file is loaded by the PHP engine during subsequent template renderings.\u003c/li\u003e\n\u003cli\u003eThe injected PHP code executes within the PHP process, bypassing the Twig sandbox and achieving remote code execution.\u003c/li\u003e\n\u003c/ol\u003e\n\u003ch2 id=\"impact\"\u003eImpact\u003c/h2\u003e\n\u003cp\u003eSuccessful exploitation of this vulnerability allows attackers to execute arbitrary PHP code on the server hosting the Twig application. Given that the Twig sandbox is bypassed, attackers can perform a wide range of malicious actions, including reading sensitive files, modifying application data, and potentially gaining full control of the server. This vulnerability affects applications using Twig versions prior to 3.26.0.\u003c/p\u003e\n\u003ch2 id=\"recommendation\"\u003eRecommendation\u003c/h2\u003e\n\u003cul\u003e\n\u003cli\u003eUpgrade to Twig version 3.26.0 or later to patch CVE-2026-46633.\u003c/li\u003e\n\u003cli\u003eDeploy the following Sigma rule to detect potential exploitation attempts by monitoring for the \u003ccode\u003euse\u003c/code\u003e tag containing a single quote (').\u003c/li\u003e\n\u003cli\u003eReview existing Twig templates for any instances of user-controlled input being used in \u003ccode\u003e{% use %}\u003c/code\u003e tags and sanitize the input to prevent code injection.\u003c/li\u003e\n\u003c/ul\u003e\n","date_modified":"2026-05-21T21:26:07Z","date_published":"2026-05-21T21:26:07Z","id":"https://feed.craftedsignal.io/briefs/2026-05-twig-code-injection/","summary":"A code injection vulnerability (CVE-2026-46633) exists in Twig versions prior to 3.26.0, where a single quote in the `{% use %}` template name is not properly escaped, allowing arbitrary PHP code execution by bypassing the Twig sandbox.","title":"Twig: PHP Code Injection via `{% use %}` Template Name (CVE-2026-46633)","url":"https://feed.craftedsignal.io/briefs/2026-05-twig-code-injection/"},{"_cs_actors":[],"_cs_cpes":[],"_cs_cves":[{"cvss":6.5,"id":"CVE-2026-9082"}],"_cs_exploited":true,"_cs_has_poc":true,"_cs_poc_references":[],"_cs_products":["Drupal 10.4.x","Drupal 10.5.x","Drupal 10.6.x","Drupal 11.0.x","Drupal 11.1.x","Drupal 11.2.x","Drupal 11.3.x","Drupal 8.9.x","Drupal Core","Drupal Core (8.0.0 - 11.3.9)","Drupal Core 8.9.x","PostgreSQL","Symfony","Twig"],"_cs_severities":["critical"],"_cs_tags":["cve","sql injection","drupal","web application"],"_cs_type":"threat","_cs_vendors":["Drupal","Google","Mandiant","Symfony","Twig"],"content_html":"\u003ch2 id=\"overview\"\u003eOverview\u003c/h2\u003e\n\u003cp\u003eA proof-of-concept exploit has been published for CVE-2026-9082, a critical SQL injection vulnerability affecting Drupal Core when using a PostgreSQL database backend. The vulnerability impacts Drupal versions 8.0.0 through 11.3.9. The vulnerability resides in the PostgreSQL Entity Query Condition handler. The issue can be exploited by unauthenticated users through the JSON:API module, which is enabled by default since Drupal 9. Successful exploitation could lead to unauthorized data access, privilege escalation, and potentially remote code execution in certain server configurations. The existence of a public exploit increases the risk to unpatched Drupal installations.\u003c/p\u003e\n\u003ch2 id=\"attack-chain\"\u003eAttack Chain\u003c/h2\u003e\n\u003col\u003e\n\u003cli\u003eAn unauthenticated attacker sends a crafted HTTP request to a vulnerable Drupal server using the JSON:API endpoint.\u003c/li\u003e\n\u003cli\u003eThe request includes malicious SQL code embedded within the array keys of the filter conditions in the URL parameters.\u003c/li\u003e\n\u003cli\u003eDrupal's PostgreSQL Entity Query Condition handler processes the request and iterates over the provided array keys.\u003c/li\u003e\n\u003cli\u003eThe \u003ccode\u003etranslateCondition()\u003c/code\u003e method constructs PDO placeholder names using the attacker-controlled array keys.\u003c/li\u003e\n\u003cli\u003eDue to insufficient sanitization, the malicious SQL code is injected into the PDO placeholder name.\u003c/li\u003e\n\u003cli\u003eThe injected SQL code bypasses the intended query sanitization mechanisms.\u003c/li\u003e\n\u003cli\u003eThe database executes the injected SQL code, allowing the attacker to manipulate database queries.\u003c/li\u003e\n\u003cli\u003eThe attacker can extract sensitive data, escalate privileges, or potentially execute arbitrary code on the server (RCE) in certain configurations.\u003c/li\u003e\n\u003c/ol\u003e\n\u003ch2 id=\"impact\"\u003eImpact\u003c/h2\u003e\n\u003cp\u003eSuccessful exploitation of CVE-2026-9082 can lead to significant consequences for affected Drupal websites. Attackers can exfiltrate sensitive data from the database, including user credentials, personally identifiable information (PII), and other confidential data. Privilege escalation allows attackers to gain administrative access to the Drupal site, enabling them to modify content, install malicious modules, or compromise the entire server. In some server configurations, the vulnerability can be leveraged to achieve remote code execution (RCE), granting the attacker complete control over the system. Given the broad usage of Drupal, a successful widespread attack could impact numerous organizations across various sectors.\u003c/p\u003e\n\u003ch2 id=\"recommendation\"\u003eRecommendation\u003c/h2\u003e\n\u003cul\u003e\n\u003cli\u003eApply the patches provided in Drupal SA-CORE-2026-004 to address CVE-2026-9082. Upgrade to Drupal Core versions 11.3.10, 11.2.12, 10.6.9, or 10.5.10 depending on your current branch to remediate the vulnerability.\u003c/li\u003e\n\u003cli\u003eMonitor web server logs for suspicious HTTP requests targeting the JSON:API endpoint (\u003ccode\u003e/jsonapi\u003c/code\u003e) with unusual filter parameters containing SQL metacharacters, as described in the Attack Chain (webserver category).\u003c/li\u003e\n\u003cli\u003eDeploy the Sigma rule \u0026quot;Detect CVE-2026-9082 Exploitation Attempt — Drupal SQL Injection via JSON:API\u0026quot; to detect potential exploitation attempts in real-time.\u003c/li\u003e\n\u003cli\u003eBlock access to the identified malicious Git repository URL (\u003ccode\u003ehttps://github.com/7h30th3r0n3/CVE-2026-9082-Drupal-PoC.git\u003c/code\u003e) to prevent internal systems from downloading the exploit code (IOC).\u003c/li\u003e\n\u003c/ul\u003e\n","date_modified":"2026-11-19T22:16:04Z","date_published":"2026-05-21T11:02:28Z","id":"https://feed.craftedsignal.io/briefs/2026-05-drupal-sqli/","summary":"A public exploit is available for CVE-2026-9082, a SQL injection vulnerability in Drupal Core affecting PostgreSQL-backed sites running versions 8.0 through 11.3.9, allowing unauthenticated users to potentially achieve data exfiltration, privilege escalation, and remote code execution.","title":"Drupal Core PostgreSQL SQL Injection Vulnerability (CVE-2026-9082) Exploit Available","url":"https://feed.craftedsignal.io/briefs/2026-05-drupal-sqli/"}],"language":"en","title":"CraftedSignal Threat Feed - Twig","version":"https://jsonfeed.org/version/1.1"}