CVE-2021-29610

Low

Description

TensorFlow is an end-to-end open source platform for machine learning. The validation in `tf.raw_ops.QuantizeAndDequantizeV2` allows invalid values for `axis` argument:. The validation(https://github.com/tensorflow/tensorflow/blob/eccb7ec454e6617738554a255d77f08e60ee0808/tensorflow/core/kernels/quantize_and_dequantize_op.cc#L74-L77) uses `||` to mix two different conditions. If `axis_ < -1` the condition in `OP_REQUIRES` will still be true, but this value of `axis_` results in heap underflow. This allows attackers to read/write to other data on the heap. The fix will be included in TensorFlow 2.5.0. We will also cherrypick this commit on TensorFlow 2.4.2, TensorFlow 2.3.3, TensorFlow 2.2.3 and TensorFlow 2.1.4, as these are also affected and still in supported range.

SeverityLow
CVSS3.6
Exploit probability—
ProductGoogle Tensorflow
PublishedMay 14, 2021
First seenMay 14, 2021
Weakness typeCWE-665CWE-665

How to fix

Update
  • google tensorflow2.1.4, 2.2.3, 2.3.3, 2.4.2 or later
  • tensorflow2.1.4, 2.2.3, 2.3.3, 2.4.2, 2.2.0rc0, 2.3.0rc0, 2.3.4, 2.4.3 or later
  • tensorflow-cpu2.1.4, 2.2.3, 2.3.3, 2.4.2, 2.2.0rc0, 2.3.0rc0, 2.3.4, 2.4.3 or later
  • tensorflow-gpu2.1.4, 2.2.3, 2.3.3, 2.4.2, 2.2.0rc0, 2.3.0rc0, 2.3.4, 2.4.3 or later

Affected products

ProductAffected versionsFixed in
google tensorflowv < 2.1.4, 2.2.0 ≤ v < 2.2.3, 2.3.0 ≤ v < 2.3.3, 2.4.0 ≤ v < 2.4.22.1.4, 2.2.3, 2.3.3, 2.4.2
tensorflowPyPIv < 2.1.4, 2.2.0 ≤ v < 2.2.3, 2.3.0 ≤ v < 2.3.3, 2.4.0 ≤ v < 2.4.2, v < 2.2.0rc0, 2.2.0 ≤ v < 2.3.0rc0, 2.3.0 ≤ v < 2.3.4, 2.4.0 ≤ v < 2.4.32.1.4, 2.2.3, 2.3.3, 2.4.2, 2.2.0rc0, 2.3.0rc0, 2.3.4, 2.4.3
tensorflow-cpuPyPIv < 2.1.4, 2.2.0 ≤ v < 2.2.3, 2.3.0 ≤ v < 2.3.3, 2.4.0 ≤ v < 2.4.2, v < 2.2.0rc0, 2.2.0 ≤ v < 2.3.0rc0, 2.3.0 ≤ v < 2.3.4, 2.4.0 ≤ v < 2.4.32.1.4, 2.2.3, 2.3.3, 2.4.2, 2.2.0rc0, 2.3.0rc0, 2.3.4, 2.4.3
tensorflow-gpuPyPIv < 2.1.4, 2.2.0 ≤ v < 2.2.3, 2.3.0 ≤ v < 2.3.3, 2.4.0 ≤ v < 2.4.2, v < 2.2.0rc0, 2.2.0 ≤ v < 2.3.0rc0, 2.3.0 ≤ v < 2.3.4, 2.4.0 ≤ v < 2.4.32.1.4, 2.2.3, 2.3.3, 2.4.2, 2.2.0rc0, 2.3.0rc0, 2.3.4, 2.4.3

Check your version

Choose the product and enter the version you run to see whether it falls in the affected range.

In the Intelligence 360 plan

Attack Surface Management

See the assets tied to your domains, the technologies they run and known vulnerabilities in one list.