CVE-2020-15204: Segfault in TensorFlow
Summary
CVE-2020-15204: Segfault in Tensorflow. Affects tensorflow across 5 version ranges.
< 1.15.4
>= 2.0.0, < 2.0.3
>= 2.1.0, < 2.1.2
>= 2.2.0, < 2.2.1
>= 2.3.0, < 2.3.1
Fixed in 5 releases; the minimum fixed version depends on the release line you run. How to fix ↓
Also tracked for
- tensorflow · Bitnami
- tensorflow-cpu · PyPI
- tensorflow-gpu · PyPI
The same CVE-2020-15204 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 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 supports both eager execution and graph execution modes, allowing developers to choose the most suitable approach for their projects. However, a vulnerability has been discovered in TensorFlow that can lead to a segmentation fault when certain operations are performed in eager mode.
Vulnerability Detail
The vulnerability in TensorFlow arises from the lack of session state setting in eager mode. When calling certain functions like tf.raw_ops.GetSessionHandle or tf.raw_ops.GetSessionHandleV2, a null pointer dereference occurs due to the absence of session state. This results in a segmentation fault. The issue has been identified in the tensorflow/core/kernels/session_ops.cc file. The vulnerability can be exploited by an attacker to crash the TensorFlow application, potentially leading to a denial of service (DoS) condition. The vulnerability has been assigned a CVSS score of 5.3, indicating a moderate severity level.
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.
-
< 1.15.41.15.4pip install --upgrade "tensorflow==1.15.4" -
>= 2.0.0, < 2.0.32.0.3pip install --upgrade "tensorflow==2.0.3" -
>= 2.1.0, < 2.1.22.1.2pip install --upgrade "tensorflow==2.1.2" -
>= 2.2.0, < 2.2.12.2.1pip install --upgrade "tensorflow==2.2.1" -
>= 2.3.0, < 2.3.12.3.1pip install --upgrade "tensorflow==2.3.1"
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 mentioned for this vulnerability. The recommended approach is to upgrade to the patched versions of TensorFlow.
Conclusion
The vulnerability in TensorFlow can lead to a segmentation fault and potential denial of service (DoS) condition. It is crucial to upgrade to the patched versions of TensorFlow to mitigate the risk. For further support and assistance with vulnerability remediation, please contact DevNack.com.
See every vulnerability recorded for tensorflow →
FAQ
TensorFlow is an open-source machine learning framework developed by Google. It provides tools and resources for building and deploying machine learning models.
The vulnerability can lead to a segmentation fault in TensorFlow, potentially causing a denial of service (DoS) condition.
To fix the vulnerability, it is recommended to upgrade to the patched versions of TensorFlow: 1.15.4, 2.0.3, 2.1.2, 2.2.1, or 2.3.1.
No specific workarounds have been mentioned for this vulnerability. Upgrading to the patched versions is the recommended solution.
This vulnerability was reported by members of the Aivul Team from Qihoo 360.
References
Related vulnerabilities
Recent vulnerabilities recorded for tensorflow.