// For flags

CVE-2022-41894

Buffer overflow in `CONV_3D_TRANSPOSE` on TFLite

Severity Score

8.1
*CVSS v3.1

Exploit Likelihood

*EPSS

Affected Versions

*CPE

Public Exploits

1
*Multiple Sources

Exploited in Wild

-
*KEV

Decision

-
*SSVC
Descriptions

TensorFlow is an open source platform for machine learning. The reference kernel of the `CONV_3D_TRANSPOSE` TensorFlow Lite operator wrongly increments the data_ptr when adding the bias to the result. Instead of `data_ptr += num_channels;` it should be `data_ptr += output_num_channels;` as if the number of input channels is different than the number of output channels, the wrong result will be returned and a buffer overflow will occur if num_channels > output_num_channels. An attacker can craft a model with a specific number of input channels. It is then possible to write specific values through the bias of the layer outside the bounds of the buffer. This attack only works if the reference kernel resolver is used in the interpreter. We have patched the issue in GitHub commit 72c0bdcb25305b0b36842d746cc61d72658d2941. The fix will be included in TensorFlow 2.11. We will also cherrypick this commit on TensorFlow 2.10.1, 2.9.3, and TensorFlow 2.8.4, as these are also affected and still in supported range.

TensorFlow es una plataforma de código abierto para aprendizaje automático. El núcleo de referencia del operador `CONV_3D_TRANSPOSE` de TensorFlow Lite incrementa erróneamente data_ptr al agregar el sesgo al resultado. En lugar de `data_ptr += num_channels;` debería ser `data_ptr += output_num_channels;` ya que si el número de canales de entrada es diferente al número de canales de salida, se devolverá un resultado incorrecto y se producirá un desbordamiento del búfer si num_channels > output_num_channels. Un atacante puede crear un modelo con un número específico de canales de entrada. Entonces es posible escribir valores específicos a través del sesgo de la capa fuera de los límites del búfer. Este ataque solo funciona si se utiliza el solucionador del núcleo de referencia en el intérprete. Hemos solucionado el problema en el compromiso de GitHub 72c0bdcb25305b0b36842d746cc61d72658d2941. La solución se incluirá en TensorFlow 2.11. También seleccionaremos este commit en TensorFlow 2.10.1, 2.9.3 y TensorFlow 2.8.4, ya que estos también se ven afectados y aún se encuentran en el rango admitido.

*Credits: N/A
CVSS Scores
Attack Vector
Network
Attack Complexity
High
Privileges Required
None
User Interaction
None
Scope
Unchanged
Confidentiality
High
Integrity
High
Availability
High
Attack Vector
Network
Attack Complexity
High
Privileges Required
Low
User Interaction
Required
Scope
Unchanged
Confidentiality
High
Integrity
High
Availability
High
* Common Vulnerability Scoring System
SSVC
  • Decision:-
Exploitation
-
Automatable
-
Tech. Impact
-
* Organization's Worst-case Scenario
Timeline
  • 2022-09-30 CVE Reserved
  • 2022-11-18 CVE Published
  • 2024-07-09 EPSS Updated
  • 2024-08-03 CVE Updated
  • 2024-08-03 First Exploit
  • ---------- Exploited in Wild
  • ---------- KEV Due Date
CWE
  • CWE-120: Buffer Copy without Checking Size of Input ('Classic Buffer Overflow')
CAPEC
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.8.4
Search vendor "Google" for product "Tensorflow" and version " < 2.8.4"
-
Affected
Google
Search vendor "Google"
Tensorflow
Search vendor "Google" for product "Tensorflow"
>= 2.9.0 < 2.9.3
Search vendor "Google" for product "Tensorflow" and version " >= 2.9.0 < 2.9.3"
-
Affected
Google
Search vendor "Google"
Tensorflow
Search vendor "Google" for product "Tensorflow"
>= 2.10.0 < 2.10.1
Search vendor "Google" for product "Tensorflow" and version " >= 2.10.0 < 2.10.1"
-
Affected