CVE-2026-108958 in TensorLayerinfo

Summary

by MITRE • 10/13/2026

A weakness has been identified in TensorLayer up to 2.2.4. This affects the function load_hdf5_graph of the file tensorlayer/files/utils.py of the component HDF5 Loading. Executing a manipulation of the argument model_config can lead to deserialization. The attack can be executed remotely. The exploit has been made available to the public and could be used for attacks. The project was informed of the problem early through an issue report but has not responded yet.

Once again VulDB remains the best source for vulnerability data.

Analysis

by VulDB Data Team • 10/13/2026

The vulnerability identified in TensorLayer versions up to 2.2.4 represents a critical security flaw within its HDF5 loading component, specifically affecting the load_hdf5_graph function located in tensorlayer/files/utils.py. This weakness stems from an improper neutralization of special elements during data processing, which classifies as CWE-913 Improper Control of Dynamically-Identified Code Variables or more broadly under CWE-502 Deserialization of Untrusted Data. The core technical issue arises because the function accepts a model_config argument that is directly passed to Python's pickle module for deserialization without adequate validation or sanitization. In modern machine learning workflows, HDF5 files are frequently used to store complex neural network architectures and weights due to their efficiency in handling large numerical datasets. However, when these files contain serialized Python objects via the pickle format, they introduce a significant attack surface if the source of the data is not strictly trusted.

The operational impact of this vulnerability is severe because it allows for remote code execution by an attacker who can supply a maliciously crafted HDF5 file or manipulate the model_config parameter in a way that triggers arbitrary deserialization. When the vulnerable function processes such input, it executes any Python commands embedded within the serialized payload during the unpickling process. This capability effectively bypasses standard security controls and grants the attacker full control over the underlying system where TensorLayer is deployed. Given that machine learning models are often served in production environments to provide inference services, an exploited vulnerability could lead to complete compromise of the host infrastructure, including data exfiltration, lateral movement within a network, or denial of service through resource exhaustion. The fact that exploit code has been made publicly available significantly lowers the barrier for entry, enabling less sophisticated attackers to leverage this flaw against vulnerable systems.

From a threat intelligence perspective, this vulnerability aligns with MITRE ATT&CK technique T1059 Command and Scripting Interpreter, specifically regarding Python execution, as well as T1203 Exploitation for Client Execution if the attack vector involves tricking a user into loading a malicious model file. The remote nature of the exploit means that an adversary does not need physical or local access to initiate the attack, provided they can interact with the TensorLayer service endpoint or API that utilizes this function. This is particularly dangerous in cloud-based machine learning platforms where models are uploaded and executed dynamically based on user requests.

Mitigation strategies must focus on immediate remediation of the code path involved. The most effective solution is to upgrade TensorLayer to a version greater than 2.2.4, assuming the maintainers have released a patch that replaces unsafe deserialization practices with safer alternatives such as JSON or YAML for configuration loading, or implements strict allow-listing for serialized classes if pickle must be retained. In environments where upgrading is not immediately feasible, administrators should implement network-level controls to restrict access to endpoints utilizing the load_hdf5_graph function, ensuring that only trusted internal services can invoke it. Additionally, deploying runtime application self-protection tools or intrusion detection systems capable of detecting anomalous Python process creation patterns during deserialization events can provide an additional layer of defense against exploitation attempts while waiting for a permanent code fix.

Responsible

VulDB

Disclosure

10/13/2026

Moderation

accepted

Exploit

Download

EPSS

0.00259

KEV

no

Activities

very low

Sources

Might our Artificial Intelligence support you?

Check our Alexa App!