CVE-2021-29582: TensorFlow - Heap-Based Read Out-of-Bounds in Dequantize
Summary
CVE-2021-29582: Heap OOB read in tf.raw_ops.Dequantize. Affects tensorflow across 4 version ranges.
< 2.1.4
>= 2.2.0, < 2.2.3
>= 2.3.0, < 2.3.3
>= 2.4.0, < 2.4.2
Fixed in 4 releases; the minimum fixed version depends on the release line you run. How to fix ↓
Also tracked for
- tensorflow · PyPI
- tensorflow · PyPI
- tensorflow-cpu · PyPI
- tensorflow-gpu · PyPI
The same CVE-2021-29582 is tracked separately for each ecosystem and vendor. Its fix information is the same; the package and affected versions differ.
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.
No signup required · Results in about 60 seconds
Background
TensorFlow is an end-to-end open source platform for machine learning. It provides a comprehensive ecosystem of tools, libraries, and resources for building and deploying machine learning models. TensorFlow is widely used in various industries and research domains.
Vulnerability Detail
The vulnerability (CVE-2021-29582) in TensorFlow arises from a lack of validation in the tf.raw_ops.Dequantize function. This vulnerability allows an attacker to trigger a read from outside the bounds of heap allocated data. The issue occurs due to the parallel access of the min_range and max_range tensors without verifying that they have the same shape. As a result, an attacker can exploit this flaw to read sensitive information or cause a denial of service. The vulnerability has been assigned a CVSSv3 score of 8.8 (High severity).
How To Fix
Fixed versions by release line
The minimum fixed version depends on the release line you run.
-
< 2.1.42.1.4 -
>= 2.2.0, < 2.2.32.2.3 -
>= 2.3.0, < 2.3.32.3.3 -
>= 2.4.0, < 2.4.22.4.2
Tip — Not sure which release line you're on? Vulert can find the fix for the version you are using. Scan free →
Workaround
No workaround has been provided for this vulnerability.
Conclusion
The vulnerability (CVE-2021-29582) in TensorFlow can be mitigated by upgrading to the latest available version. It is recommended to promptly update TensorFlow installations to ensure the security and stability of machine learning models. For further assistance or support in vulnerability remediation, please contact DevNack.com.
See every vulnerability recorded for tensorflow →
FAQ
TensorFlow is an open source platform for machine learning, widely used for building and deploying machine learning models.
This vulnerability allows an attacker to read data from outside the bounds of heap allocated memory, potentially leading to information disclosure or denial of service.
Versions 0.x, 2.1.4, 2.2.3, 2.3.3, and 2.4.2 of TensorFlow are affected by this vulnerability.
Yes, the vulnerability has been fixed in TensorFlow versions 2.5.0, 2.4.2, 2.3.3, 2.2.3, and 2.1.4.
To upgrade TensorFlow, follow the official upgrade guide provided by TensorFlow.
References
Related vulnerabilities
Recent vulnerabilities recorded for tensorflow.