CVE-2021-29544: TensorFlow - Denial of Service via CHECK-fail in QuantizeAndDequantizeV4Grad

tensorflow Updated 02 Oct 2025

Summary

06/03/2024
Yes i
Medium
Not published

CVE-2021-29544: CHECK-fail in QuantizeAndDequantizeV4Grad. Affects tensorflow versions >= 2.4.0, < 2.4.2. Fixed in 2.4.2. How to fix ↓

Also tracked for

The same CVE-2021-29544 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 MarkAI Find prospects already talking about the problem you solve AI watches the communities your customers use to find qualified prospects, then alerts you when a conversation is worth joining. See MarkAI

Background

TensorFlow is an end-to-end open source platform for machine learning. It provides a comprehensive ecosystem of tools, libraries, and resources for developing and deploying machine learning models. TensorFlow is widely used in various industries and research domains for tasks such as image recognition, natural language processing, and recommendation systems. However, a vulnerability has been discovered in TensorFlow that can lead to a denial of service attack.

Vulnerability Detail

The vulnerability exists in the tf.raw_ops.QuantizeAndDequantizeV4Grad function of TensorFlow. The implementation of this function does not properly validate the rank of the input tensors, allowing an attacker to trigger a CHECK failure. This can result in a denial of service by causing the program to terminate unexpectedly. The issue has been identified and a fix will be included in TensorFlow 2.5.0. The fix will also be backported to TensorFlow 2.4.2, which is the only other affected version.

How To Fix

Minimum fixed version

2.4.2

This is the first release that contains the fix.

Tip — Not sure which version your app runs? Vulert can match this fix to it. Scan free →

Workaround

There is no specific workaround mentioned for this vulnerability. However, users can mitigate the risk by following best practices for securing their TensorFlow deployments. This includes restricting access to TensorFlow APIs, implementing proper input validation, and monitoring for any suspicious activity or unexpected program terminations.

Conclusion

The vulnerability in TensorFlow can lead to a denial of service attack. It is important for users to update their TensorFlow installations to the latest version or apply the provided patch to ensure the security of their machine learning models. Regularly updating TensorFlow and other dependencies is crucial to protect against known vulnerabilities. For further support on vulnerability remediation, please contact DevNack.com.

See every vulnerability recorded for tensorflow →

Share this vulnerability

FAQ

TensorFlow is an open source platform for machine learning that provides tools and resources for developing and deploying machine learning models.

The vulnerability can be exploited to cause a denial of service attack by triggering a CHECK failure in TensorFlow.

The vulnerability affects TensorFlow versions 2.4.0 and 2.4.1. The issue has been fixed in TensorFlow 2.4.2 and will also be addressed in the upcoming TensorFlow 2.5.0 release.

To fix the vulnerability, it is recommended to update TensorFlow to version 2.5.0 or apply the patch provided in TensorFlow 2.4.2.

There are no specific workarounds mentioned for this vulnerability. However, users can mitigate the risk by following best practices for securing their TensorFlow deployments.

Related vulnerabilities

Recent vulnerabilities recorded for tensorflow.

How To Fix

Minimum fixed version

2.4.2

This is the first release that contains the fix.

Tip — Not sure which version your app runs? Vulert can match this fix to it. 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