Vulnerability · Published Nov 21, 2024 · Assigned by GitHub_M

CVE-2024-52803LLama Factory Remote OS Command Injection Vulnerability

High 7.5

In plain English

A high-severity cross-site scripting in LLaMA-Factory from hiyouga. Proof-of-concept exploit code is public. The chance it is exploited in the next 30 days is estimated at 2.3% (higher than 84% of all known vulnerabilities). Fixed versions are available - upgrade the affected package.

Severity (CVSS 3.1)7.5High
Exploit odds (30 days)2.3%top 16.4% of all CVEs
Exploited in the wildNo reportsCISA SSVC: poc
Attack toolingNoneno public tooling known

Official description

LLama Factory enables fine-tuning of large language models. A critical remote OS command injection vulnerability has been identified in the LLama Factory training process. This vulnerability arises from improper handling of user input, allowing malicious actors to execute arbitrary OS commands on the host system. The issue is caused by insecure usage of the `Popen` function with `shell=True`, coupled with unsanitized user input. Immediate remediation is required to mitigate the risk. This vulnerability is fixed in 0.9.1.

Affected packages & fixed versions

EcosystemPackageFixed inAdvisory
PyPIllamafactory0.9.1GHSA-hj3w-wrh4-44vp
PyPIllamafactory0.9.1PYSEC-2026-1575

Affected products (as reported)

VendorProductVersions
hiyouga LLaMA-Factory < 0.9.1

Weakness: CWE-79 · Vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N

References