LLaMA-Factory Remote Code Execution (RCE) Vulnerability
Key facts
- Attack vector
- Network
- Privileges required
- None
- User interaction
- None
- Attack complexity
- Low
- Impact type
- Code execution
- Confidentiality · integrity · availability
- High · High · High
- Fix status
- Fixed
Attack profile from CVSS 3.1 · NVD. Fix status from CNA and GitHub. Impact type from CWE-502.
Summary
LLaMA-Factory is a tuning library for large language models. A remote code execution vulnerability was discovered in LLaMA-Factory versions up to and including 0.9.3 during the LLaMA-Factory training process. This vulnerability arises because the `vhead_file` is loaded without proper safeguards, allowing malicious attackers to execute arbitrary malicious code on the host system simply by passing a malicious `Checkpoint path` parameter through the `WebUI` interface. The attack is stealthy, as the victim remains unaware of the exploitation. The root cause is that the `vhead_file` argument is loaded without the secure parameter `weights_only=True`. Version 0.9.4 contains a fix for the issue.
Why it matters now
SSVC decision points
CISA ADP · SSVC 2.0.3
- Exploitation
- Poc
- Automatable
- No
- Technical impact
- Partial
The decision (Track, Attend, Act) also depends on your mission and well-being impact; see CISA's SSVC guide.
Affected products
| Vendor | Product | Affected versions | Fixed in | Status | Source |
|---|---|---|---|---|---|
| hiyouga | LLaMA-Factory | before 0.9.4 | 0.9.4 | Patch available | CNA |
| — | llamafactory (PyPI) | up to 0.9.3 | — | No fix listed | GHSA-xj56-p8mm-qmxj |
- LLaMA-Factory Vendorhiyouga Affected before 0.9.4 Fixed in 0.9.4 Patch available CNA
- llamafactory (PyPI) Vendor— Affected up to 0.9.3 Fixed in — No fix listed GHSA-xj56-p8mm-qmxj
Remediation
- Fix · CNA LLaMA-Factory (hiyouga) Fixed in 0.9.4
Timeline
- 2026-10-02 Threatist record created from CVE-2025-53002
- 2026-10-03 Alias added: GHSA-xj56-p8mm-qmxj
References
Exploit 2
More hiyouga Llama-factory vulnerabilities
- TI-2026-41855 LLaMA-Factory 0.9.5 Remote Code Execution via WebUI Model Path CVSS 4.0CRITICAL 9.3
- TI-2024-35316 LLama Factory Remote OS Command Injection Vulnerability CVSS 3.1CRITICAL 9.8
- TI-2025-38177 LLaMA Factory's Chat API has Critical SSRF and LFI Vulnerabilities CVSS 3.1HIGH 8.1
- TI-2025-29280 LLaMA-Factory Allows Arbitrary Code Execution via Unsafe Deserialization in Ilamafy_baichuan2.py CVSS 3.1HIGH 7.8
Sources
- CVE-2025-53002 · CVE Program
- CVE-2025-53002 · NVD
- FIRST EPSS
- GHSA-xj56-p8mm-qmxj · GitHub Advisory Database · CC BY 4.0
This product uses the NVD API but is not endorsed or certified by the NVD. Sources and licences