CVE-2021-31805: Forced OGNL evaluation, when evaluated on raw not validated user input in tag attributes, may lead to RCE.
Vulnerability summary
CVE-2021-31805 is a critical (CVSS 9.8) vulnerability in apache software foundation apache struts. EPSS estimates a 85.43% chance of exploitation in the next 30 days, higher than 99.7% of scored vulnerabilities.
Severe, CVSS 9.8 (NVD); no exploitation reported by the 5 checked sources; EPSS 85% (FIRST, 04-12-2026)
Source freshness unavailable
How is this decided?Timeline
- 12-04-2022PublishedVulnerability first disclosed.
- 03-08-2024Last modifiedVulnerability information updated.
Description
The fix issued for CVE-2020-17530 was incomplete. So from Apache Struts 2.0.0 to 2.5.29, still some of the tag’s attributes could perform a double evaluation if a developer applied forced OGNL evaluation by using the %{...} syntax. Using forced OGNL evaluation on untrusted user input can lead to a Remote Code Execution and security degradation.
CVSS metrics
3 scores · 2 sources · 2 versions- OSV · MavenEcosystem advisory · calculated9.8CriticalCVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
EPSS trend
Probability
85.43%
Chance of exploitation in the next 30 days
Percentile
100%
Versus all other CVEs
30-day change
No change 0.00 pp
From 85.43% on 04-11-2026
Known exploited
Compare KEV catalogsNot in the CISA KEV catalog.
Not in the ENISA CNW catalog.
Not in the CIRCL catalog.
Public exploits
0 foundNo public exploits indexed.
Weaknesses
CWE · root causeAffected systems
Known conditions: network-reachable, no authentication, no user interaction (CVSS vector). Other conditions: not stated in public data.
Apache1 product
- struts≥ 2.0.0, ≤ 2.5.29
Apache software foundation1 product
- apache struts2.0.0 to 2.5.29
Org.apache.struts1 product
- struts2-core≥ 2.0.0, < 2.5.30
3 vendors · 3 products
References
6 links- www.openwall.com/lists/oss-security/2022/04/12/6Mailing ListX Refsource MLISTWEBMitigationThird Party Advisory