CVE-2022-23588: TensorFlow: DoS via crafted SavedModel crashes Grappler

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

If your ML pipelines load SavedModels from untrusted or user-supplied sources, this is an exploitable crash. An attacker with low privileges who can submit a SavedModel can take down your inference or training service. Patch to TF 2.8.0 / 2.7.1 / 2.6.3 / 2.5.3 and restrict who can submit models for loading.

What is the risk?

Medium severity but operationally significant for exposed model-serving endpoints. CVSS 6.5 with network-accessible, low-complexity exploitation requiring only low privileges makes this achievable by any authenticated user or insider. No code execution or data exfiltration, but availability impact is high — a single malformed SavedModel triggers an unrecoverable process crash. Risk escalates in multi-tenant model serving platforms or CI/CD pipelines that automatically load externally sourced models.

What systems are affected?

Package Ecosystem Vulnerable Range Patched
TensorFlow pip No patch
195.8K OpenSSF 7.1 3.7K dependents Pushed 2d ago 4% patched ~1372d to patch Full package profile →

Do you use TensorFlow? You're affected.

How severe is it?

CVSS 3.1
6.5 / 10
EPSS
0.9%
chance of exploitation in 30 days
Higher than 53% 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, VulnCheck KEV, CISA SSVC, EPSS, Metasploit, Exploit-DB, trickest/cve, Nuclei templates, and inthewild.io exploitation reports.

What is the 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

What should I do?

5 steps
  1. PATCH

    Upgrade to TensorFlow 2.8.0, 2.7.1, 2.6.3, or 2.5.3 immediately.

  2. RESTRICT

    Enforce strict provenance controls on SavedModel ingestion — only load models from cryptographically signed, internal sources.

  3. SANDBOX

    Run model loading in isolated processes or containers so a crash does not bring down the entire inference service.

  4. VALIDATE

    Add pre-load integrity checks (hash verification, schema validation) before passing SavedModels to the optimizer.

  5. DETECT

    Monitor for unexpected TensorFlow process crashes or restarts in serving infrastructure — repeated crashes from the same model source are an IOC.

What does CISA's SSVC say?

Decision Track*
Exploitation poc
Automatable No
Technical Impact partial

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

How is it classified?

Which compliance frameworks are affected?

This CVE is relevant to:

EU AI Act
Art. 15 - Accuracy, robustness and cybersecurity
ISO 42001
6.1 - Actions to address risks and opportunities 8.1 - Operational planning and control
NIST AI RMF
MANAGE-2.2 - Mechanisms to sustain the value of deployed AI
OWASP LLM Top 10
LLM04 - Model Denial of Service LLM05 - Supply Chain Vulnerabilities

Frequently Asked Questions

What is CVE-2022-23588?

If your ML pipelines load SavedModels from untrusted or user-supplied sources, this is an exploitable crash. An attacker with low privileges who can submit a SavedModel can take down your inference or training service. Patch to TF 2.8.0 / 2.7.1 / 2.6.3 / 2.5.3 and restrict who can submit models for loading.

Is CVE-2022-23588 actively exploited?

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

How to fix CVE-2022-23588?

1. PATCH: Upgrade to TensorFlow 2.8.0, 2.7.1, 2.6.3, or 2.5.3 immediately. 2. RESTRICT: Enforce strict provenance controls on SavedModel ingestion — only load models from cryptographically signed, internal sources. 3. SANDBOX: Run model loading in isolated processes or containers so a crash does not bring down the entire inference service. 4. VALIDATE: Add pre-load integrity checks (hash verification, schema validation) before passing SavedModels to the optimizer. 5. DETECT: Monitor for unexpected TensorFlow process crashes or restarts in serving infrastructure — repeated crashes from the same model source are an IOC.

What systems are affected by CVE-2022-23588?

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

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

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

What is the AI security impact?

Affected AI Architectures

model servingtraining pipelinesML model registriesinference pipelines

MITRE ATLAS Techniques

AML.T0010.001 AI Software
AML.T0011.000 Unsafe AI Artifacts
AML.T0029 Denial of AI Service
AML.T0043 Craft Adversarial Data

Compliance Controls Affected

EU AI Act: Art. 15
ISO 42001: 6.1, 8.1
NIST AI RMF: MANAGE-2.2
OWASP LLM Top 10: LLM04, LLM05

What are the technical details?

Original Advisory

Tensorflow is an Open Source Machine Learning Framework. A malicious user can cause a denial of service by altering a `SavedModel` such that Grappler optimizer would attempt to build a tensor using a reference `dtype`. This would result in a crash due to a `CHECK`-fail in the `Tensor` constructor as reference types are not allowed. 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 adversary with a low-privilege account on a shared ML platform (e.g., a data scientist account on an internal model registry or a customer account on a multi-tenant MLaaS product) uploads a specially crafted SavedModel where the Grappler constant folding pass attempts to construct a Tensor with a reference dtype. When the platform's automated pipeline or inference server loads the model, TensorFlow hits a CHECK-fail assertion in tensor.cc and crashes. By automating re-uploads, the attacker maintains a persistent DoS against the serving endpoint without any elevated privileges.

Weaknesses (CWE)

CWE-617 — Reachable Assertion: The product contains an assert() or similar statement that can be triggered by an attacker, which leads to an application exit or other behavior that is more severe than necessary.

  • [Implementation] Make sensitive open/close operation non reachable by directly user-controlled data (e.g. open/close resources)
  • [Implementation] Perform input validation on user data.

Source: MITRE CWE corpus.

CVSS Vector

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

Timeline

Published
February 4, 2022
Last Modified
November 21, 2024
First Seen
February 4, 2022

Related Vulnerabilities