{"id":"CVE-2022-29208","published":"2022-05-20T22:30:13Z","modified":"2025-04-22T17:58:20Z","title":"Segfault and Out-of-bounds Write write due to incomplete validation in TensorFlow","vendor":"tensorflow","product":"tensorflow","tier":"tail","description":{"text":"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.EditDistance` has incomplete validation. Users can pass negative values to cause a segmentation fault based denial of service. In multiple places throughout the code, one may compute an index for a write operation. However, the existing validation only checks against the upper bound of the array. Hence, it is possible to write before the array by massaging the input to generate negative values for `loc`. Versions 2.9.0, 2.8.1, 2.7.2, and 2.6.4 contain a patch for this issue.","provenance":"source","from":"CVE.org"},"cvss":{"score":7.1,"severity":"HIGH","version":"3.1","vector":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:H/A:H","provenance":"source","from":"CVE.org CNA"},"epss":{"score":0.00387,"percentile":0.33707,"provenance":"source"},"cwes":[{"id":"CWE-787","name":"Out-of-bounds Write"}],"references":[{"url":"https://github.com/tensorflow/tensorflow/releases/tag/v2.6.4","tags":["x_refsource_MISC"]},{"url":"https://github.com/tensorflow/tensorflow/releases/tag/v2.7.2","tags":["x_refsource_MISC"]},{"url":"https://github.com/tensorflow/tensorflow/releases/tag/v2.8.1","tags":["x_refsource_MISC"]},{"url":"https://github.com/tensorflow/tensorflow/releases/tag/v2.9.0","tags":["x_refsource_MISC"]},{"url":"https://github.com/tensorflow/tensorflow/security/advisories/GHSA-2r2f-g8mw-9gvr","tags":["x_refsource_CONFIRM"]},{"url":"https://github.com/tensorflow/tensorflow/commit/30721cf564cb029d34535446d6a5a6357bebc8e7","tags":["x_refsource_MISC"]}],"priority":{"score":11.7,"factors":[{"name":"EPSS percentile","points":6.74},{"name":"CVSS severity","points":4.97}]},"vendorSlug":"tensorflow","affectedVersions":[{"vendor":"tensorflow","product":"tensorflow","versions":["< 2.6.4",">= 2.7.0rc0, < 2.7.2",">= 2.8.0rc0, < 2.8.1",">= 2.9.0rc0, < 2.9.0"]}],"ssvc":{"exploitation":"poc","automatable":"no","technicalImpact":"partial","timestamp":"2025-04-22T15:46:49.777430Z","from":"CISA ADP","provenance":"source"},"affected":[{"ecosystem":"PyPI","package":"tensorflow","vulnerableRanges":["<2.6.4",">=2.7.0, <2.7.2",">=2.8.0, <2.8.1"],"patched":["2.6.4","2.7.2","2.8.1"],"from":["GHSA-2r2f-g8mw-9gvr","PYSEC-2026-3088"],"provenance":"source"},{"ecosystem":"PyPI","package":"tensorflow-cpu","vulnerableRanges":["<2.6.4",">=2.7.0, <2.7.2",">=2.8.0, <2.8.1"],"patched":["2.6.4","2.7.2","2.8.1"],"from":["GHSA-2r2f-g8mw-9gvr","PYSEC-2026-3266"],"provenance":"source"},{"ecosystem":"PyPI","package":"tensorflow-gpu","vulnerableRanges":["<2.6.4",">=2.7.0, <2.7.2",">=2.8.0, <2.8.1"],"patched":["2.6.4","2.7.2","2.8.1"],"from":["GHSA-2r2f-g8mw-9gvr","PYSEC-2026-943"],"provenance":"source"}],"summary":{"text":"The flaw is incomplete input validation in the EditDistance operation (tf.raw_ops.EditDistance) of TensorFlow, an open source machine learning platform, where computed write indices are checked only against the array's upper bound and not the lower one. An attacker with local access and low privileges who can supply crafted inputs can use negative index values to trigger an out-of-bounds write before the array, which can crash the process via a segmentation fault, and the attack requires no user interaction.","provenance":"ai","model":"claude-haiku-5-5","generatedAt":"2026-11-20T21:53:19Z"},"euvd":{"id":"EUVD-2022-2039","exploited":false,"provenance":"source"},"lineage":{"familyId":"fam-tensorflow-cve-2021-29564","parents":[{"from":"CVE-2021-29564","to":"CVE-2022-29208","relation":"related","confidence":"medium","kind":"lineage","evidence":[{"kind":"same-code","provenance":"machine","files":["tensorflow/core/kernels/edit_distance_op.cc"],"commits":["https://github.com/tensorflow/tensorflow/commit/f4c364a5d6880557f6f5b6eb5cee2c407f0186b3","https://github.com/tensorflow/tensorflow/commit/30721cf564cb029d34535446d6a5a6357bebc8e7"],"basis":"shared function","functions":["EditDistanceOp"]}]}]}}