CVE-2011-1772 — struts2-core
CVE-2011-1772 is a Cross-site Scripting (XSS) vulnerability in org.apache.struts:struts2-core. 5 public exploit or proof-of-concept references are indexed, so weaponization risk is real. A fix is available for org.apache.struts:struts2-core — see the affected versions and patch details below.
Cross-site Scripting in Apache Struts
EPSS Exploitation Probability
Probability of exploitation in the next 30 days, from FIRST.org EPSS.
Real-World Exposure
org.apache.struts:struts2-coreReal-time download stats are indexed for npm and PyPI packages. This vulnerability affects Maven packages — download data is not available via public APIs for these ecosystems.
Description
Multiple Cross-Site Scripting (XSS) in XWork generated error pages in Apache Struts. By default, XWork doesn't escape action's names in automatically generated error page, allowing for a successful XSS attack. When Dynamic Method Invocation (DMI) is enabled, the action name is generated dynamically base on request parameters. This allows to call non-existing page and method to produce error page with injected code as below. As of Struts 2.2.3 the action names are escaped when automatically generated error pages are rendered.
Affected Packages
| Ecosystem | Package | Vulnerable range | Fix |
|---|---|---|---|
| ☕Maven | org.apache.struts:struts2-core | all versions | 2.2.3org.apache.struts:struts2-core:2.2.3 |
Affected Products
strutsapachewebworkopensymphonyxworkopensymphonyResearch use only. For defensive security, authorized penetration testing, and academic research only. Never execute exploit code against systems without explicit written authorization.
Apache Struts 2.0.0 < 2.2.1.1 - XWork 's:submit' HTML Tag Cross-Site Scripting
by Dr. Marian Ventuneac · May 10, 2011
Detection & mitigation playbook
Open-source dependencyDetect
Scan your dependency tree (package-lock.json, pnpm-lock.yaml, requirements.txt, go.sum, etc.) for org.apache.struts:struts2-core, including transitive dependencies — a direct dependency you never call can still pull in a vulnerable version.
Fix
Update org.apache.struts:struts2-core to 2.2.3 or later, then make sure no transitive (indirect) dependency still pins the vulnerable range — O3 confirms CVE-2011-1772 is resolved across your whole dependency graph.
Workarounds
Escape or sanitise the affected output on the server side rather than relying on client-side filtering, and add a Content-Security-Policy that blocks inline script execution so injected markup cannot run even if it reaches the page.
Frequently Asked Questions
Is CVE-2011-1772 in your dependencies?
Find it across Maven, including transitive dependencies.