CVE-2021-29537: Heap Buffer Overflow in TensorFlow
Summary
CVE-2021-29537: Heap buffer overflow in QuantizedResizeBilinear. 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-29537 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 developing and deploying machine learning models. TensorFlow is widely used in various industries and research fields.
Vulnerability Detail
The vulnerability identified as CVE-2021-29537 is a heap buffer overflow in the QuantizedResizeBilinear function of TensorFlow. This vulnerability can be exploited by an attacker by passing invalid thresholds for the quantization. The implementation assumes that the arguments are always valid scalars and tries to access the numeric value directly, leading to a heap buffer overflow. The impact of this vulnerability can be severe, potentially allowing an attacker to execute arbitrary code or cause a denial of service.
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
There is no specific workaround provided for this vulnerability. The recommended action is to apply the available patches or upgrade to the fixed versions of TensorFlow.
Conclusion
The identified vulnerability in TensorFlow can have severe consequences, including arbitrary code execution or denial of service. It is crucial to apply the available patches or upgrade to the fixed versions to mitigate the risk. For further support on vulnerability remediation, you can contact DevNack.com.
See every vulnerability recorded for tensorflow →
FAQ
TensorFlow is an open source platform for machine learning that provides tools and libraries for developing and deploying machine learning models.
This vulnerability can lead to a heap buffer overflow, which can be exploited by an attacker to execute arbitrary code or cause a denial of service.
The vulnerability affects TensorFlow versions 0 and 2.1.4 to 2.4.2. It has been fixed in TensorFlow 2.5.0 and backported to TensorFlow 2.4.2, TensorFlow 2.3.3, TensorFlow 2.2.3, and TensorFlow 2.1.4.
To fix this vulnerability, it is recommended to upgrade to TensorFlow 2.5.0 or later. If you are using an affected version, you should also consider updating to the fixed versions mentioned earlier.
There is no specific workaround provided for this vulnerability. Applying the available patches or upgrading to the fixed versions is the recommended action.
References
Related vulnerabilities
Recent vulnerabilities recorded for tensorflow.