Attack ChainAIDerived
Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain
-
ReconHost malicious .keras/.h5 archive
-
DeliveryVictim loads model in containerized pipeline
-
ExploitCWD-based filter validates against `/`
-
InstallTraversal entries pass safety check
-
C2Files written outside extraction dir
-
ExecuteOverwrite config or inject code
-
ImpactPipeline executes attacker payload
Vulnerability Assessment
| Weakness |
CWE
OWASP Top 10:2025
A01:2025 - Broken Access Control
ASVS 5.0
V5 - File Handling Path canonicalization, traversal prevention
MITRE ATT&CK
2 techniques across 2 tactics: Discovery, Collection The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up. |
| Exploitation Conditions | Victim must invoke Keras archive extraction (e.g., |
| Impact | The provided CVSS 3.0 vector (AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:N, score 8.1) reasonably reflects that the attack requires a victim to load a malicious archive (UI:R) but otherwise needs no privileges. There is no KEV listing, no EPSS score supplied, and no public POC evidence in the references - only a Huntr bounty page and the upstream fix commit - so this is best treated as a credible-but-not-yet-exploited supply-chain risk to ML workloads rather than an active emergency. The C:H/I:H rating is consistent with arbitrary file writes that can clobber config or inject code, but the A:N (no availability impact) is debatable since corrupting pipeline files could degrade availability; defenders should not over-rely on that single metric. |
| Exploit ScenarioDerived | An attacker publishes a malicious Keras model file (a crafted zip/tar archive) on a model hub, Hugging Face mirror, or shared S3 bucket containing entries with |
Get an e-mail when this CVE is exploited, patched or re-scored. Free account.
Alert meAnalysisAIv1 – Jun 11, 2026
Path traversal in Keras archive extraction utilities prior to version 3.14.0 allows remote attackers to write files outside the intended extraction directory when a victim loads a malicious model archive. The flaw stems from validating archive member paths against the process current working directory rather than the actual extraction destination, which collapses to the filesystem root in common Docker, CI/CD, and Jupyter setups. No public exploit identified at time of analysis, but the upstream fix and a Huntr bounty disclosure make targeted exploitation against ML pipelines plausible.
RemediationAI
Upgrade Keras to 3.14.0 or later, which reworks filter_safe_zipinfos() and filter_safe_tarinfos() to take the actual extraction path as base_dir (see commit 2465b6657b02c8eed308759b7e800e295ae01888); released patched version not independently confirmed beyond the description's '3.14.0' string, so verify the tagged release before pinning. As compensating controls until you can upgrade, avoid calling extract_open_archive or loading .keras/.h5 archives from untrusted sources, run training/inference workers with a non-root CWD inside an unprivileged directory (e.g. WORKDIR /workspace in Docker) so the flawed CWD check still rejects most traversals, and prefer Python 3.12+ where tarfile's filter="data" provides a second line of defense - note this changes container ergonomics and may break scripts that assume CWD /. Reference the Huntr bounty page (https://huntr.com/bounties/a07e3983-7158-4419-af2b-38f1dea01a4f) for disclosure details.
Affected VersionsENISA
Affected Packages
Source: OSV (Open Source Vulnerabilities)
Affects your stack
Affects 2 packages in pypi, euvd
Checking this CVE against your own stacks and servers is part of the Basic plan and up.
Technical ContextAI · show details
The vulnerability lives in filter_safe_zipinfos() and filter_safe_tarinfos() inside keras/src/utils/file_utils.py, which previously hardcoded base_dir = resolve_path(".") instead of receiving the real extraction path. This is a classic CWE-22 (Improper Limitation of a Pathname to a Restricted Directory) realized through an incorrect trust boundary: traversal segments like ../ are compared against CWD, so when CWD is / (typical for containerized Python runtimes), any path stays 'within' the boundary. Compounding factors include an AttributeError bug in the zip filter that aborts iteration on a blocked entry and the absence of Python 3.11's filter="data" tarfile safety net, which is the upstream interpreter mitigation for PEP 706-style tar extraction hardening.
Know when Keras gets its next vulnerability
- Watch products and get an email when something new is published
- Check this CVE against your own stack and servers
- Exploit and PoC references, threat intelligence from 22 sources
No credit card · 7-day full trial
Severity by source
AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:N
Network-delivered malicious archive, no privileges, requires victim to load it (UI:R); arbitrary file write gives I:H, modest read/availability impact via overwriting configs and datasets.
Primary rating from Vendor (huntr).
CVSS VectorVendor: huntr
Lifecycle Timeline
2DescriptionCVE.org
Keras versions prior to 3.14.0 are vulnerable to a path traversal issue in the archive extraction utilities located in keras/src/utils/file_utils.py. The functions filter_safe_tarinfos() and filter_safe_zipinfos() validate archive member paths against the process current working directory (CWD) instead of the actual extraction destination. When the process runs with CWD set to /, which is common in Docker containers, CI/CD runners, and Jupyter environments, the validation boundary becomes the filesystem root, allowing traversal paths to bypass the security check. Additionally, the zip filter contains a bug that causes an AttributeError when a blocked entry is encountered, leading to incomplete extraction. Furthermore, Python 3.11 installations lack the filter="data" safety net, leaving them entirely reliant on the flawed CWD-based filter. Exploitation of this vulnerability can result in arbitrary file writes outside the intended extraction directory, enabling attackers to overwrite configuration files, inject malicious code, or corrupt machine learning datasets and pipelines.
Articles & Coverage 1
Executive ViewAI
Keras versions prior to 3.14.0 contain a path traversal vulnerability allowing remote attackers to write arbitrary files outside the intended extraction directory when processing malicious model archives, with heightened risk in containerized and CI/CD machine learning environments. This vulnerability could enable attackers to inject malicious code into ML pipelines and compromise infrastructure if untrusted model files are processed.
Vendor-released patch: Keras 3.14.0. Pending patch deployment: restrict model archive loading to internally vetted repositories only; disable model archive extraction features if unused; implement container-level file system sandboxing with read-only root filesystems; monitor for unauthorized file creation during model load operations.
Threat Intelligence Overview
How this decision was reached
The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.
What every action level means
SSVC AssessmentENISA
Priority Score
Attack Technique
Path traversal exploits occur when applications use user-controlled input to construct file system paths without proper validation.
The Keras Model.load_model method can be exploited to achieve arbitrary code execution, even with safe_mode=True. Rated
Deserialization of untrusted data in Keras 3.11.0 through 3.11.2 allows remote code execution when a victim loads a mali
A arbitrary code injection vulnerability in TensorFlow's Keras framework (<2.13) allows attackers to execute arbitrary c
Directory traversal in Keras through 3.11.3 allows an attacker who supplies a crafted tar archive to keras.utils.get_fil
The Keras Model.load_model method can be exploited to achieve arbitrary code execution, even with safe_mode=True. Rated
Memory-exhaustion denial of service in Google Keras 3.0.0 through 3.13.0 lets a remote attacker crash the Python interpr
Arbitrary local file disclosure in Keras 3.0.0 through 3.13.1 allows a remote attacker to read sensitive files from a vi
Keras Model.load_model fails to enforce safe_mode=True for the StringLookup layer's vocabulary path handling, so a malic
A safe mode bypass vulnerability in the `Model.load_model` method in Keras versions 3.0.0 through 3.10.0 allows an attac
An issue in keras 3.7.0 allows attackers to write arbitrary files to the user's machine via downloading a crafted tar fi
EUVD-2026-36244
GHSA-hqp4-2352-xf5r
NVD
CVE.org
EPSS
Vulnrichment
VulDB
Exploit-DB