{
  "id": "CVE-2026-46634",
  "url": "https://poc.griffinguard.io/cve/CVE-2026-46634",
  "published_at": "2026-07-14T21:19:17.804Z",
  "title": "Twig: `template_from_string()` escapes a SourcePolicy-driven sandbox via synthesized template name",
  "vendor": "twigphp",
  "product": "Twig",
  "cvss": {
    "score": 9.8,
    "source": "nvd",
    "vector": "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H"
  },
  "kev": {
    "in_kev": false,
    "added_at": null,
    "days_after_publication": null
  },
  "first_poc": null,
  "poc_repo_count": 0,
  "exploit_count": 0,
  "suspicious_repo_count": 0,
  "edge_device": null,
  "description": "Twig is a template language for PHP. From 3.9.0 until 3.26.0, template_from_string() compiles an inner template under a synthesized __string_template__\u003chash\u003e name that can fall outside a SourcePolicyInterface sandbox decision, allowing a sandboxed template that can call template_from_string and include to render an inner template without security policy enforcement. This issue is fixed in version 3.26.0.",
  "cwe": "CWE-693",
  "cpes": [
    "cpe:2.3:a:symfony:twig:*:*:*:*:*:*:*:*"
  ],
  "cvss_by_source": {
    "cna": 7.7,
    "nvd": 9.8
  },
  "repos": [],
  "remediation": {
    "affected": [
      {
        "vendor": "twigphp",
        "product": "Twig",
        "ranges": [
          "\u003e= 3.9.0, \u003c 3.26.0"
        ],
        "fixed_in": [
          "3.26.0"
        ]
      }
    ],
    "upgrade": [
      "Upgrade Twig to 3.26.0 or later."
    ],
    "references": [
      {
        "kind": "Vendor advisory",
        "url": "https://github.com/twigphp/Twig/security/advisories/GHSA-24x9-r6q4-q93w"
      },
      {
        "kind": "Patch",
        "url": "https://github.com/twigphp/Twig/commit/1cde8f2b62463f85d47995fc25f8241cb409d915"
      },
      {
        "kind": "Release notes",
        "url": "https://github.com/twigphp/Twig/releases/tag/v3.26.0"
      }
    ]
  },
  "exploit_refs": [],
  "hunt_profile": [],
  "rules": []
}
