Medium severity5.3NVD Advisory· Published Jul 4, 2016· Updated May 6, 2026
CVE-2016-4465
CVE-2016-4465
Description
The URLValidator class in Apache Struts 2 2.3.20 through 2.3.28.1 and 2.5.x before 2.5.1 allows remote attackers to cause a denial of service via a null value for a URL field.
Affected packages
Versions sourced from the GitHub Security Advisory.
| Package | Affected versions | Patched versions |
|---|---|---|
org.apache.struts:struts2-coreMaven | >= 2.3.20, < 2.3.29 | 2.3.29 |
org.apache.struts:struts2-coreMaven | >= 2.5.0, < 2.5.13 | 2.5.13 |
Patches
2eccc31ebce54Improves validation RegEx
2 files changed · +2 −1
xwork-core/src/main/java/com/opensymphony/xwork2/validator/validators/URLValidator.java+1 −1 modified@@ -82,7 +82,7 @@ public String getUrlRegex() { "|((\\d|[1-9]\\d|1\\d{2}|2[0-4][0-9]|25[0-5])\\.){3}" + "(\\d|[1-9]\\d|1\\d{2}|2[0-4][0-9]|25[0-5])" + ")(:\\d+)?" + - ")(((\\/+([a-z0-9$_\\.\\+!\\*\\'\\(\\),;:@&=-]|%[0-9a-f]{2})*)*" + + ")(((\\/{0,1}([a-z0-9$_\\.\\+!\\*\\'\\(\\),;:@&=-]|%[0-9a-f]{2})*)*" + "(\\?([a-z0-9$_\\.\\+!\\*\\'\\(\\),;:@&=-]|%[0-9a-f]{2})*)" + "?)?)?" + "(#([a-z0-9$_\\.\\+!\\*\\'\\(\\),;:@&=-]|%[0-9a-f]{2})*)?" +
xwork-core/src/test/java/com/opensymphony/xwork2/validator/URLValidatorTest.java+1 −0 modified@@ -139,6 +139,7 @@ public void testValidUrlWithDefaultRegex() throws Exception { assertFalse(pattern.matcher("").matches()); assertFalse(pattern.matcher(" ").matches()); assertFalse(pattern.matcher("no url").matches()); + assertFalse(pattern.matcher("http://example.com////////////////////////////////////////////////////////////////////////////////////??").matches()); assertTrue(pattern.matcher("http://www.opensymphony.com").matches()); assertTrue(pattern.matcher("https://www.opensymphony.com").matches());
a0fdca138feeImproves validation RegEx
2 files changed · +2 −1
core/src/main/java/com/opensymphony/xwork2/validator/validators/URLValidator.java+1 −1 modified@@ -81,7 +81,7 @@ public String getUrlRegex() { "|((\\d|[1-9]\\d|1\\d{2}|2[0-4][0-9]|25[0-5])\\.){3}" + "(\\d|[1-9]\\d|1\\d{2}|2[0-4][0-9]|25[0-5])" + ")(:\\d+)?" + - ")(((\\/+([a-z0-9$_\\.\\+!\\*\\'\\(\\),;:@&=-]|%[0-9a-f]{2})*)*" + + ")(((\\/{0,1}([a-z0-9$_\\.\\+!\\*\\'\\(\\),;:@&=-]|%[0-9a-f]{2})*)*" + "(\\?([a-z0-9$_\\.\\+!\\*\\'\\(\\),;:@&=-]|%[0-9a-f]{2})*)" + "?)?)?" + "(#([a-z0-9$_\\.\\+!\\*\\'\\(\\),;:@&=-]|%[0-9a-f]{2})*)?" +
core/src/test/java/com/opensymphony/xwork2/validator/URLValidatorTest.java+1 −0 modified@@ -138,6 +138,7 @@ public void testValidUrlWithDefaultRegex() throws Exception { assertFalse(pattern.matcher("").matches()); assertFalse(pattern.matcher(" ").matches()); assertFalse(pattern.matcher("no url").matches()); + assertFalse(pattern.matcher("http://example.com////////////////////////////////////////////////////////////////////////////////////??").matches()); assertTrue(pattern.matcher("http://www.opensymphony.com").matches()); assertTrue(pattern.matcher("https://www.opensymphony.com").matches());
Vulnerability mechanics
Generated on May 9, 2026. Inputs: CWE entries + fix-commit diffs from this CVE's patches. Citations validated against bundle.
References
11- jvn.jp/en/jp/JVN12352818/index.htmlnvdVendor AdvisoryWEB
- jvndb.jvn.jp/jvndb/JVNDB-2016-000114nvdVDB EntryVendor AdvisoryWEB
- www-01.ibm.com/support/docview.wssnvdThird Party AdvisoryWEB
- github.com/advisories/GHSA-xg75-68x3-7p3qghsaADVISORY
- nvd.nist.gov/vuln/detail/CVE-2016-4465ghsaADVISORY
- struts.apache.org/docs/s2-041.htmlnvdVendor AdvisoryWEB
- bugzilla.redhat.com/show_bug.cginvdIssue TrackingWEB
- github.com/apache/struts/commit/a0fdca138feec2c2e94eb75ca1f8b76678b4d152ghsaWEB
- github.com/apache/struts/commit/eccc31ebce5430f9e91b9684c63eaaf885e603f9ghsaWEB
- www.oracle.com/technetwork/security-advisory/cpujul2017-3236622.htmlnvd
- www.securityfocus.com/bid/91278nvd
News mentions
0No linked articles in our index yet.