Out-of-bounds Read Affecting tensorflow-cpu package, versions [2.5.0,2.5.1) [2.4.0,2.4.3) [,2.3.4)
Threat Intelligence
Do your applications use this vulnerable package?
In a few clicks we can analyze your entire application and see what components are vulnerable in your application, and suggest you quick fixes.
Test your applications- Snyk ID SNYK-PYTHON-TENSORFLOWCPU-1540724
- published 13 Aug 2021
- disclosed 13 Aug 2021
- credit Unknown
Introduced: 13 Aug 2021
CVE-2021-37679 Open this link in a new tabHow to fix?
Upgrade tensorflow-cpu
to version 2.5.1, 2.4.3, 2.3.4 or higher.
Overview
tensorflow-cpu is a machine learning framework.
Affected versions of this package are vulnerable to Out-of-bounds Read. It is possible to nest a tf.map_fn
within another tf.map_fn
call. However, if the input tensor is a RaggedTensor
and there is no function signature provided, code assumes the output is a fully specified tensor and fills output buffer with uninitialized contents from the heap. The t
and z
outputs should be identical, however this is not the case. The last row of t
contains data from the heap which can be used to leak other memory information. The bug lies in the conversion from a Variant
tensor to a RaggedTensor
. The implementation does not check that all inner shapes match and this results in the additional dimensions. The same implementation can result in data loss, if input tensor is tweaked.