{
  "affected": [
    {
      "ranges": [
        {
          "database_specific": {
            "cpe": "cpe:2.3:a:symfony:twig:*:*:*:*:*:*:*:*",
            "extracted_events": [
              {
                "introduced": "0"
              },
              {
                "fixed": "3.27.0"
              }
            ],
            "source": [
              "CPE_RANGE",
              "REFERENCES"
            ]
          },
          "events": [
            {
              "introduced": "0"
            },
            {
              "fixed": "04ae1bfe9463c816cf72ca0abe7eae2c77a9a9ed"
            },
            {
              "fixed": "9ff41014639ef0e8eb50ac7669191c309d863105"
            }
          ],
          "repo": "https://github.com/twigphp/twig",
          "type": "GIT"
        }
      ]
    }
  ],
  "aliases": [
    "GHSA-5v5v-ww74-355v"
  ],
  "database_specific": {
    "cna_assigner": "GitHub_M",
    "cwe_ids": [
      "CWE-693",
      "CWE-863"
    ],
    "osv_generated_from": "https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/48xxx/CVE-2026-48806.json"
  },
  "details": "Twig is a template language for PHP. Prior to 3.27.0, ArrayExpression does not guard dynamic mapping keys that are coerced to strings, allowing PHP to invoke __toString() on a Stringable object used as a mapping key without calling SandboxExtension::ensureToStringAllowed(). This issue is fixed in version 3.27.0.",
  "id": "CVE-2026-48806",
  "modified": "2026-07-18T03:41:43.285859565Z",
  "published": "2026-07-14T21:28:08.781Z",
  "references": [
    {
      "type": "WEB",
      "url": "https://github.com/twigphp/Twig/releases/tag/v3.27.0"
    },
    {
      "type": "ADVISORY",
      "url": "https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/48xxx/CVE-2026-48806.json"
    },
    {
      "type": "ADVISORY",
      "url": "https://github.com/twigphp/Twig/security/advisories/GHSA-5v5v-ww74-355v"
    },
    {
      "type": "ADVISORY",
      "url": "https://nvd.nist.gov/vuln/detail/CVE-2026-48806"
    },
    {
      "type": "FIX",
      "url": "https://github.com/twigphp/Twig/commit/9ff41014639ef0e8eb50ac7669191c309d863105"
    }
  ],
  "schema_version": "1.8.0",
  "severity": [
    {
      "score": "CVSS:4.0/AV:N/AC:L/AT:N/PR:L/UI:N/VC:H/VI:L/VA:N/SC:N/SI:N/SA:N",
      "type": "CVSS_V4"
    }
  ],
  "summary": "Twig: Sandbox `__toString()` policy bypass via dynamic mapping keys"
}