CVE-2021-37663
Incomplete validation in `QuantizeV2` in TensorFlow
Severity Score
Exploit Likelihood
Affected Versions
Public Exploits
0Exploited in Wild
-Decision
Descriptions
TensorFlow is an end-to-end open source platform for machine learning. In affected versions due to incomplete validation in `tf.raw_ops.QuantizeV2`, an attacker can trigger undefined behavior via binding a reference to a null pointer or can access data outside the bounds of heap allocated arrays. The [implementation](https://github.com/tensorflow/tensorflow/blob/84d053187cb80d975ef2b9684d4b61981bca0c41/tensorflow/core/kernels/quantize_op.cc#L59) has some validation but does not check that `min_range` and `max_range` both have the same non-zero number of elements. If `axis` is provided (i.e., not `-1`), then validation should check that it is a value in range for the rank of `input` tensor and then the lengths of `min_range` and `max_range` inputs match the `axis` dimension of the `input` tensor. We have patched the issue in GitHub commit 6da6620efad397c85493b8f8667b821403516708. 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.
TensorFlow es una plataforma de código abierto de extremo a extremo para el aprendizaje automático. En las versiones afectadas debido a una comprobación incompleta en "tf.raw_ops.QuantizeV2", un atacante puede desencadenar un comportamiento indefinido vinculando una referencia a un puntero null o puede acceder a datos fuera de límites de las matrices asignadas a la pila. La [implementación] (https://github.com/tensorflow/tensorflow/blob/84d053187cb80d975ef2b9684d4b61981bca0c41/tensorflow/core/kernels/quantize_op.cc#L59) presenta alguna comprobación, pero no comprueba que "min_range" y" max_range" tengan el mismo número de elementos distinto de cero. Si se proporciona "axis" (es decir, no" -1"), entonces la comprobación debe verificar que sea un valor en el rango para el rango del tensor de "input" y luego las longitudes de las entradas de" min_range" y "max_range" coincidan con las Dimensión "axis" del tensor" input". Hemos solucionado el problema en GitHub commit 6da6620efad397c85493b8f8667b821403516708. La corrección será incluida en TensorFlow versión 2.6.0. También seleccionaremos este commit en TensorFlow versión 2.5.1, TensorFlow versión 2.4.3 y TensorFlow versión 2.3.4, ya que estos también están afectados y aún se encuentran en el rango admitido.
CVSS Scores
SSVC
- Decision:-
Timeline
- 2021-07-29 CVE Reserved
- 2021-08-12 CVE Published
- 2023-03-08 EPSS Updated
- 2024-08-04 CVE Updated
- ---------- Exploited in Wild
- ---------- KEV Due Date
- ---------- First Exploit
CWE
- CWE-20: Improper Input Validation
CAPEC
References (2)
URL | Tag | Source |
---|---|---|
https://github.com/tensorflow/tensorflow/security/advisories/GHSA-g25h-jr74-qp5j | Third Party Advisory |
URL | Date | SRC |
---|
URL | Date | SRC |
---|---|---|
https://github.com/tensorflow/tensorflow/commit/6da6620efad397c85493b8f8667b821403516708 | 2021-08-19 |
URL | Date | SRC |
---|
Affected Vendors, Products, and Versions
Vendor | Product | Version | Other | Status | ||||||
---|---|---|---|---|---|---|---|---|---|---|
Vendor | Product | Version | Other | Status | <-- --> | Vendor | Product | Version | Other | Status |
Google Search vendor "Google" | Tensorflow Search vendor "Google" for product "Tensorflow" | >= 2.3.0 < 2.3.4 Search vendor "Google" for product "Tensorflow" and version " >= 2.3.0 < 2.3.4" | - |
Affected
| ||||||
Google Search vendor "Google" | Tensorflow Search vendor "Google" for product "Tensorflow" | >= 2.4.0 < 2.4.3 Search vendor "Google" for product "Tensorflow" and version " >= 2.4.0 < 2.4.3" | - |
Affected
| ||||||
Google Search vendor "Google" | Tensorflow Search vendor "Google" for product "Tensorflow" | 2.5.0 Search vendor "Google" for product "Tensorflow" and version "2.5.0" | - |
Affected
| ||||||
Google Search vendor "Google" | Tensorflow Search vendor "Google" for product "Tensorflow" | 2.6.0 Search vendor "Google" for product "Tensorflow" and version "2.6.0" | rc0 |
Affected
| ||||||
Google Search vendor "Google" | Tensorflow Search vendor "Google" for product "Tensorflow" | 2.6.0 Search vendor "Google" for product "Tensorflow" and version "2.6.0" | rc1 |
Affected
| ||||||
Google Search vendor "Google" | Tensorflow Search vendor "Google" for product "Tensorflow" | 2.6.0 Search vendor "Google" for product "Tensorflow" and version "2.6.0" | rc2 |
Affected
|