🔍 CVE-2021-29541

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

🇰🇷 한글 설명

TensorFlow의 `tf.raw_ops.StringNGrams` 함수에서 `data_splits` 인자를 충분히 검증하지 않아 발생하는 결함입니다. 공격자가 특정 입력을 통해 출력 크기를 0 또는 음수로 만들면 널 포인터 역참조가 발생하여 프로그램이 비정상 종료될 수 있습니다.

💡 쉬운 설명

머신러닝 도구인 TensorFlow에서 잘못된 데이터를 입력하면 프로그램이 갑자기 꺼지는 오류가 발생할 수 있습니다. 이는 데이터 처리 과정에서 빈 공간을 잘못 참조하기 때문에 발생합니다.

🇺🇸 원문 (English)

TensorFlow is an end-to-end open source platform for machine learning. An attacker can trigger a dereference of a null pointer in `tf.raw_ops.StringNGrams`. This is because the implementation(https://github.com/tensorflow/tensorflow/blob/1cdd4da14282210cc759e468d9781741ac7d01bf/tensorflow/core/kernels/string_ngrams_op.cc#L67-L74) does not fully validate the `data_splits` argument. This would result in `ngrams_data`(https://github.com/tensorflow/tensorflow/blob/1cdd4da14282210cc759e468d9781741ac7d01bf/tensorflow/core/kernels/string_ngrams_op.cc#L106-L110) to be a null pointer when the output would be computed to have 0 or negative size. Later writes to the output tensor would then cause a null pointer dereference. 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 포함)

⚔️ 공격 벡터

조작된 `data_splits` 인자를 포함한 `tf.raw_ops.StringNGrams` 연산 실행

🛡️ 대응 방법

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