LLaMA-Factory through 0.9.5 contains a remote code execution vulnerability that allows attackers with WebUI access to execute arbitrary Python code by supplying a malicious model path in the Chat or Training interfaces. The application passes user-supplied model path input unvalidated into AutoTokenizer.from_pretrained() and AutoModel.from_pretrained() with a hardcoded trust_remote_code=True parameter, causing the Hugging Face transformers library to fetch and execute arbitrary code from a remote or local model repository with the privileges of the server process.
Description as published by the source, in English.
Key facts
Published
2026-06-30
Last modified
2026-10-25
Assigned by
disclosure@vulncheck.com
CVSS vector
CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H
Scored by
nvd@nist.gov (NVD Primary)
Probability of exploitation
0.6 %
higher than 47 %
of all known vulnerabilities
EPSS, next 30 days, model v2026.06.15
The product constructs all or part of a code segment using externally-influenced input from an upstream component, but it does not neutralize or incorrectly neutralizes special elements that could modify the syntax or b…
Attack techniques
Derived through the weakness type: CVE to CWE to CAPEC to ATT&CK.
This shows which techniques the weakness class is historically used for.
It does not assert that this vulnerability has been exploited that way.
T1027.006: HTML Smuggling stealth
T1027.009: Embedded Payloads stealth
T1055: Process Injection stealth, privilege-escalation
T1176: Software Extensions persistence
T1195.001: Compromise Software Dependencies and Development Tools initial-access