🔍 CVE-2021-29571

4.5
CVSS Score
MEDIUM
2021-05-14
2026-06-17 03:47
✅ 완료

🇰🇷 한글 설명

TensorFlow의 `tf.raw_ops.MaxPoolGradWithArgmax` 구현에서 입력값 검증 미흡으로 인해 힙 할당 데이터의 경계를 벗어난 읽기/쓰기가 발생할 수 있는 취약점입니다. 공격자가 조작된 입력을 제공할 경우 메모리 오염을 유발할 수 있습니다.

💡 쉬운 설명

TensorFlow라는 인공지능 도구에서 데이터의 크기를 제대로 확인하지 않아 발생하는 오류입니다. 나쁜 의도를 가진 사람이 특수한 데이터를 넣으면 컴퓨터의 메모리 영역을 침범하여 프로그램을 망가뜨릴 수 있습니다.

🇺🇸 원문 (English)

TensorFlow is an end-to-end open source platform for machine learning. The implementation of `tf.raw_ops.MaxPoolGradWithArgmax` can cause reads outside of bounds of heap allocated data if attacker supplies specially crafted inputs. The implementation(https://github.com/tensorflow/tensorflow/blob/31bd5026304677faa8a0b77602c6154171b9aec1/tensorflow/core/kernels/image/draw_bounding_box_op.cc#L116-L130) assumes that the last element of `boxes` input is 4, as required by [the op](https://www.tensorflow.org/api_docs/python/tf/raw_ops/DrawBoundingBoxesV2). Since this is not checked attackers passing values less than 4 can write outside of bounds of heap allocated objects and cause memory corruption. If the last dimension in `boxes` is less than 4, accesses similar to `tboxes(b, bb, 3)` will access data outside of bounds. Further during code execution there are also writes to these indices. 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 포함)

⚔️ 공격 벡터

조작된 입력값(boxes의 마지막 차원이 4 미만인 값)을 전달하여 메모리 경계 외 영역에 접근

🛡️ 대응 방법

TensorFlow를 2.5.0 이상 버전으로 업데이트하거나, 지원되는 최신 패치 버전(2.4.2, 2.3.3 등)으로 업데이트하십시오.

🔧 검증 코드

출력된 버전 번호가 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:L/I:L/A:L

💻 영향받는 소프트웨어

Azure Machine Learning