What’s Vulnerable › Vulnerabilities
CVE-2021-29601: Integer overflow in TFLite concatentation
- Severity: high (CVSS 7.1 v3.1)
- Exploited in the wild: not listed in CISA KEV
- EPSS: 0.2% probability of exploitation in the next 30 days
- Public exploit or detection template: yes
- Published: 2021-05-14 · updated 2026-06-17
- Weakness: CWE-190
Description
TensorFlow is an end-to-end open source platform for machine learning. The TFLite implementation of concatenation is vulnerable to an integer overflow issue(https://github.com/tensorflow/tensorflow/blob/7b7352a724b690b11bfaae2cd54bc3907daf6285/tensorflow/lite/kernels/concatenation.cc#L70-L76). An attacker can craft a model such that the dimensions of one of the concatenation input overflow the values of `int`. TFLite uses `int` to represent tensor dimensions, whereas TF uses `int64`. Hence, valid TF models can trigger an integer overflow when converted to TFLite format. 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.
Affected products
- tensorflow: before 2.1.4; from 2.2.0 before 2.2.3; from 2.3.0 before 2.3.3; from 2.4.0 before 2.4.2 — fixed in 2.1.4, 2.2.3, 2.3.3, 2.4.2
How to fix
Upgrade to a fixed version: tensorflow 2.1.4, 2.2.3, 2.3.3, 2.4.2. Check the vendor advisory for mitigations.
References
- https://github.com/tensorflow/tensorflow/commit/4253f96a58486ffe84b61c0415bb234a4632ee73
- https://github.com/tensorflow/tensorflow/security/advisories/GHSA-9c84-4hx6-xmm4
- https://github.com/tensorflow/tensorflow/commit/4253f96a58486ffe84b61c0415bb234a4632ee73
- https://github.com/tensorflow/tensorflow/security/advisories/GHSA-9c84-4hx6-xmm4
Get alerted when CVE-2021-29601 or the next vulnerability affects your stack