Skip to content
Heist/ feed
Back to feed
High

Security advisory

Type: advisorySources: OSVCVE: CVE-2021-41205

TensorFlow is an open source platform for machine learning. In affected versions the shape inference functions for the `QuantizeAndDequantizeV*` operations can trigger a read outside of bounds of heap allocated array. The fix will be included in TensorFlow 2.7.0. We will also cherrypick this commit on TensorFlow 2.6.1, TensorFlow 2.5.2, and TensorFlow 2.4.4, as these are also affected and still in supported range.

Products
Not specified
Affected versions
Not specified
Fixed versions
Not specified
CVEs
CVE-2021-41205
Confirmed fixed CVEs
Not specified
Updated in this feed
31 Oct 2026, 12:38 UTC · Revision 1

Source evidence

CVE-2021-41205

core-osv · Original source

Published 5 Nov 2021, 21:15 UTC

TensorFlow is an open source platform for machine learning. In affected versions the shape inference functions for the `QuantizeAndDequantizeV*` operations can trigger a read outside of bounds of heap allocated array. The fix will be included in TensorFlow 2.7.0. We will also cherrypick this commit on TensorFlow 2.6.1, TensorFlow 2.5.2, and TensorFlow 2.4.4, as these are also affected and still in supported range.

osv:CVE-2021-41205
Complete source record
{
  "id": "ce6e64b4b9f14f562e18d201f1fb95767217bf4bb70c438b9cee835b7b584ddd",
  "url": "https://osv.dev/vulnerability/CVE-2021-41205",
  "method": "structured",
  "payload": {
    "kind": "advisory",
    "title": "CVE-2021-41205",
    "summary": "TensorFlow is an open source platform for machine learning. In affected versions the shape inference functions for the `QuantizeAndDequantizeV*` operations can trigger a read outside of bounds of heap allocated array. The fix will be included in TensorFlow 2.7.0. We will also cherrypick this commit on TensorFlow 2.6.1, TensorFlow 2.5.2, and TensorFlow 2.4.4, as these are also affected and still in supported range.",
    "evidence": "osv:CVE-2021-41205",
    "products": [],
    "severity": "high",
    "structured": {
      "id": "CVE-2021-41205",
      "aliases": [
        "BIT-tensorflow-2021-41205",
        "CVE-2021-41205",
        "GHSA-49rx-x2rw-pc6f",
        "PYSEC-2021-398",
        "PYSEC-2021-615",
        "PYSEC-2021-813"
      ],
      "metrics": [
        {
          "type": "CVSS_V3",
          "score": "CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:N/A:H"
        }
      ],
      "affected": [
        {
          "ranges": [
            {
              "repo": "https://github.com/tensorflow/tensorflow",
              "type": "GIT",
              "events": [
                {
                  "introduced": "0"
                },
                {
                  "fixed": "64918868e2154b06c7479347a59a4230f785e9fa"
                },
                {
                  "introduced": "a4dfb8d1a71385bd6d122e4f27f86dcebb96712d"
                },
                {
                  "fixed": "957590ea15cc03ee2e00fc61934647d54836676f"
                },
                {
                  "introduced": "919f693420e35d00c8d0a42100837ae3718f7927"
                },
                {
                  "fixed": "3aa40c3ce9d16eae296f086bc4ac4d62deb2affc"
                },
                {
                  "fixed": "7cf73a2274732c9d82af51c2bc2cf90d13cd7e6d"
                }
              ],
              "database_specific": {
                "extracted_events": [
                  {
                    "cpe": "cpe:2.3:a:google:tensorflow:*:*:*:*:*:*:*:*",
                    "range": [
                      {
                        "introduced": "0"
                      },
                      {
                        "fixed": "2.4.4"
                      }
                    ],
                    "source": "CPE_RANGE"
                  },
                  {
                    "cpe": "cpe:2.3:a:google:tensorflow:*:*:*:*:*:*:*:*",
                    "range": [
                      {
                        "introduced": "2.5.0"
                      },
                      {
                        "fixed": "2.5.2"
                      }
                    ],
                    "source": "CPE_RANGE"
                  },
                  {
                    "cpe": "cpe:2.3:a:google:tensorflow:*:*:*:*:*:*:*:*",
                    "range": [
                      {
                        "introduced": "2.6.0"
                      },
                      {
                        "fixed": "2.6.1"
                      }
                    ],
                    "source": "CPE_RANGE"
                  },
                  {
                    "range": [
                      {
                        "fixed": "7cf73a2274732c9d82af51c2bc2cf90d13cd7e6d"
                      }
                    ],
                    "source": "REFERENCES_COMMIT"
                  }
                ]
              }
            }
          ],
          "versions": [
            "v2.4.3",
            "v2.6.0",
            "v2.5.1",
            "v2.4.2",
            "v2.5.0",
            "v2.4.1",
            "v2.4.0",
            "v2.4.0-rc4",
            "v2.4.0-rc3",
            "v2.4.0-rc2",
            "v2.4.0-rc1",
            "v2.4.0-rc0",
            "v1.12.1",
            "v1.9.0-rc2",
            "v1.6.0-rc1",
            "v1.1.0-rc2",
            "v1.1.0-rc1",
            "0.6.0",
            "0.5.0"
          ],
          "database_specific": {
            "source": "https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2021-41205.json",
            "vanir_signatures": [
              {
                "id": "CVE-2021-41205-00534f21",
                "digest": {
                  "length": 841,
                  "function_hash": "123438572843765965434699119996211259994"
                },
                "source": "https://github.com/tensorflow/tensorflow/commit/7cf73a2274732c9d82af51c2bc2cf90d13cd7e6d",
                "target": {
                  "file": "tensorflow/core/ops/array_ops_test.cc",
                  "function": "TEST"
                },
                "deprecated": false,
                "signature_type": "Function",
                "signature_version": "v1"
              },
              {
                "id": "CVE-2021-41205-420c859d",
                "digest": {
                  "threshold": 0.9,
                  "line_hashes": [
                    "21333042683030008622626700788704679710",
                    "107974015649863047257561587271006256936",
                    "76264185542097749296149273318889205888",
                    "162844488573385355550968197393835032856",
                    "21333042683030008622626700788704679710",
                    "107974015649863047257561587271006256936",
                    "76264185542097749296149273318889205888",
                    "162844488573385355550968197393835032856",
                    "87441483361887399196298430787636489488",
                    "117865729398493155727895012950138526202",
                    "338599889189426925599503441466802115660",
                    "162844488573385355550968197393835032856",
                    "21333042683030008622626700788704679710",
                    "107974015649863047257561587271006256936",
                    "76264185542097749296149273318889205888",
                    "162844488573385355550968197393835032856"
                  ]
                },
                "source": "https://github.com/tensorflow/tensorflow/commit/7cf73a2274732c9d82af51c2bc2cf90d13cd7e6d",
                "target": {
                  "file": "tensorflow/core/ops/array_ops.cc"
                },
                "deprecated": false,
                "signature_type": "Line",
                "signature_version": "v1"
              },
              {
                "id": "CVE-2021-41205-98efe4f2",
                "digest": {
                  "threshold": 0.9,
                  "line_hashes": [
                    "176074768384060708931562000164345550008",
                    "297622500618749956280912214398564217827",
                    "330408963431617733958437307615778212110",
                    "201190268224471700808885306969477262917"
                  ]
                },
                "source": "https://github.com/tensorflow/tensorflow/commit/7cf73a2274732c9d82af51c2bc2cf90d13cd7e6d",
                "target": {
                  "file": "tensorflow/core/ops/array_ops_test.cc"
                },
                "deprecated": false,
                "signature_type": "Line",
                "signature_version": "v1"
              }
            ],
            "vanir_signatures_modified": "2026-10-20T14:10:32Z"
          }
        }
      ],
      "modified": "2026-10-20T14:10:32.672300288Z",
      "provider": "osv",
      "references": [
        "https://github.com/tensorflow/tensorflow/security/advisories/GHSA-49rx-x2rw-pc6f",
        "https://github.com/tensorflow/tensorflow/commit/7cf73a2274732c9d82af51c2bc2cf90d13cd7e6d"
      ],
      "provider_metadata": {}
    },
    "related_cves": [
      {
        "value": "CVE-2021-41205",
        "evidence": "/id"
      }
    ],
    "security_relevant": true,
    "severity_evidence": "/severity/0/score"
  },
  "source_id": "core-osv",
  "document_id": 388623,
  "published_at": "2021-11-05T21:15:08.75+00:00"
}