cve.bz

CVE-2026-41901 thymeleaf thymeleaf: Expression Language Injection

9.0 criticalEPSS 0.4%Fix available

Critical (9.0) in thymeleaf thymeleaf. EPSS 0.4% estimated probability of exploitation activity in the next 30 days. Fixed in org.thymeleaf:thymeleaf 3.1.5.RELEASE.

On this page
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.

Severity

CVSS 3.1

9.0 critical
CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:C/C:H/I:H/A:H
EPSS
0.4% (unchanged from 0.4% a week ago; 0.5% 30 days ago) estimated probability of exploitation activity in the next 30 days; 38th percentile. Scored 2026-11-23. A forecast for this CVE across the internet, not for your own systems.
CISA's assessment (SSVC)
Exploitation: none · Automatable: no · Technical impact: total, assessed 2026-05-13. From CISA's Vulnrichment in the CVE List: whether it is exploited, whether exploiting it can be automated, and how much control it gives.
CWEs
CWE-917 Improper Neutralization of Special Elements used in an Expression Language Statement (Expression Language Injection)
CWE-1336 Improper Neutralization of Special Elements Used in a Template Engine
OWASP Top 10
A05:2025 Injection
Published
Modified
NVD analysis
Deferred: the NVD does not plan to analyze it
Record from
the NVD, synced

Fix and patched versions

  • org.thymeleaf:thymeleaf (Maven): fixed in 3.1.5.RELEASE
  • org.thymeleaf:thymeleaf-spring5 (Maven): fixed in 3.1.5.RELEASE
  • org.thymeleaf:thymeleaf-spring6 (Maven): fixed in 3.1.5.RELEASE

Ask an AI about this CVE

Show the promptExplain CVE-2026-41901 for an engineer deciding whether to act. Use https://cve.bz/api/public/cves/CVE-2026-41901?via=ask-ai-copy and https://cve.bz/cve/CVE-2026-41901?via=ask-ai-copy as the source of truth: what is affected and which versions fix it, whether it is in CISA KEV, public exploits, and its EPSS (an internet-wide 30-day estimate of exploitation activity, not a forecast for my systems). If they give no fixed versions, use the CVE record https://cveawg.mitre.org/api/cve/CVE-2026-41901 or the vendor advisory, not third-party mirrors. Tell me how to check whether I am affected and how to verify a fix. Cite the sources and say where they are uncertain.

Opens a third-party assistant; its answer is its own, not cve.bz's. The prompt holds only this CVE's id and public links.

Affected

Versions

From the CNA's record in the CVE List.

ProductAffected
thymeleaf< 3.1.5.RELEASE

Packages (OSV)

AdvisoryEcosystemPackageAffectedFixed in
GHSA-c9ph-gxww-7744Mavenorg.thymeleaf:thymeleaf<3.1.5.RELEASE3.1.5.RELEASE
GHSA-c9ph-gxww-7744Mavenorg.thymeleaf:thymeleaf-spring5<3.1.5.RELEASE3.1.5.RELEASE
GHSA-c9ph-gxww-7744Mavenorg.thymeleaf:thymeleaf-spring6<3.1.5.RELEASE3.1.5.RELEASE

Red Hat

Red Hat rates this Important.

Red Hat's statement

This is an Important security bypass in Thymeleaf's expression execution, allowing Server-Side Template Injection (SSTI). The flaw enables arbitrary code execution if an application processes unsanitized input containing malicious expressions within sandboxed template contexts.

Red Hat OpenShift Dev Spaces is not affected by this vulnerability as each version ships with a patched version of Thymeleaf 3.1.5.RELEASE. Thymeleaf is only used in Red Hat OpenShift Dev Spaces for email generation rather than web request handling which limits the severity of this vulnerability.

ProductPackageStateAdvisory
Red Hat Fuse 7thymeleafWill not fix
Red Hat JBoss Enterprise Application Platform Expansion PackthymeleafNot affected
Red Hat OpenShift Dev Spacesdevspaces/openvsx-rhel9Not affected
Red Hat OpenShift Dev Spacesdevspaces/pluginregistry-rhel9Not affected
Red Hat Single Sign-On 7thymeleafFix deferred

Contains Red Hat Security Data © Red Hat, Inc., licensed under CC BY 4.0. Source: https://access.redhat.com/security/data. Modified: reformatted. Red Hat's page for CVE-2026-41901.

GitHub PoC (unverified)

Repositories on GitHub named after this CVE. Nobody has checked them and they are not scanned: some hold a working proof of concept, some nothing useful, and some malware made to look like one. Read the code before you run any of it.

References

Check your stackJSON