CVE-2016-3081: Apache Struts 2 S2-032 RCE via method: prefix with Dynamic Method Invocation
Exploited in the wild High 8.1 EPSS 96.5% Apache Struts
Apache Struts 2.3.19 to 2.3.28 (except 2.3.20.3 and 2.3.24.3) let remote attackers pass a malicious OGNL expression through the method: prefix and execute arbitrary code on the server when Dynamic Method Invocation (DMI) is enabled. Apache fixed it in April 2016 (S2-032) in 2.3.20.3, 2.3.24.3 and 2.3.28.1. CISA added it to the Known Exploited Vulnerabilities catalog on 2026-10-08, so legacy Struts 2.3 web applications should be checked and rebuilt.
- CVE-2016-3081CVE identifier
- 8.1CVSS 3.1 base score (high)
- 2026-10-08added to CISA's exploited list (US federal deadline 2026-10-11)
- 96.5%EPSS: chance of exploitation in the next 30 days (higher than 100% of CVEs)
- 2016-04-26published
What do these terms mean? CVE · CVSS score · exploited (KEV) · EPSS · backported fix · all terms
What to do now
- Check whether you run Apache Struts and which version (commands below).
- Install the fixed version for your system: see “Patch it” below.
- Redeploy the rebuilt application (WAR) and restart the servlet container.
- If you cannot patch today, apply the temporary mitigation below and patch as soon as possible.
- Because this flaw is being exploited, also check the server for signs of compromise.
Affected and fixed versions
Affected:
- Apache Struts 2.3.19 to 2.3.20.2
- Apache Struts 2.3.21 to 2.3.24.1
- Apache Struts 2.3.25 to 2.3.28
Fixed in:
- Apache Struts 2.3.20.3
- Apache Struts 2.3.24.3
- Apache Struts 2.3.28.1
Am I affected?
find / -name 'struts2-core-*.jar' 2>/dev/null
grep -rn 'struts.enable.DynamicMethodInvocation' /path/to/webapp/WEB-INF/classes/struts.xml
Patch it
Use the commands for your system. Distribution packages often keep an older version number with the fix backported, so compare with the fixed package versions in the table below, not only with the upstream version.
Debian
bundled in applicationsUbuntu
bundled in applicationsRHEL, AlmaLinux, Rocky, Oracle
bundled in applicationsFedora
bundled in applicationsSUSE / openSUSE
bundled in applicationsAmazon Linux
bundled in applicationsArch Linux
bundled in applicationsAlpine
bundled in applicationsFreeBSD
bundled in applicationsBuilt from source
# Maven: raise the dependency and rebuild/redeploy the application
# <dependency>
# <groupId>org.apache.struts</groupId>
# <artifactId>struts2-core</artifactId>
# <version>2.3.28.1</version> <!-- or 2.3.20.3 / 2.3.24.3, or a current supported Struts release -->
# </dependency>
mvn clean packageGeneral update steps for every system are on the Linux and Unix & BSD pages; after updating, see which services to restart.
If you cannot patch yet
- Disable Dynamic Method Invocation (Apache workaround), in struts.xml: <constant name="struts.enable.DynamicMethodInvocation" value="false"/>
- Alternatively implement your own ActionMapper based on the source of the fixed Struts versions (Apache).
CISA required action: Apply mitigations in accordance with vendor instructions, ensuring compliance with CISA’s BOD 26-04 Prioritizing Security Updates Based on Risk (see URL in Notes) guidance and CISA’s “Forensics Triage Requirements” (see URL in Notes). Follow applicable BOD 26-04 guidance for cloud services or discontinue use of the product if mitigations are unavailable. Stakeholders are responsible for evaluating each asset's internet exposure and ensuring adherence to BOD 26-04 patching guidelines.
This vulnerability could affect an open-source component, third-party library, protocol, or proprietary implementation that could be used by different products. For more information, please see: https://cwiki.apache.org/confluence/display/WW/S2-032 ; ; BOD 26-04: https://www.cisa.gov/news-events/directives/bod-26-04-prioritizing-security-updates-based-risk ; Forensics Triage Requirements: https://www.cisa.gov/news-events/directives/bod-26-04-implementation-guidance-prioritizing-security-updates-based-risk ; https://nvd.nist.gov/vuln/detail/CVE-2016-3081
Sources
- Apache Struts security bulletin S2-032
- Apache Struts docs: Action configuration (Dynamic Method Invocation)
- Maven Central: org.apache.struts:struts2-core:2.3.28.1
- Debian security tracker CVE-2016-3081
- CVE record CVE-2016-3081
- https://struts.apache.org/docs/s2-032.html
- https://www.exploit-db.com/exploits/39756/
- CVE-2016-3081 on CVE.org
- CVE-2016-3081 on NVD
- CISA Known Exploited Vulnerabilities catalog
Page generated automatically from official sources on 2026-11-03 18:05 UTC and reviewed by an editor. Always confirm with your vendor's advisory.