Code execution via raw-message OGNL evaluation
Published Jul 10, 2017 · Updated Oct 21, 2025
OGNL injection in Apache Struts 2.1.x and 2.3.x allows remote attackers to execute code through Struts 1 plugin messages. Struts1Action.execute passes raw ActionMessage keys containing untrusted field values to getText, which evaluates embedded OGNL expressions. Exploitation requires a reachable Struts 1 action using the plugin and unsafe message construction; executed code inherits the application process's permissions.
Summary
What happened
OGNL injection in Apache Struts 2.1.x and 2.3.x allows remote attackers to execute code through Struts 1 plugin messages. Struts1Action.execute passes raw ActionMessage keys containing untrusted field values to getText, which evaluates embedded OGNL expressions. Exploitation requires a reachable Struts 1 action using the plugin and unsafe message construction; executed code inherits the application process's permissions.
The record
- CVE
- CVE-2017-9791
- Published
- Jul 10, 2017
- Updated
- Oct 21, 2025
- Vendor
- Apache Software Foundation
- Product
- Apache Struts
- Classifications
- CWE-20, T1190
- Attack vector
- network
- Privileges
- unauthenticated
Timeline
How it unfolded
- Jul 10, 2017CVE publishedPublication date reported by the CVE source.
- Oct 21, 2025Record updatedLatest update available in the CVE record.
Exploitability
Present is not the same as exploitable
Compare your product and version with the public record. A matching version still requires validation against your environment.
Is a vulnerable build present?
Compare these published version ranges with your installed build and any vendor patches.
- Affected versionversion=2.1.x series
- Affected versionversion=2.3.x series
What conditions does exploitation require?
What is affected?
Published CVSS scores
CVSS describes severity. EPSS estimates exploitation probability.
Attacks
What attackers are doing with it
Daily unique IPs observed by Shadowserver honeypots for known exploited vulnerabilities (KEVs). Missing observations do not establish an absence of attacks.
Activity data is delayed. The latest report is Sep 28, 2026.
View daily counts
| Reporting day | Unique IPs |
|---|---|
| Sep 22, 2026 | 11 |
| Sep 23, 2026 | 5 |
| Sep 24, 2026 | 12 |
| Sep 25, 2026 | 15 |
| Sep 26, 2026 | 6 |
| Sep 27, 2026 | 16 |
| Sep 28, 2026 | 12 |
Public exploit references
- Apache Struts 2.3.x Showcase remote code execution demonstrationproof of concept · unverified
- Metasploit Struts 1 Plugin Showcase OGNL Code Executionfunctional · unverified
Labels summarize the accepted research assessment. They do not indicate a test against your environment.
Reported exploitation
- CISA Known Exploited Vulnerabilities catalog inclusionknown exploited catalog
Technologies
Your stack
See the directory against your own environment.
Your stack
Check the software in your environment
Get started to see how Hinoki identifies affected software and validates exploitability in your environment.
Contact us