CVE-2025-46567
Description
LLama Factory enables fine-tuning of large language models. Prior to version 1.0.0, a critical vulnerability exists in the `llamafy_baichuan2.py` script of the LLaMA-Factory project. The script performs insecure deserialization using `torch.load()` on user-supplied `.bin` files from an input directory. An attacker can exploit this behavior by crafting a malicious `.bin` file that executes arbitrary commands during deserialization. This issue has been patched in version 1.0.0.
How to fix
- hiyouga llama-factory1.0.0 or later
- llamafactory0.9.3 or later
Affected products
| Product | Affected versions | Fixed in |
|---|---|---|
| hiyouga llama-factory | v < 1.0.0 | 1.0.0 |
| llamafactoryPyPI | v < 0.9.3 | 0.9.3 |
Check your version
Choose the product and enter the version you run to see whether it falls in the affected range.
Attack Surface Management
See the assets tied to your domains, the technologies they run and known vulnerabilities in one list.