CVE-2022-23568: Integer Overflow Vulnerability in TensorFlow

tensorflow-cpu Updated 02 Oct 2025

Summary

03/02/2022
Yes i
Unrated
Not published

CVE-2022-23568: Tensorflow is an Open Source Machine Learning Framework. Affects tensorflow-cpu across 4 version ranges.

< 2.5.3 >= 2.6.0, < 2.6.3 < a68f68061e263a88321c104a6c911fe5598050a8 < b51b82fe65ebace4475e3c54eb089c18a4403f1c

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

Also tracked for

The same CVE-2022-23568 is tracked separately for each ecosystem and vendor. Its fix information is the same; the package and affected versions differ.

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

Sponsored Devnack Your last release was probably never penetration tested Manual testing by engineers who build software, not an auditor's checklist. Trusted by teams at Swift and Google Talk to Devnack

Background

TensorFlow is an open-source machine learning framework widely used for developing and training machine learning models. It provides a comprehensive set of tools and libraries for building and deploying machine learning applications. TensorFlow supports various platforms and is known for its scalability and flexibility. However, a vulnerability has been discovered in the implementation of the AddManySparseToTensorsMap function, which can lead to an integer overflow and subsequent denial of service (DoS) attack. This vulnerability affects the TensorFlow package versions 0 to 2.5.3, 2.6.0 to 2.6.3, and 2.7.1, and has been fixed in TensorFlow 2.8.0.

Vulnerability Detail

The vulnerability arises due to missing validation on the shapes of input tensors and the direct construction of a large TensorShape object with user-provided dimensions. This oversight allows an attacker to trigger an integer overflow, resulting in a CHECK-fail when building new TensorShape objects. An attacker can exploit this vulnerability to cause a denial of service by crashing the application. The impact of this vulnerability can be severe, as it can disrupt the availability of machine learning applications and potentially lead to financial losses or data breaches.

How To Fix

Latest published version: 2.21.0 as of 22 Oct 2026

pip install --upgrade "tensorflow-cpu==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-cpu==2.5.3"
  • >= 2.6.0, < 2.6.3 2.6.3
    pip install --upgrade "tensorflow-cpu==2.6.3"

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

Workaround

There is no specific workaround provided for this vulnerability. The recommended approach is to update the TensorFlow package to the latest patched version.

Conclusion

The integer overflow vulnerability in TensorFlow can lead to a denial of service (DoS) attack and potential disruption of machine learning applications. It is crucial to update the TensorFlow package to the latest patched version or apply the provided patches to mitigate the risk. For further support and assistance in vulnerability remediation, please contact DevNack.com.

See every vulnerability recorded for tensorflow-cpu →

Share this vulnerability

FAQ

TensorFlow is an open-source machine learning framework used for developing and training machine learning models.

The vulnerability can lead to a denial of service (DoS) attack, potentially disrupting the availability of machine learning applications.

The vulnerability affects TensorFlow versions 0 to 2.5.3, 2.6.0 to 2.6.3, and 2.7.1.

Yes, the vulnerability has been fixed in TensorFlow 2.8.0. Patches have also been released for TensorFlow 2.7.1, TensorFlow 2.6.3, and TensorFlow 2.5.3.

To mitigate the risk, it is recommended to update your TensorFlow installation to the latest patched version.

Related vulnerabilities

Recent vulnerabilities recorded for tensorflow-cpu.

How To Fix

Latest published version: 2.21.0 as of 22 Oct 2026

pip install --upgrade "tensorflow-cpu==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-cpu==2.5.3"
  • >= 2.6.0, < 2.6.3 2.6.3
    pip install --upgrade "tensorflow-cpu==2.6.3"

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