Skip to content
OpenAdvisories
Medium · 5.5 CVE-2022-29197 BIT-tensorflow-2022-29197EUVD-2022-4208GHSA-hrg5-737c-2p56PYSEC-2026-1009PYSEC-2026-3202PYSEC-2026-3341

Missing validation causes denial of service in TensorFlow via `UnsortedSegmentJoin`

Published May 20, 2022 · Updated Apr 22, 2025 · Assigned by GitHub_M

Description

TensorFlow is an open source platform for machine learning. Prior to versions 2.9.0, 2.8.1, 2.7.2, and 2.6.4, the implementation of `tf.raw_ops.UnsortedSegmentJoin` does not fully validate the input arguments. This results in a `CHECK`-failure which can be used to trigger a denial of service attack. The code assumes `num_segments` is a scalar but there is no validation for this before accessing its value. Versions 2.9.0, 2.8.1, 2.7.2, and 2.6.4 contain a patch for this issue.

Affected products

VendorProductAffectedFixed
tensorflow tensorflow < 2.6.4, >= 2.7.0rc0, < 2.7.2, >= 2.8.0rc0, < 2.8.1, >= 2.9.0rc0, < 2.9.0 —

Affected packages

EcosystemPackageAffectedFixedRecord
PyPI tensorflow < 2.6.4 2.6.4 GHSA-hrg5-737c-2p56
PyPI tensorflow >= 2.7.0, < 2.7.2 2.7.2 GHSA-hrg5-737c-2p56
PyPI tensorflow >= 2.8.0, < 2.8.1 2.8.1 GHSA-hrg5-737c-2p56
PyPI tensorflow < 2.6.4 · >= 2.7.0, < 2.7.2 · >= 2.8.0, < 2.8.1 2.6.4, 2.7.2, 2.8.1 PYSEC-2026-3202
PyPI tensorflow-cpu < 2.6.4 2.6.4 GHSA-hrg5-737c-2p56
PyPI tensorflow-cpu >= 2.7.0, < 2.7.2 2.7.2 GHSA-hrg5-737c-2p56
PyPI tensorflow-cpu >= 2.8.0, < 2.8.1 2.8.1 GHSA-hrg5-737c-2p56
PyPI tensorflow-cpu < 2.6.4 · >= 2.7.0, < 2.7.2 · >= 2.8.0, < 2.8.1 2.6.4, 2.7.2, 2.8.1 PYSEC-2026-3341
PyPI tensorflow-gpu < 2.6.4 2.6.4 GHSA-hrg5-737c-2p56
PyPI tensorflow-gpu >= 2.7.0, < 2.7.2 2.7.2 GHSA-hrg5-737c-2p56
PyPI tensorflow-gpu >= 2.8.0, < 2.8.1 2.8.1 GHSA-hrg5-737c-2p56
PyPI tensorflow-gpu < 2.6.4 · >= 2.7.0, < 2.7.2 · >= 2.8.0, < 2.8.1 2.6.4, 2.7.2, 2.8.1 PYSEC-2026-1009

References