Quick answers
- Is CVE-2021-37644 exploited in the wild?
- No. Junglewise Threat Intelligence has no report of CVE-2021-37644 being exploited in the wild.
- How severe is CVE-2021-37644?
- Low severity, with a CVSS score of 3.1, published 12 August 2021.
- Which products and versions are affected?
- Google TensorFlow < 2.6.0; fixed in 2.3.4, 2.4.3, 2.5.1, 2.6.0+; tensorflow (PyPI) GIT:introduced=0,fixed=8a6e874437670045e6c7dc6154c7412b4a2135e2|ECOSYSTEM:introduced=2.3.0,fixed=2.3.4,introduced=2.4.0,fixed=2.4.3; tensorflow-cpu (PyPI) GIT:introduced=0,fixed=8a6e874437670045e6c7dc6154c7412b4a2135e2|ECOSYSTEM:introduced=2.3.0,fixed=2.3.4,introduced=2.4.0,fixed=2.4.3; tensorflow-gpu (PyPI) GIT:introduced=0,fixed=8a6e874437670045e6c7dc6154c7412b4a2135e2|ECOSYSTEM:introduced=2.3.0,fixed=2.3.4,introduced=2.4.0,fixed=2.4.3.
- Is there a fix for CVE-2021-37644?
- Yes. tensorflow (PyPI): upgrade to 2.4.3 or later; tensorflow-cpu (PyPI): upgrade to 2.4.3 or later; tensorflow-gpu (PyPI): upgrade to 2.4.3 or later. Junglewise finds every place you run it, drafts the upgrade and applies it once you approve.
- How is CVE-2021-37644 attacked?
- It is attacked with local access, in a software library.
- Am I affected by CVE-2021-37644?
- Check whether you run Google TensorFlow, tensorflow (PyPI), tensorflow-cpu (PyPI) or one of the others listed at an affected version. Junglewise does that check for you around the clock: connect your code, cloud and domains, and it matches new vulnerabilities like this one against what you actually run and tells you when one reaches you.
How to fix
- tensorflow (PyPI): upgrade to 2.4.3 or later
pip install "tensorflow>=2.4.3" - tensorflow-cpu (PyPI): upgrade to 2.4.3 or later
pip install "tensorflow-cpu>=2.4.3" - tensorflow-gpu (PyPI): upgrade to 2.4.3 or later
pip install "tensorflow-gpu>=2.4.3"
Technical details
The tf.raw_ops.TensorListReserve operation in TensorFlow performs an unchecked std::vector.resize() call with a user-supplied num_elements parameter. An attacker providing a negative value triggers an abort condition in the C++ standard library. The vulnerability exists in versions prior to 2.6.0 (with cherry-picked fixes in 2.3.4, 2.4.3, and 2.5.1). Exploitation requires the ability to invoke TensorFlow operations with attacker-controlled input (local access or remote code execution capability in the application layer). The impact is a process crash (denial of service).
Affected products
- Google TensorFlow < 2.6.0; fixed in 2.3.4, 2.4.3, 2.5.1, 2.6.0+
- Google TensorFlow CPU < 2.3.4, 2.4.0–2.4.2, 2.5.0
- Google TensorFlow GPU < 2.3.4, 2.4.0–2.4.2, 2.5.0
Identifiers
- CVE-2021-37644
- GHSA-27j5-4p9v-pp67
- PYSEC-2021-266
- PYSEC-2021-557
- PYSEC-2021-755
Timeline
- 2021-08-11: disclosed
- 2021-08-25: patched: Fix included in TensorFlow 2.6.0 and cherry-picked to 2.3.4, 2.4.3, 2.5.1