Skip to main content

CVE-2022-35984: CWE-617: Reachable Assertion in tensorflow tensorflow

Medium
Published: Fri Sep 16 2022 (09/16/2022, 21:40:14 UTC)
Source: CVE
Vendor/Project: tensorflow
Product: tensorflow

Description

TensorFlow is an open source platform for machine learning. `ParameterizedTruncatedNormal` assumes `shape` is of type `int32`. A valid `shape` of type `int64` results in a mismatched type `CHECK` fail that can be used to trigger a denial of service attack. We have patched the issue in GitHub commit 72180be03447a10810edca700cbc9af690dfeb51. The fix will be included in TensorFlow 2.10.0. We will also cherrypick this commit on TensorFlow 2.9.1, TensorFlow 2.8.1, and TensorFlow 2.7.2, as these are also affected and still in supported range. There are no known workarounds for this issue.

AI-Powered Analysis

AILast updated: 06/22/2025, 19:50:29 UTC

Technical Analysis

CVE-2022-35984 is a vulnerability in TensorFlow, an open-source machine learning platform widely used for developing and deploying machine learning models. The issue arises in the `ParameterizedTruncatedNormal` function, which expects the `shape` parameter to be of type `int32`. However, if a `shape` parameter of type `int64` is provided, this leads to a type mismatch that triggers a CHECK assertion failure within the TensorFlow codebase. This assertion failure causes the program to terminate unexpectedly, resulting in a denial of service (DoS) condition. The vulnerability affects multiple TensorFlow versions: all versions prior to 2.7.2, versions from 2.8.0 up to but not including 2.8.1, and versions from 2.9.0 up to but not including 2.9.1. The issue has been patched in TensorFlow 2.10.0 and backported to supported versions 2.7.2, 2.8.1, and 2.9.1. No known workarounds exist, meaning users must update to a patched version to mitigate the risk. Exploitation does not require authentication or user interaction but does require the attacker to supply a specially crafted input to trigger the assertion failure. There are no known exploits in the wild at this time. The vulnerability is classified under CWE-617 (Reachable Assertion), indicating that an assertion statement can be triggered by external input, leading to a crash or denial of service. This vulnerability primarily impacts the availability of TensorFlow-based applications by causing unexpected termination when processing malicious inputs.

Potential Impact

For European organizations, the primary impact of CVE-2022-35984 is the potential disruption of machine learning services and applications that rely on vulnerable TensorFlow versions. Organizations using TensorFlow in production environments—such as financial institutions, healthcare providers, research institutions, and technology companies—may experience service outages or degraded performance if an attacker supplies malicious inputs that trigger the assertion failure. This could interrupt critical workflows, delay data processing, or halt automated decision-making systems. While the vulnerability does not directly compromise confidentiality or integrity, the denial of service could indirectly affect business continuity and operational reliability. Additionally, organizations that provide machine learning as a service (MLaaS) or deploy TensorFlow models in cloud environments may face reputational damage and customer trust issues if their services become unavailable. Given the widespread adoption of TensorFlow across industries in Europe, the impact could be significant, especially in sectors where uptime and reliability are essential. However, the lack of known exploits in the wild and the requirement for specific input conditions somewhat limit the immediate risk.

Mitigation Recommendations

To mitigate CVE-2022-35984, European organizations should prioritize upgrading TensorFlow installations to the patched versions: 2.7.2, 2.8.1, 2.9.1, or later (including 2.10.0). Since no workarounds exist, patching is the only effective mitigation. Organizations should implement the following practical steps: 1) Conduct an inventory of all systems and applications using TensorFlow to identify vulnerable versions. 2) Test and deploy the updated TensorFlow versions in development and staging environments to ensure compatibility and stability. 3) Implement input validation and sanitization at the application layer to restrict or verify the data types and formats of inputs passed to TensorFlow functions, reducing the risk of malformed inputs triggering the assertion. 4) Monitor application logs and system behavior for unexpected crashes or assertion failures that could indicate attempted exploitation. 5) For cloud or containerized deployments, update container images and orchestration configurations to use patched TensorFlow versions. 6) Educate developers and data scientists about the importance of using supported TensorFlow versions and the risks of processing untrusted inputs. 7) Consider implementing runtime protections such as process supervision and automatic restarts to minimize downtime in case of crashes. These measures will help reduce the risk of denial of service and improve resilience against this vulnerability.

Need more detailed analysis?Get Pro

Technical Details

Data Version
5.1
Assigner Short Name
GitHub_M
Date Reserved
2022-07-15T00:00:00.000Z
Cisa Enriched
true

Threat ID: 682d9845c4522896dcbf40dd

Added to database: 5/21/2025, 9:09:25 AM

Last enriched: 6/22/2025, 7:50:29 PM

Last updated: 8/15/2025, 6:41:13 AM

Views: 18

Actions

PRO

Updates to AI analysis are available only with a Pro account. Contact root@offseq.com for access.

Please log in to the Console to use AI analysis features.

Need enhanced features?

Contact root@offseq.com for Pro access with improved analysis and higher rate limits.

Latest Threats