{"id":"CVE-2026-41901","aliases":["CVE-2026-41901","GHSA-c9ph-gxww-7744"],"related":[],"kind":"vulnerability","state":"published","title":"Thymeleaf: Improper recognition of unauthorized syntax patterns in sandboxed Thymeleaf expressions","summary":"Thymeleaf is a server-side Java template engine for web and standalone environments. Prior to 3.1.5.RELEASE, a security bypass vulnerability exists in the expression execution mechanisms of Thymeleaf. Although the library provides mechanisms to avoid the execution of potentially dangerous expressions in some specific sandboxed (restricted) contexts, it fails to properly neutralize specific constructs that allow this kind of expressions to be executed. If an application developer passes to the template engine unsanitized variables that contain such expressions, and these values are used in sandboxed contexts inside the templates, these expressions can be executed achieving Server-Side Template Injection (SSTI). This vulnerability is fixed in 3.1.5.RELEASE.","summarySource":"cvelist","descriptions":[{"lang":"en","text":"Thymeleaf is a server-side Java template engine for web and standalone environments. Prior to 3.1.5.RELEASE, a security bypass vulnerability exists in the expression execution mechanisms of Thymeleaf. Although the library provides mechanisms to avoid the execution of potentially dangerous expressions in some specific sandboxed (restricted) contexts, it fails to properly neutralize specific constructs that allow this kind of expressions to be executed. If an application developer passes to the template engine unsanitized variables that contain such expressions, and these values are used in sandboxed contexts inside the templates, these expressions can be executed achieving Server-Side Template Injection (SSTI). This vulnerability is fixed in 3.1.5.RELEASE.","source":"cvelist"},{"lang":"en","text":"### Impact\n\nA security bypass vulnerability exists in the expression execution mechanisms of Thymeleaf up to and including 3.1.4.RELEASE. Although the library provides mechanisms to avoid the execution of potentially dangerous expressions in some specific sandboxed (restricted) contexts, it fails to properly neutralize specific constructs that allow this kind of expressions to be executed. If an application developer passes to the template engine unsanitized variables that contain such expressions, and these values are used in sandboxed contexts inside the templates, these expressions can be executed achieving Server-Side Template Injection (SSTI).\n\n### Patches\n\nThis has been fixed in Thymeleaf 3.1.5.RELEASE. All users are advised to upgrade immediately.\n\n### Workarounds\n\nNo workaround is available beyond ensuring applications do not pass unvalidated/unsanitized data directly to the template engine. Upgrading to 3.1.5.RELEASE is strongly recommended in any case.","format":"markdown","source":"ghsa"}],"published":"2026-05-04T21:15:20.000Z","modified":"2026-06-17T10:47:09.893Z","severity":{"scorer":"GitHub_M","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:C/C:H/I:H/A:H","score":9,"rating":"CRITICAL"},"severities":[{"scorer":"GitHub_M","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:C/C:H/I:H/A:H","score":9,"rating":"CRITICAL"},{"scorer":"GitHub","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:C/C:H/I:H/A:H","score":9,"rating":"CRITICAL"}],"cwes":["CWE-917","CWE-1336"],"affected":[{"ranges":[{"version":"< 3.1.5.RELEASE","status":"affected"}],"vendor":"thymeleaf","product":"thymeleaf","source":"cvelist"},{"ranges":[{"type":"ecosystem","introduced":"0","status":"affected","fixed":"3.1.5.RELEASE"}],"ecosystem":"Maven","package":"org.thymeleaf:thymeleaf","purl":"pkg:maven/org.thymeleaf/thymeleaf","source":"ghsa"},{"ranges":[{"type":"ecosystem","introduced":"0","status":"affected","fixed":"3.1.5.RELEASE"}],"ecosystem":"Maven","package":"org.thymeleaf:thymeleaf-spring5","purl":"pkg:maven/org.thymeleaf/thymeleaf-spring5","source":"ghsa"},{"ranges":[{"type":"ecosystem","introduced":"0","status":"affected","fixed":"3.1.5.RELEASE"}],"ecosystem":"Maven","package":"org.thymeleaf:thymeleaf-spring6","purl":"pkg:maven/org.thymeleaf/thymeleaf-spring6","source":"ghsa"}],"references":[{"url":"https://github.com/thymeleaf/thymeleaf/security/advisories/GHSA-c9ph-gxww-7744","tags":["web","x-refsource-confirm"],"sources":["cvelist","ghsa","nvd"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2026-41901","tags":["advisory"],"sources":["ghsa"]},{"url":"https://github.com/thymeleaf/thymeleaf","tags":["package"],"sources":["ghsa"]}],"credits":[],"assigner":"GitHub_M","ssvc":{"scorer":"CISA-ADP","exploitation":"none","automatable":"no","technicalImpact":"total","date":"2026-05-13T12:07:53.448Z"},"sources":[{"source":"cvelist","name":"CVE List","id":"CVE-2026-41901","url":"https://www.cve.org/CVERecord?id=CVE-2026-41901","licence":"CVE Terms of Use","modified":"2026-05-13T12:08:38.767Z"},{"source":"ghsa","name":"GitHub Advisory Database","id":"GHSA-c9ph-gxww-7744","url":"https://github.com/advisories/GHSA-c9ph-gxww-7744","licence":"CC-BY-4.0","modified":"2026-05-13T17:02:46.716Z"},{"source":"nvd","name":"NVD","id":"CVE-2026-41901","url":"https://nvd.nist.gov/vuln/detail/CVE-2026-41901","licence":"Public domain","modified":"2026-06-17T10:47:09.893Z"}],"updatedAt":"2026-11-25T22:59:21.515Z","epss":{"score":0.00427,"percentile":0.38853,"date":"2026-12-01T12:00:22.000Z"}}