🔍 CVE-2021-37690

6.6
CVSS Score
MEDIUM
2021-08-13
2026-06-17 04:00
✅ 완료

🇰🇷 한글 설명

TensorFlow의 특정 shape 함수 실행 시 `ShapeAndType` 구조체에서 추가 정보가 생성되는데, 이 정보가 즉시 삭제되는 추론 컨텍스트에 종속되어 발생합니다. 상위 코드에서 이 정보에 접근하려고 하면 세그멘테이션 오류(segfault)가 발생할 수 있는 취약점입니다.

💡 쉬운 설명

프로그램이 사용 중인 데이터를 너무 빨리 삭제해버려서, 나중에 그 데이터를 다시 쓰려고 할 때 프로그램이 갑자기 멈추거나 꺼지는 문제입니다. 데이터의 위치를 가리키는 주소가 잘못되어 발생하는 오류입니다.

🇺🇸 원문 (English)

TensorFlow is an end-to-end open source platform for machine learning. In affected versions when running shape functions, some functions (such as `MutableHashTableShape`) produce extra output information in the form of a `ShapeAndType` struct. The shapes embedded in this struct are owned by an inference context that is cleaned up almost immediately; if the upstream code attempts to access this shape information, it can trigger a segfault. `ShapeRefiner` is mitigating this for normal output shapes by cloning them (and thus putting the newly created shape under ownership of an inference context that will not die), but we were not doing the same for shapes and types. This commit fixes that by doing similar logic on output shapes and types. We have patched the issue in GitHub commit ee119d4a498979525046fba1c3dd3f13a039fbb1. 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 2.6.0 미만 버전 (2.5.1, 2.4.3, 2.3.4 포함)

⚔️ 공격 벡터

특정 shape 함수를 호출하는 악의적인 모델이나 입력 데이터를 통해 프로그램의 비정상 종료(DoS) 유도

🛡️ 대응 방법

TensorFlow를 2.6.0 이상 버전으로 업데이트하거나, 패치가 적용된 2.5.1, 2.4.3, 2.3.4 버전으로 업데이트

🔧 검증 코드

출력된 버전이 2.6.0 미만인 경우 해당 취약점에 노출된 상태입니다.

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

📊 CVSS Vector String

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

💻 영향받는 소프트웨어

Azure Machine Learning