Improper Validation of Integrity Check Value in TensorFlow

tensorflow Updated 02 Oct 2025

Summary

09/02/2022
HIGH
Yes i
High
7.0

GHSA-43q8-3fv7-pr5x: Improper Validation of Integrity Check Value in TensorFlow. Affects tensorflow across 3 version ranges.

< 2.5.3 >= 2.6.0, < 2.6.3 >= 2.7.0, < 2.7.1

Fixed in 2.5.3, 2.6.3 or 2.7.1, depending on the release line you run. How to fix ↓

Free scan

Check if this vulnerability affects your application

Upload a manifest or SBOM and we'll show whether you're affected, plus every other risky package in the same scan.

Check my app free

No signup required · Results in about 60 seconds

Upload your dependency manifest or SBOM

Drag & drop your file here or

Java Javascript PHP Python Go Rust Ruby Dart C/C++ Elixir CycloneDX SPDX

Upload a supported dependency manifest or SBOM. No installation or source-code access required.

See supported files and SBOM formats
SBOM sbom.json · bom.json · bom.xml · *.spdx.json · *.cdx.json · *.cdx.xml
Java pom.xml · gradle.lockfile · buildscript-gradle.lockfile
Javascript package-lock.json · yarn.lock · pnpm-lock.yaml
PHP composer.lock
Python poetry.lock · requirements.txt · Pipfile.lock
Go go.mod
Rust Cargo.lock
Ruby Gemfile.lock
Dart pubspec.lock
C/C++ conan.lock
Elixir mix.lock
Enter your work email to receive your report link.

Verify your email to view the full report and start 30 days of continuous monitoring. No credit card required.

Sponsored Lume, the Habilume companion Habilume Habit tracker with a companion that grows with you Complete habits, earn Lume Points, and watch your Lume grow as you stay consistent. App Store Google Play

Background

TensorFlow is an open-source machine learning framework developed by Google. It provides a comprehensive ecosystem of tools, libraries, and resources for building and deploying machine learning models. TensorFlow is widely used in various domains, including research, industry, and academia. However, a vulnerability has been discovered in TensorFlow that could potentially lead to a denial of service attack or a heap out-of-bounds read.

Vulnerability Detail

The vulnerability in TensorFlow arises from the improper validation of the integrity check value in the implementation of tf.sparse.split. This function does not fully validate the input arguments, allowing a malicious user to trigger a denial of service attack or a heap out-of-bounds read. The vulnerability can be exploited by passing a non-scalar value for the axis parameter. This vulnerability is similar to a previously reported issue (TFSA-2021-190, CVE-2021-41206). The impact of this vulnerability can be severe, potentially leading to crashes, data corruption, or unauthorized access to sensitive information.

How To Fix

Latest published version: 2.21.0 as of 22 Oct 2026

pip install --upgrade "tensorflow==2.21.0"

Upgrading to it may include breaking changes; the versions below are the minimum fixed release for this vulnerability.

If you can't move to the latest

The minimum fixed version depends on the release line you run.

  • < 2.5.3 2.5.3
    pip install --upgrade "tensorflow==2.5.3"
  • >= 2.6.0, < 2.6.3 2.6.3
    pip install --upgrade "tensorflow==2.6.3"
  • >= 2.7.0, < 2.7.1 2.7.1
    pip install --upgrade "tensorflow==2.7.1"

Tip — Not sure which release line you're on? Vulert can find the fix for the version you are using. Scan free →

Workaround

As a temporary workaround, users can avoid passing non-scalar values for the axis parameter in the tf.sparse.split function. By ensuring that axis is always a scalar, the vulnerability can be mitigated. Here is an example of how to use the function with a scalar axis value:

import tensorflow as tf
data = tf.random.uniform([1, 32, 32], dtype=tf.float32)
axis = 1
x = tf.sparse.from_dense(data)
result = tf.sparse.split(x, 3, axis=axis)

By following this workaround, the risk of exploitation can be reduced until the TensorFlow installation is updated to a patched version.

Conclusion

The vulnerability in TensorFlow's tf.sparse.split function can lead to a denial of service attack or a heap out-of-bounds read. It is crucial to update your TensorFlow installation to the latest version or the respective patched versions to mitigate this vulnerability. Additionally, following the provided workaround can reduce the risk of exploitation. If you have any further questions or need assistance with vulnerability remediation, please contact DevNack.com.

See every vulnerability recorded for tensorflow →

Share this vulnerability

FAQ

TensorFlow is an open-source machine learning framework developed by Google. It provides a comprehensive ecosystem of tools, libraries, and resources for building and deploying machine learning models.

The vulnerability can lead to a denial of service attack or a heap out-of-bounds read. This can result in crashes, data corruption, or unauthorized access to sensitive information.

To fix the vulnerability, update your TensorFlow installation to version 2.8.0 or later. If you are using an older version, update to the respective patched versions (2.7.1, 2.6.3, or 2.5.3). Regularly updating TensorFlow is recommended to ensure the latest security patches are applied.

Yes, as a temporary workaround, avoid passing non-scalar values for the axis parameter in the tf.sparse.split function. By ensuring that axis is always a scalar, the vulnerability can be mitigated.

You can use Vulert, a vulnerability monitoring tool, to check if your application is affected by this vulnerability. Vulert analyzes your Pipfile.lock file and provides real-time alerts for open-source vulnerabilities.

Related vulnerabilities

Recent vulnerabilities recorded for tensorflow.

Sponsored Lume, the Habilume companion Habilume Habit tracker with a companion that grows with you Complete habits, earn Lume Points, and watch your Lume grow as you stay consistent. App Store Google Play

How To Fix

Latest published version: 2.21.0 as of 22 Oct 2026

pip install --upgrade "tensorflow==2.21.0"

Upgrading to it may include breaking changes; the versions below are the minimum fixed release for this vulnerability.

If you can't move to the latest

The minimum fixed version depends on the release line you run.

  • < 2.5.3 2.5.3
    pip install --upgrade "tensorflow==2.5.3"
  • >= 2.6.0, < 2.6.3 2.6.3
    pip install --upgrade "tensorflow==2.6.3"
  • >= 2.7.0, < 2.7.1 2.7.1
    pip install --upgrade "tensorflow==2.7.1"

Tip — Not sure which release line you're on? Vulert can find the fix for the version you are using. Scan free →

Subscribe to Vulert on Telegram
Daily digest of new CVEs, critical and high severity, affected packages and fixes — plus a weekly roundup.
Join the channel →
Help improve this record
Report an issue or send feedback