A remote code execution vulnerability exists in invoke-ai/invokeai versions 5.3.1 through 5.4.2 via the /api/v2/models/install API. The vulnerability arises from unsafe deserialization of model files
A remote code execution vulnerability exists in invoke-ai/invokeai versions 5.3.1 through 5.4.2 via the /api/v2/models/install API. The vulnerability arises from unsafe deserialization of model files using torch.load without proper validation. Attackers can exploit this by embedding malicious code in model files, which is executed upon loading. This issue is fixed in version 5.4.3.
Affected software
Click a technology to see all vulnerabilities affecting it.
| Platform | Package | Vulnerable versions | Fixed in |
|---|---|---|---|
| Python (PyPI) | invokeai | >= 5.3.1, < 5.4.3rc1 | 5.4.3rc1 |
References
- https://nvd.nist.gov/vuln/detail/CVE-2024-12029
- https://github.com/invoke-ai/InvokeAI/commit/ed46acee79460189b38c164321b14bdfbf3073c9
- https://github.com/invoke-ai/invokeai/commit/756008dc5899081c5aa51e5bd8f24c1b3975a59e
- https://github.com/invoke-ai/InvokeAI
- https://github.com/pypa/advisory-database/tree/main/vulns/invokeai/PYSEC-2025-9.yaml
- https://huntr.com/bounties/9b790f94-1b1b-4071-bc27-78445d1a87a3
- https://github.com/advisories/GHSA-mcrp-whpw-jp68
- CVSS vector
CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H- Weakness (CWE)
CWE-502- Platform
- Python (PyPI)
- Package
invokeai- Disclosed
- 20.03.2025
- Updated
- 11.10.2026 12:20
Sources and licenses
OSV / GitHub Advisory Database - GHSA-mcrp-whpw-jp68 - CC BY 4.0
OSV / GitHub Advisory Database - PYSEC-2025-9 - PyPA Advisory Database; CC BY 4.0
Vulnerability history: invokeai
All published vulnerabilities of this package (Python (PyPI)), newest first. Shows whether this is a one-off slip or a package that needs watching.
- Total entries
- 5
- First → latest
- 03.2025 09.2025
- Without a fix
- 2
- Exploited in attacks
- 0
Severity breakdown
- Critical 3
- High 2
Disclosures per year
- 2025: 5
- 2026: 0
-
A remote code execution vulnerability exists in invoke-ai/invokeai versions 5.3.1 through 5.4.2 via the /api/v2/models/install API. The vulnerability arises from unsafe deserialization of model files this entry
Know which vulnerabilities affect your application
With the DockRay integration and software inventory enabled, DockRay checks reported component versions against known vulnerabilities and notifies you about confirmed matches. Coverage depends on the supported technology and available advisory data.