Skip to main content

CVE-2022-23595: CWE-476: NULL Pointer Dereference in tensorflow tensorflow

Medium
Published: Fri Feb 04 2022 (02/04/2022, 22:32:13 UTC)
Source: CVE
Vendor/Project: tensorflow
Product: tensorflow

Description

Tensorflow is an Open Source Machine Learning Framework. When building an XLA compilation cache, if default settings are used, TensorFlow triggers a null pointer dereference. In the default scenario, all devices are allowed, so `flr->config_proto` is `nullptr`. The fix will be included in TensorFlow 2.8.0. We will also cherrypick this commit on TensorFlow 2.7.1, TensorFlow 2.6.3, and TensorFlow 2.5.3, as these are also affected and still in supported range.

AI-Powered Analysis

AILast updated: 06/22/2025, 03:36:04 UTC

Technical Analysis

CVE-2022-23595 is a medium-severity vulnerability in TensorFlow, an open-source machine learning framework widely used for developing and deploying machine learning models. The vulnerability is a NULL pointer dereference (CWE-476) that occurs during the building of an XLA (Accelerated Linear Algebra) compilation cache. Specifically, when default settings are used, TensorFlow allows all devices by default, which results in the internal pointer `flr->config_proto` being set to `nullptr`. This null pointer dereference can cause the TensorFlow process to crash or terminate unexpectedly when the affected code path is executed. The issue affects multiple TensorFlow versions: all versions greater than or equal to 2.7.0 but less than 2.7.1, versions from 2.6.0 up to but not including 2.6.3, and all versions below 2.5.3. The vulnerability was identified and fixed in TensorFlow 2.8.0, with backported patches planned for 2.7.1, 2.6.3, and 2.5.3, which are still supported releases. There are no known exploits in the wild at this time, and the vulnerability requires the use of default device settings that lead to the null pointer dereference during the XLA compilation cache build process. Since this is a NULL pointer dereference, the primary impact is a denial of service (DoS) through application crashes rather than unauthorized code execution or data leakage. The vulnerability does not require authentication or user interaction beyond triggering the affected code path in TensorFlow. Given TensorFlow’s widespread use in research, industry, and cloud environments, this vulnerability could impact any organization running vulnerable TensorFlow versions, especially where XLA compilation is enabled or used by default.

Potential Impact

For European organizations, the primary impact of CVE-2022-23595 is the potential for denial of service due to application crashes in machine learning workloads that utilize TensorFlow with vulnerable versions. This could disrupt AI/ML model training, inference pipelines, or production systems relying on TensorFlow, leading to operational downtime and potential delays in data processing or decision-making. Organizations in sectors heavily reliant on AI, such as finance, healthcare, automotive, and manufacturing, may experience interruptions in critical services or research activities. While the vulnerability does not directly compromise confidentiality or integrity, the availability impact can have cascading effects on business continuity and service reliability. Cloud service providers and data centers hosting TensorFlow workloads may also be affected, potentially impacting multiple customers if shared infrastructure is used. Since no known exploits exist, the immediate risk is moderate; however, the widespread deployment of TensorFlow in Europe means that unpatched systems could be vulnerable to accidental crashes or targeted DoS attempts if an exploit is developed. The impact is more pronounced in environments where XLA compilation is enabled by default or heavily used, as this triggers the vulnerable code path.

Mitigation Recommendations

European organizations should prioritize upgrading TensorFlow to version 2.8.0 or later, or apply the backported patches available for versions 2.7.1, 2.6.3, and 2.5.3 to remediate this vulnerability. If immediate upgrading is not feasible, organizations should consider disabling XLA compilation or configuring device settings explicitly to avoid the default scenario that leads to the null pointer dereference. Implementing robust monitoring and alerting for TensorFlow process crashes can help detect exploitation attempts or accidental triggers of this vulnerability. Additionally, organizations should audit their machine learning pipelines to identify all TensorFlow instances and verify their versions. For cloud deployments, coordinate with cloud providers to ensure underlying TensorFlow frameworks are patched. Incorporating fault tolerance and automatic restart mechanisms in ML workflows can mitigate the operational impact of unexpected crashes. Finally, maintain strict access controls and environment segregation to limit the potential blast radius if a denial of service occurs.

Need more detailed analysis?Get Pro

Technical Details

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

Threat ID: 682d9848c4522896dcbf6200

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

Last enriched: 6/22/2025, 3:36:04 AM

Last updated: 8/12/2025, 1:17:58 AM

Views: 15

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