CVE-2020-17530
📋 TL;DR
This vulnerability in Apache Struts allows attackers to perform remote code execution by forcing OGNL evaluation on raw user input in tag attributes. It affects all Apache Struts 2 installations from version 2.0.0 through 2.5.25. Attackers can exploit this to execute arbitrary code on vulnerable servers.
💻 Affected Systems
- Apache Struts 2
📦 What is this software?
Communications Diameter Intelligence Hub by Oracle
View all CVEs affecting Communications Diameter Intelligence Hub →
Communications Diameter Intelligence Hub by Oracle
View all CVEs affecting Communications Diameter Intelligence Hub →
Communications Diameter Intelligence Hub by Oracle
View all CVEs affecting Communications Diameter Intelligence Hub →
Communications Diameter Intelligence Hub by Oracle
View all CVEs affecting Communications Diameter Intelligence Hub →
Communications Policy Management by Oracle
Communications Pricing Design Center by Oracle
View all CVEs affecting Communications Pricing Design Center →
Financial Services Data Integration Hub by Oracle
View all CVEs affecting Financial Services Data Integration Hub →
Financial Services Data Integration Hub by Oracle
View all CVEs affecting Financial Services Data Integration Hub →
Struts by Apache
⚠️ Risk & Real-World Impact
Worst Case
Full system compromise with attacker gaining complete control over the server, data exfiltration, lateral movement, and persistent backdoor installation.
Likely Case
Remote code execution leading to web application compromise, data theft, and potential ransomware deployment.
If Mitigated
Limited impact with proper input validation and security controls, potentially resulting in denial of service or limited information disclosure.
🎯 Exploit Status
Multiple public exploits exist, and exploitation requires minimal technical skill. The vulnerability is actively exploited in the wild.
🛠️ Fix & Mitigation
✅ Official Fix
Patch Version: Struts 2.5.26 or later
Vendor Advisory: https://cwiki.apache.org/confluence/display/WW/S2-061
Restart Required: Yes
Instructions:
1. Download Struts 2.5.26 or later from Apache website. 2. Replace existing Struts libraries with patched versions. 3. Restart application server. 4. Test application functionality.
🔧 Temporary Workarounds
Input Validation Filter
allImplement strict input validation to block OGNL expressions in user input
Implement custom servlet filter or Struts interceptor to sanitize tag attribute inputs
WAF Rule
allDeploy Web Application Firewall rules to block OGNL expression patterns
Add WAF rule to detect and block patterns like ${, #, @ in request parameters
🧯 If You Can't Patch
- Isolate vulnerable systems in restricted network segments with strict firewall rules
- Implement application-level input validation and output encoding for all user inputs
🔍 How to Verify
Check if Vulnerable:
Check Struts version in application libraries or configuration files. If version is between 2.0.0 and 2.5.25 inclusive, system is vulnerable.
Check Version:
Check struts2-core JAR file version or examine web.xml/struts.xml configuration
Verify Fix Applied:
Verify Struts version is 2.5.26 or later. Test application functionality and monitor for any OGNL evaluation issues.
📡 Detection & Monitoring
Log Indicators:
- Unusual OGNL evaluation errors in application logs
- Suspicious parameter values containing ${, #, or @ symbols
- Unexpected Java class loading or method invocation
Network Indicators:
- HTTP requests with OGNL expressions in parameters
- Unusual outbound connections from application server
- Exploit kit traffic patterns
SIEM Query:
source="app_logs" AND ("OGNL" OR "${*" OR "#*" OR "@*")
🔗 References
- http://jvn.jp/en/jp/JVN43969166/index.html
- http://packetstormsecurity.com/files/160721/Apache-Struts-2-Forced-Multi-OGNL-Evaluation.html
- http://www.openwall.com/lists/oss-security/2022/04/12/6
- https://cwiki.apache.org/confluence/display/WW/S2-061
- https://security.netapp.com/advisory/ntap-20210115-0005/
- https://www.oracle.com//security-alerts/cpujul2021.html
- https://www.oracle.com/security-alerts/cpuApr2021.html
- https://www.oracle.com/security-alerts/cpuapr2022.html
- https://www.oracle.com/security-alerts/cpujan2021.html
- https://www.oracle.com/security-alerts/cpujan2022.html
- https://www.oracle.com/security-alerts/cpuoct2021.html
- http://jvn.jp/en/jp/JVN43969166/index.html
- http://packetstormsecurity.com/files/160721/Apache-Struts-2-Forced-Multi-OGNL-Evaluation.html
- http://www.openwall.com/lists/oss-security/2022/04/12/6
- https://cwiki.apache.org/confluence/display/WW/S2-061
- https://security.netapp.com/advisory/ntap-20210115-0005/
- https://www.oracle.com//security-alerts/cpujul2021.html
- https://www.oracle.com/security-alerts/cpuApr2021.html
- https://www.oracle.com/security-alerts/cpuapr2022.html
- https://www.oracle.com/security-alerts/cpujan2021.html
- https://www.oracle.com/security-alerts/cpujan2022.html
- https://www.oracle.com/security-alerts/cpuoct2021.html
- https://www.cisa.gov/known-exploited-vulnerabilities-catalog?field_cve=CVE-2020-17530