🔍 CVE-2021-29584

2.5
CVSS Score
LOW
2021-05-14
2026-06-17 03:47
✅ 완료

🇰🇷 한글 설명

TensorFlow에서 새로운 텐서 모양을 생성할 때 정수 오버플로가 발생하여 서비스 거부(DoS)를 유발할 수 있는 취약점입니다. 특정 구현에서 차원 크기를 검증하지 않고 밀집 형태를 구축하기 때문에 발생하며, 이는 CHECK 실패를 유도하여 프로그램을 중단시킵니다.

💡 쉬운 설명

데이터의 크기를 계산하는 과정에서 숫자가 너무 커져 오류가 발생하는 문제입니다. 이 오류가 발생하면 프로그램이 갑자기 멈춰버려 서비스를 이용할 수 없게 됩니다.

🇺🇸 원문 (English)

TensorFlow is an end-to-end open source platform for machine learning. An attacker can trigger a denial of service via a `CHECK`-fail in caused by an integer overflow in constructing a new tensor shape. This is because the implementation(https://github.com/tensorflow/tensorflow/blob/0908c2f2397c099338b901b067f6495a5b96760b/tensorflow/core/kernels/sparse_split_op.cc#L66-L70) builds a dense shape without checking that the dimensions would not result in overflow. The `TensorShape` constructor(https://github.com/tensorflow/tensorflow/blob/6f9896890c4c703ae0a0845394086e2e1e523299/tensorflow/core/framework/tensor_shape.cc#L183-L188) uses a `CHECK` operation which triggers when `InitDims`(https://github.com/tensorflow/tensorflow/blob/6f9896890c4c703ae0a0845394086e2e1e523299/tensorflow/core/framework/tensor_shape.cc#L212-L296) returns a non-OK status. This is a legacy implementation of the constructor and operations should use `BuildTensorShapeBase` or `AddDimWithStatus` to prevent `CHECK`-failures in the presence of overflows. 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.

📍 영향받는 시스템

TensorFlow 2.5.0 미만 버전 (2.4.2, 2.3.3, 2.2.3, 2.1.4 포함)

⚔️ 공격 벡터

조작된 텐서 모양(Tensor Shape) 데이터를 입력하여 정수 오버플로를 유도함

🛡️ 대응 방법

TensorFlow를 2.5.0 이상의 최신 버전으로 업데이트하거나 보안 패치가 적용된 버전으로 업그레이드함

🔧 검증 코드

출력된 버전 번호가 2.5.0 미만인지 확인하여 취약 여부를 판단함

Shell / Script
python3 -c 'import tensorflow as tf; print(tf.__version__)'

📊 CVSS Vector String

CVSS Vector
CVSS:3.1/AV:L/AC:H/PR:L/UI:N/S:U/C:N/I:N/A:L

💻 영향받는 소프트웨어

Azure Machine Learning