High severityNVD Advisory· Published Mar 11, 2025· Updated Jul 24, 2025
Arbitrary Code Execution via Crafted Keras Config for Model Loading
CVE-2025-1550
Description
The Keras Model.load_model function permits arbitrary code execution, even with safe_mode=True, through a manually constructed, malicious .keras archive. By altering the config.json file within the archive, an attacker can specify arbitrary Python modules and functions, along with their arguments, to be loaded and executed during model loading.
AI Insight
LLM-synthesized narrative grounded in this CVE's description and references.
Affected packages
Versions sourced from the GitHub Security Advisory.
| Package | Affected versions | Patched versions |
|---|---|---|
kerasPyPI | >= 3.0.0, < 3.9.0 | 3.9.0 |
Affected products
4- osv-coords3 versionspkg:apk/chainguard/kubeflow-pipelines-visualization-serverpkg:apk/wolfi/kubeflow-pipelines-visualization-serverpkg:pypi/keras
< 2.4.1-r2+ 2 more
- (no CPE)range: < 2.4.1-r2
- (no CPE)range: < 2.4.1-r2
- (no CPE)range: >= 3.0.0, < 3.9.0
- Google/Kerasv5Range: 3.0.0
Patches
Vulnerability mechanics
References
9- github.com/advisories/GHSA-48g7-3x6r-xfhpghsaADVISORY
- nvd.nist.gov/vuln/detail/CVE-2025-1550ghsaADVISORY
- github.com/keras-team/keras/commit/e67ac8ffd0c883bec68eb65bb52340c7f9d3a903ghsaWEB
- github.com/keras-team/keras/pull/20751ghsaWEB
- github.com/keras-team/keras/releases/tag/v3.9.0ghsaWEB
- github.com/keras-team/keras/security/advisories/GHSA-48g7-3x6r-xfhpghsaWEB
- github.com/pypa/advisory-database/tree/main/vulns/keras/PYSEC-2025-122.yamlghsaWEB
- towerofhanoi.it/writeups/cve-2025-1550ghsaWEB
- towerofhanoi.it/writeups/cve-2025-1550/mitre
News mentions
0No linked articles in our index yet.