CVE-2021-37673: `CHECK`-fail in `MapStage` in TensorFlow
Impact An attacker can trigger a denial of service via a CHECK-fail in tf.rawops.MapStage:
python import tensorflow as tf tf.rawops.MapStage( key=tf.constant([], shape=[0, 0, 0, 0], dtype=tf.int64), indices=tf.constant((0), dtype=tf.int32), values=[tf.constant((0), dtype=tf.int32)], dtypes=[tf.int32, tf.int64], capacity=0, memorylimit=0, container='', sharedname='') The implementation does not check that the key input is a valid non-empty tensor. Patches We have patched the issue in GitHub commit d7de67733925de196ec8863a33445b73f9562d1d.
The fix will be included in TensorFlow 2.6.0. We will also cherrypick this commit on TensorFlow 2.5.1, TensorFlow 2.4.3, and TensorFlow 2.3.4, as these are also affected and still in supported range.
For more information Please consult our security guide for more information regarding the security model and how to contact us with issues and questions.
Attribution This vulnerability has been reported by Ying Wang and Yakun Zhang of Baidu X-Team.
Other sources
TensorFlow is an end-to-end open source platform for machine learning. In affected versions an attacker can trigger a denial of service via a CHECK-fail in tf.rawops.MapStage. The implementation does not check that the key input is a valid non-empty tensor. We have patched the issue in GitHub commit d7de67733925de196ec8863a33445b73f9562d1d. The fix will be included in TensorFlow 2.6.0. We will also cherrypick this commit on TensorFlow 2.5.1, TensorFlow 2.4.3, and TensorFlow 2.3.4, as these are also affected and still in supported range.
Affected Software
Remediation
Recommended actions to resolve this vulnerability, in priority order.
- Upgrade
Upgrade
pip/tensorflow-gputo a version that resolves this vulnerability.Fixed in 2.5.1 - Upgrade
Upgrade
pip/tensorflow-gputo a version that resolves this vulnerability.Fixed in 2.4.3 - Upgrade
Upgrade
pip/tensorflow-gputo a version that resolves this vulnerability.Fixed in 2.3.4 - Upgrade
Upgrade
pip/tensorflow-cputo a version that resolves this vulnerability.Fixed in 2.5.1 - Upgrade
Upgrade
pip/tensorflow-cputo a version that resolves this vulnerability.Fixed in 2.4.3 - Upgrade
Upgrade
pip/tensorflow-cputo a version that resolves this vulnerability.Fixed in 2.3.4 - Upgrade
Upgrade
pip/tensorflowto a version that resolves this vulnerability.Fixed in 2.5.1 - Upgrade
Upgrade
pip/tensorflowto a version that resolves this vulnerability.Fixed in 2.4.3 - Upgrade
Upgrade
pip/tensorflowto a version that resolves this vulnerability.Fixed in 2.3.4 - Upgrade
Upgrade
tensorflow/tensorflowto a version that resolves this vulnerability.Fixed in 2.6.0Patch GitHub commit d7de67733925de196ec8863a33445b73f9562d1d - Upgrade
Upgrade
tensorflow/tensorflowto a version that resolves this vulnerability.Fixed in 2.5.1Patch GitHub commit d7de67733925de196ec8863a33445b73f9562d1d - Upgrade
Upgrade
tensorflow/tensorflowto a version that resolves this vulnerability.Fixed in 2.4.3Patch GitHub commit d7de67733925de196ec8863a33445b73f9562d1d - Upgrade
Upgrade
tensorflow/tensorflowto a version that resolves this vulnerability.Fixed in 2.3.4Patch GitHub commit d7de67733925de196ec8863a33445b73f9562d1d
Event History
Frequently Asked Questions
What is the severity of CVE-2021-37673?
CVE-2021-37673 has been classified as a denial of service vulnerability.
How do I fix CVE-2021-37673?
To remediate CVE-2021-37673, upgrade to TensorFlow versions 2.3.4, 2.4.3, or 2.5.1.
What software is affected by CVE-2021-37673?
CVE-2021-37673 affects TensorFlow versions from 2.3.0 to 2.3.4, 2.4.0 to 2.4.3, and 2.5.0.
Can CVE-2021-37673 be exploited remotely?
Yes, CVE-2021-37673 can be exploited remotely to cause a denial of service.
What environment is vulnerable to CVE-2021-37673?
CVE-2021-37673 impacts environments using the specified vulnerable versions of TensorFlow.