{"schemaVersion":1,"url":"https://cve.openhack.com/cve/CVE-2026-46636","id":"CVE-2026-46636","title":"Twig: Sandbox method allowlist bypass via `Markup` subclass","description":"Twig is a template language for PHP. From version 1.0.0 to before version 3.27.0, SecurityPolicy::checkMethodAllowed() unconditionally whitelists all method calls on instances of Twig\\Markup. Twig\\Markup is not final, so subclasses inherit the bypass. An application that passes an object of a Markup-derived class into a sandboxed template (typically to mark a chunk of HTML as safe) inadvertently e","descriptionLong":"Twig is a template language for PHP. From version 1.0.0 to before version 3.27.0, SecurityPolicy::checkMethodAllowed() unconditionally whitelists all method calls on instances of Twig\\Markup. Twig\\Markup is not final, so subclasses inherit the bypass. An application that passes an object of a Markup-derived class into a sandboxed template (typically to mark a chunk of HTML as safe) inadvertently exposes every public method of that subclass to template authors, regardless of the configured allowedMethods list. This issue has been patched in version 3.27.0.","published":"2026-09-04T22:07:35.122Z","updated":"2026-11-19T19:46:04.857725522Z","reserved":"2026-05-15T20:11:54.584Z","status":"Awaiting Analysis","rejected":false,"assigner":"GitHub_M","metric":{"version":"4.0","score":8.7,"vector":"CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:N/VA:N/SC:N/SI:N/SA:N","rating":"high","source":"GitHub_M"},"metrics":[{"version":"4.0","score":8.7,"vector":"CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:N/VA:N/SC:N/SI:N/SA:N","rating":"high","source":"GitHub_M"},{"version":"4.0","score":8.7,"vector":"CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:N/VA:N/SC:N/SI:N/SA:N/E:X/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X","rating":"high","source":"github.com"},{"version":"4.0","score":null,"vector":"CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:N/VA:N/SC:N/SI:N/SA:N","rating":"unrated","source":"OSV"}],"rating":"high","products":["twigphp Twig"],"affectedProducts":[{"vendor":"twigphp","product":"Twig","defaultStatus":null,"versions":[{"version":">= 1.0.0, < 3.27.0","status":"affected"}],"platforms":[]}],"packages":[],"cwes":["CWE-1336"],"aliases":["GHSA-64jr-qjx4-w2fh"],"references":[{"url":"https://github.com/twigphp/Twig/security/advisories/GHSA-64jr-qjx4-w2fh","tags":["x_refsource_CONFIRM","advisory"]},{"url":"https://security-tracker.debian.org/tracker/CVE-2026-46636","tags":["x_refsource_MISC","web"]},{"url":"https://security-tracker.debian.org/tracker/DSA-6311-1","tags":["x_refsource_MISC","web"]},{"url":"https://symfony.com/blog/cve-2026-46636-sandbox-filter-tag-and-function-allow-list-bypass-when-sandbox-state-changes-between-renders","tags":["x_refsource_MISC","article"]},{"url":"http://github.com/twigphp/Twig/releases/tag/v3.27.0","tags":["x_refsource_MISC","web"]},{"url":"https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/46xxx/CVE-2026-46636.json","tags":["advisory"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2026-46636","tags":["advisory"]}],"patchReferenced":false,"fixAvailable":false,"exploitReferenced":false,"kev":false,"kevAdded":null,"kevDue":null,"kevEntry":null,"ssvc":{"exploitation":"none","automatable":"yes","technicalImpact":"partial"},"epss":0.0057,"epssPercentile":0.47961,"sources":[{"name":"CVE List","url":"https://www.cve.org/CVERecord?id=CVE-2026-46636","ok":true},{"name":"NVD","url":"https://nvd.nist.gov/vuln/detail/CVE-2026-46636","ok":true,"note":"Awaiting Analysis"},{"name":"OSV","url":"https://osv.dev/vulnerability/CVE-2026-46636","ok":true,"note":"0 packages"},{"name":"CISA KEV","url":"https://www.cisa.gov/known-exploited-vulnerabilities-catalog","ok":true,"note":"not listed"},{"name":"EPSS","url":"https://api.first.org/data/v1/epss?cve=CVE-2026-46636","ok":true,"note":"scored 2026-11-19"}],"aiTitle":false,"tech":[],"critical":[],"attention":null}