GHSA-48M4-24CQ-37QF
Vulnerability from github – Published: 2026-10-28 21:16 – Updated: 2026-10-28 21:16Summary
ONNX shape inference performed an out-of-bounds read when processing a malformed RNN, GRU, or LSTM node from opsets 1–6 whose first input had a rank other than three.
RNNShapeInference_opset1_to_6() checked whether the input shape was present but accessed dim(0) and dim(1) without first checking its rank. A crafted model could therefore terminate a process that called onnx.shape_inference.infer_shapes(). The model passed onnx.checker.check_model() before reaching the vulnerable path.
Technical details
The vulnerable code read dimensions unconditionally:
if (hasInputShape(ctx, 0)) {
const auto& first_input_shape = getInputShape(ctx, 0);
seq_length = first_input_shape.dim(0);
batch_size = first_input_shape.dim(1);
}
For an undersized shape, protobuf's repeated-field access read outside the intended array in release builds. The observed result was SIGSEGV; sanitizer and debug builds terminated on a protobuf bounds check.
The newer opset 7–13 and opset 14+ inference paths already required the first input to have rank three and were not affected.
Impact
An application that performs shape inference on an untrusted model can be terminated, causing denial of service. Exploitation does not require privileges or human interaction once the model is processed. No confidentiality or integrity impact was demonstrated.
Affected versions
- Affected: ONNX through 1.21.0
- Patched: ONNX 1.22.0
The vulnerable schemas are limited to RNN and LSTM opsets 1–6 and GRU opsets 3–6.
Remediation
Upgrade to ONNX 1.22.0 or later. The fix validates that the first input has rank three before accessing its dimensions.
- Fix: onnx/onnx#7879
- Commit:
92e541266
The original malformed model was also re-tested against the published ONNX 1.23.2 wheel and correctly raises InferenceError.
Severity
The vulnerable ONNX component processes the malicious model through a local library API or file boundary and is not itself bound to a network stack. Applications that expose ONNX model processing over a network should calculate an Environmental score with Modified Attack Vector set to Network.
{
"affected": [
{
"database_specific": {
"last_known_affected_version_range": "\u003c= 1.21.0"
},
"package": {
"ecosystem": "PyPI",
"name": "onnx"
},
"ranges": [
{
"events": [
{
"introduced": "0"
},
{
"fixed": "1.22.0"
}
],
"type": "ECOSYSTEM"
}
]
}
],
"aliases": [
"CVE-2026-115919"
],
"database_specific": {
"cwe_ids": [
"CWE-125"
],
"github_reviewed": true,
"github_reviewed_at": "2026-10-28T21:16:24Z",
"nvd_published_at": "2026-10-26T18:17:39Z",
"severity": "MODERATE"
},
"details": "## Summary\n\nONNX shape inference performed an out-of-bounds read when processing a malformed RNN, GRU, or LSTM node from opsets 1\u20136 whose first input had a rank other than three.\n\n`RNNShapeInference_opset1_to_6()` checked whether the input shape was present but accessed `dim(0)` and `dim(1)` without first checking its rank. A crafted model could therefore terminate a process that called `onnx.shape_inference.infer_shapes()`. The model passed `onnx.checker.check_model()` before reaching the vulnerable path.\n\n## Technical details\n\nThe vulnerable code read dimensions unconditionally:\n\n```cpp\nif (hasInputShape(ctx, 0)) {\n const auto\u0026 first_input_shape = getInputShape(ctx, 0);\n seq_length = first_input_shape.dim(0);\n batch_size = first_input_shape.dim(1);\n}\n```\n\nFor an undersized shape, protobuf\u0027s repeated-field access read outside the intended array in release builds. The observed result was SIGSEGV; sanitizer and debug builds terminated on a protobuf bounds check.\n\nThe newer opset 7\u201313 and opset 14+ inference paths already required the first input to have rank three and were not affected.\n\n## Impact\n\nAn application that performs shape inference on an untrusted model can be terminated, causing denial of service. Exploitation does not require privileges or human interaction once the model is processed. No confidentiality or integrity impact was demonstrated.\n\n## Affected versions\n\n- Affected: ONNX through 1.21.0\n- Patched: ONNX 1.22.0\n\nThe vulnerable schemas are limited to RNN and LSTM opsets 1\u20136 and GRU opsets 3\u20136.\n\n## Remediation\n\nUpgrade to ONNX 1.22.0 or later. The fix validates that the first input has rank three before accessing its dimensions.\n\n- Fix: [onnx/onnx#7879](https://github.com/onnx/onnx/pull/7879)\n- Commit: [`92e541266`](https://github.com/onnx/onnx/commit/92e541266af5dd38cfa48aeb92206f4268a066cd)\n\nThe original malformed model was also re-tested against the published ONNX 1.23.2 wheel and correctly raises `InferenceError`.\n\n## Severity\n\nThe vulnerable ONNX component processes the malicious model through a local library API or file boundary and is not itself bound to a network stack. Applications that expose ONNX model processing over a network should calculate an Environmental score with Modified Attack Vector set to Network.",
"id": "GHSA-48m4-24cq-37qf",
"modified": "2026-10-28T21:16:24Z",
"published": "2026-10-28T21:16:24Z",
"references": [
{
"type": "WEB",
"url": "https://github.com/onnx/onnx/security/advisories/GHSA-48m4-24cq-37qf"
},
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2026-115919"
},
{
"type": "WEB",
"url": "https://github.com/onnx/onnx/pull/7879"
},
{
"type": "WEB",
"url": "https://github.com/onnx/onnx/commit/92e541266af5dd38cfa48aeb92206f4268a066cd"
},
{
"type": "PACKAGE",
"url": "https://github.com/onnx/onnx"
},
{
"type": "WEB",
"url": "https://github.com/onnx/onnx/releases/tag/v1.22.0"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.1/AV:L/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H",
"type": "CVSS_V3"
}
],
"summary": "ONNX: Out-of-Bounds Read in RNN/GRU/LSTM Shape Inference (Old Opsets, Missing Rank Check)"
}
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.