CVE-2026-133637: Apache Struts Bean Validation messages run as OGNL expressions

ByLinuxtastic

November 30, 2026 #Apache Struts, #CVE

Apache Struts is the Java web framework behind a great many internal business applications on Linux servers, and its Bean Validation plugin turns Jakarta Bean Validation constraints on action fields into form errors. In Struts 2.5.0 through 2.5.33, 6.0.0 through 6.12.0 and 7.0.0 through 7.4.0, a validation message that carries the submitted value in its text could be evaluated as an OGNL expression rather than displayed, so a visitor who types an expression into a field whose constraint message echoes the value can run code on the server. Upgrade to Struts 7.5.0 or later (7.5.1 is the download on offer), or 6.13.0 on the 6.x line, and redeploy; until then, give every constraint whose message includes the validated value an explicit message key. Applications that do not use the Bean Validation plugin are not affected, and Struts 7 is only affected when the OGNL allowlist has been switched off.

CVE-2026-133637 at a glance.

ComponentApache Struts, the Bean Validation plugin (struts2-bean-validation-plugin) and the framework’s message interpolation; a library bundled into each application’s WAR, not a distribution package. Apache’s advisory id is S2-081
Affected versionsStruts 2.5.0 to 2.5.33 (end of life), 6.0.0 to 6.12.0, and 7.0.0 to 7.4.0 only when the OGNL allowlist is disabled; it is enabled by default, so Struts 7 in its default configuration is not affected. Only applications that use the Bean Validation plugin are affected
Fixed inStruts 7.5.0 and 6.13.0 (the advisory); the project’s download page offers 7.5.1 and 6.13.0 on 30 November 2026. The fix shows provider-produced messages as text; the struts.beanValidation.convertMessageToUtf setting now applies only to messages resolved from message resources
SeverityApache rates it Moderate and gives no CVSS; the CISA ADP container on the CVE record scores it CVSS 3.1 8.8 High (AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H). NVD had no record for this id on 30 November 2026. CWE-917, expression language injection
Exploited in the wildNot on CISA’s Known Exploited Vulnerabilities list as of 30 November 2026 (catalogue 2026.11.27). EPSS: no score yet on 30 November 2026
Who is exposedStruts applications that load the Bean Validation plugin and whose constraints use a message containing the submitted value, which includes the provider’s standard messages for some constraints; an unauthenticated visitor only needs to reach a form that the constraint validates. Struts 7 with the default allowlist, and applications without the plugin, are not exposed
PublishedCVE record 30 November 2026 (Apache CNA; the advisory page was last edited 20 November 2026); credit Adam Korczynski of Ada Logics, for Anthropic; this page built 30 November 2026, last updated 30 November 2026

What it is

Bean Validation constraints carry a message template, and the provider fills the template in when a value fails: a @Size or @Pattern message can say what the offending value was, and the provider’s own default messages do so for some constraints. The Struts plugin takes the interpolated message and hands it to the framework as a field error, and the framework’s text handling treated that string the way it treats its own message resources, where ${…} and %{…} are OGNL expressions to be evaluated. A visitor who submits an expression as the field value, in a way that fails the constraint, therefore gets the expression evaluated on the server when the error message is built. The record files it as CWE-917, expression language injection, and the advisory says plainly that remote code execution is possible.

The two limits on it matter. The constraint’s message must place the submitted value into its text; a message that says only “must be between 1 and 10 characters” gives the attacker nothing to evaluate. And on Struts 7 the OGNL allowlist, on by default, confines what an expression may touch, so the advisory lists 7.0.0 to 7.4.0 as affected only where someone has disabled it. Struts 6 and the end-of-life 2.5 line have no such guard. The fix in 7.5.0 and 6.13.0 renders provider-produced messages as text and narrows struts.beanValidation.convertMessageToUtf to messages that came from the application’s own message resources, which is the behaviour change to test for after upgrading.

This is one of ten Struts CVE records published on 30 November 2026 (CVE-2026-133636 to CVE-2026-133644 and CVE-2026-133649), each with its own S2 advisory; this page covers S2-081 only, and we read no other advisory for it. Apache’s security page notes that 7.5.0 and 6.13.0 also extended the default excluded packages for OGNL to java.beans, java.lang.reflect and java.lang.invoke, which is one more reason to take the whole release rather than cherry-pick.

Who is affected on Linux

Struts ships inside the application, so the row that matters is the last one; no distribution packages Struts 2, 6 or 7 (Debian carries only the ancient libstruts1.2-java), and the trackers we consulted on 30 November 2026 either had no entry or refused automated readers.

DistributionStatusFixed package
AlpineNot consultednot packaged
DebianTracker unreachable on 30 November 2026not packaged (Struts 2/6/7)
UbuntuTracker unreachable on 30 November 2026not packaged
RHEL, Rocky, Alma, CentOS StreamSecurity-data feed unreachable on 30 November 2026not packaged
openSUSE/SLE, Fedora, ArchSUSE page unreachable on 30 November 2026; others not consultednot packaged
Applications bundling Struts (Maven/Gradle dependency, WAR on Tomcat, Jetty or WildFly)Affected at 2.5.0–2.5.33, 6.0.0–6.12.0, and 7.0.0–7.4.0 with the allowlist off, when the Bean Validation plugin is usedstruts2-core 7.5.1 (or 7.5.0) / 6.13.0, rebuilt and redeployed

How to check

Three questions: which Struts is deployed, is the Bean Validation plugin on the classpath, and do any constraint messages interpolate the submitted value. On Struts 7 there is a fourth, whether anyone turned the allowlist off.

# 1. the deployed framework and plugin jars (the file name carries the version)
find / -name 'struts2-core-*.jar' 2>/dev/null
find / -name 'struts2-bean-validation-plugin-*.jar' 2>/dev/null
# a WAR that has not been exploded: list its libraries
unzip -l /path/to/app.war 2>/dev/null | grep -E 'struts2-(core|bean-validation-plugin)'

# 2. messages that put the submitted value into the text, in your own sources and bundles
grep -rnE '\$\{validatedValue\}' --include='*.java' --include='*.properties' --include='*.xml' /path/to/app/src 2>/dev/null | head
# constraints with no explicit message at all fall back to the provider's defaults
grep -rnE '@(Size|Pattern|Min|Max|Email|NotBlank)\(' --include='*.java' /path/to/app/src 2>/dev/null | grep -v 'message *=' | head

# 3. Struts 7 only: has the OGNL allowlist been disabled in the configuration?
grep -rniE 'allowlist' --include='struts*.xml' --include='*.properties' /path/to/app 2>/dev/null

No struts2-bean-validation-plugin jar means the vulnerable path is not loaded and you are done, whatever the core version. Core at 7.5.0 or later, or 6.13.0 or later, is fixed. An affected core with the plugin present is the case to act on: step 2 tells you how wide the door is, and on Struts 7 step 3 tells you whether the allowlist is still standing in front of it. Treat a hit in step 2 on Struts 6 or 2.5 as exploitable by anyone who can submit the form.

How to fix it

Bump the dependency, rebuild, redeploy and restart the servlet container; a running JVM keeps the old classes until it restarts. Struts 6.x applications can stay on the 6 line with 6.13.0, which carries the same fix.

# Maven: in pom.xml, every org.apache.struts artifact to the same version
#   <struts2.version>7.5.1</struts2.version>        (or 6.13.0 on the 6.x line)
mvn -q versions:display-dependency-updates 2>/dev/null | grep -i struts
mvn clean package
# Gradle: implementation 'org.apache.struts:struts2-core:7.5.1' (and the plugin at the same version)

# redeploy and restart the container that hosts the WAR
systemctl restart tomcat10        # or tomcat9, jetty, wildfly, as installed
# confirm what is now running
find / -name 'struts2-core-*.jar' 2>/dev/null

If you cannot ship a new build yet, the advisory’s workaround is to give every constraint whose message includes the validated value an explicit message key, with the key’s text kept in the application’s message resources rather than in the annotation. On Struts 7, confirm the OGNL allowlist is enabled and leave it that way; it is the reason the default configuration is not affected. Do not treat a web application firewall rule on ${ and %{ as the fix, since the advisory describes the evaluation happening in the message, not in a URL you can filter, and encodings vary.

# before: the provider's message interpolates the value
#   @Size(max = 10)
# after: an explicit key, with the text in the message resources
#   @Size(max = 10, message = "{field.too_long}")
# package.properties / ApplicationResources.properties:
#   field.too_long=The value is too long (at most 10 characters)

Sources

  • CVE-2026-133637 at CVE.org — the Apache CNA record (30 November 2026): the description, the three affected ranges, CWE-917, the credit; the CISA ADP container carries the CVSS 3.1 8.8
  • S2-081 — the Apache Struts advisory: “Moderate”, the fix versions, the explicit-message-key workaround and the backward-compatibility note
  • Apache Struts security page and the download page (7.5.1 and 6.13.0 offered, 30 November 2026)
  • NVD entry — no record on 30 November 2026
  • Distribution trackers: Debian · Ubuntu · Red Hat · SUSE (all unreachable on 30 November 2026; Struts is not packaged by any of them)
  • EPSS — no score for this CVE on 30 November 2026

Related reading

This advisory page was assembled from the primary sources listed above on 30 November 2026 and is updated when they change. The facts are theirs; the checks and the ordering are ours. If a row in the distribution table is out of date, the tracker link in that row is the current word.