CVE-2022-23567: TensorFlow: integer overflow DoS in sparse tensor ops

MEDIUM PoC AVAILABLE CISA: TRACK*
Published February 3, 2022
CISO Take

This medium-severity flaw lets any authenticated user crash TensorFlow serving infrastructure via malformed sparse tensor inputs, causing OOM or process termination. Patch to TF 2.8.0, 2.7.1, 2.6.3, or 2.5.3 immediately if running shared or multi-tenant ML serving. No data exfiltration risk, but availability of ML pipelines is the exposure.

Risk Assessment

Medium risk in isolation, elevated in shared ML platform contexts. CVSS 6.5 reflects low-complexity network exploitation requiring only authenticated access. The DoS-only impact limits severity, but organizations running internal ML-as-a-service platforms or multi-tenant TensorFlow endpoints face meaningful availability risk from insider threats or compromised credentials. Not actively exploited and not in CISA KEV.

Affected Systems

Package Ecosystem Vulnerable Range Patched
tensorflow pip No patch
195.0K OpenSSF 7.2 3.7K dependents Pushed 6d ago 4% patched ~1372d to patch Full package profile →

Do you use tensorflow? You're affected.

Severity & Risk

CVSS 3.1
6.5 / 10
EPSS
0.4%
chance of exploitation in 30 days
Higher than 64% of all CVEs
Exploitation Status
Exploit Available
Exploitation: MEDIUM
Sophistication
Trivial
Exploitation Confidence
medium
CISA SSVC: Public PoC
Public PoC indexed (trickest/cve)
Composite signal derived from CISA KEV, CISA SSVC, EPSS, trickest/cve, and Nuclei templates.

Attack Surface

AV AC PR UI S C I A
AV Network
AC Low
PR Low
UI None
S Unchanged
C None
I None
A High

Recommended Action

5 steps
  1. Patch: Upgrade to TensorFlow 2.8.0, or backport versions 2.7.1, 2.6.3, or 2.5.3.

  2. Containment: Apply container memory limits (--memory flag in Docker) to bound OOM blast radius and prevent host-level impact.

  3. Access control: Restrict model inference endpoints to trusted identities; avoid exposing raw TF ops to untrusted users.

  4. Detection: Monitor for repeated process crashes or anomalous memory spikes in TF serving pods. Alert on OOM-kills in ML serving namespaces.

  5. Workaround (if patching delayed): Validate input tensor shapes and dimensions at the API gateway layer before forwarding to TF.

CISA SSVC Assessment

Decision Track*
Exploitation poc
Automatable No
Technical Impact partial

Source: CISA Vulnrichment (SSVC v2.0). Decision based on the CISA Coordinator decision tree.

Classification

Compliance Impact

This CVE is relevant to:

EU AI Act
Article 15 - Accuracy, robustness and cybersecurity
ISO 42001
A.6.2.6 - AI system robustness and availability
NIST AI RMF
MANAGE-2.2 - Mechanisms to sustain the value of AI systems over time
OWASP LLM Top 10
LLM10:2025 - Unbounded Consumption

Frequently Asked Questions

What is CVE-2022-23567?

This medium-severity flaw lets any authenticated user crash TensorFlow serving infrastructure via malformed sparse tensor inputs, causing OOM or process termination. Patch to TF 2.8.0, 2.7.1, 2.6.3, or 2.5.3 immediately if running shared or multi-tenant ML serving. No data exfiltration risk, but availability of ML pipelines is the exposure.

Is CVE-2022-23567 actively exploited?

Proof-of-concept exploit code is publicly available for CVE-2022-23567, increasing the risk of exploitation.

How to fix CVE-2022-23567?

1. Patch: Upgrade to TensorFlow 2.8.0, or backport versions 2.7.1, 2.6.3, or 2.5.3. 2. Containment: Apply container memory limits (--memory flag in Docker) to bound OOM blast radius and prevent host-level impact. 3. Access control: Restrict model inference endpoints to trusted identities; avoid exposing raw TF ops to untrusted users. 4. Detection: Monitor for repeated process crashes or anomalous memory spikes in TF serving pods. Alert on OOM-kills in ML serving namespaces. 5. Workaround (if patching delayed): Validate input tensor shapes and dimensions at the API gateway layer before forwarding to TF.

What systems are affected by CVE-2022-23567?

This vulnerability affects the following AI/ML architecture patterns: model serving, training pipelines, shared ML platforms, batch inference.

What is the CVSS score for CVE-2022-23567?

CVE-2022-23567 has a CVSS v3.1 base score of 6.5 (MEDIUM). The EPSS exploitation probability is 0.45%.

Technical Details

NVD Description

Tensorflow is an Open Source Machine Learning Framework. The implementations of `Sparse*Cwise*` ops are vulnerable to integer overflows. These can be used to trigger large allocations (so, OOM based denial of service) or `CHECK`-fails when building new `TensorShape` objects (so, assert failures based denial of service). We are missing some validation on the shapes of the input tensors as well as directly constructing a large `TensorShape` with user-provided dimensions. The fix will be included in TensorFlow 2.8.0. We will also cherrypick this commit on TensorFlow 2.7.1, TensorFlow 2.6.3, and TensorFlow 2.5.3, as these are also affected and still in supported range.

Exploitation Scenario

An insider or attacker with valid API credentials to a shared TensorFlow Model Server submits a crafted inference request containing sparse tensor inputs with pathological dimension values designed to trigger integer overflow in Sparse*Cwise* kernel allocation. The server allocates an enormous TensorShape or exhausts memory, crashing the process. In a Kubernetes-based ML platform, this forces a pod restart, disrupting all concurrent inference requests. The attacker repeats this in a loop to maintain denial of service. No privileged access or ML expertise required beyond knowing the target operation accepts sparse inputs.

CVSS Vector

CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H

Timeline

Published
February 3, 2022
Last Modified
May 5, 2025
First Seen
February 3, 2022

Related Vulnerabilities