Incident report
JFrog Discovery of Over 100 Malicious Pickle Models Hosted on Public Model Hub
On February 27, 2024, JFrog Security Research published an investigation identifying roughly 100 malicious machine learning models hosted publicly on the Hugging Face Hub, including checkpoints engineered to open interactive reverse shells to attacker infrastructure when loaded. Every confirmed payload abused Python's unsafe `pickle` serialization format inside `.pt` and `.bin` model weights, executing arbitrary system commands during standard `torch.load()` calls. Later in 2024, Protect AI expanded scanning across the hub and identified additional suspicious model artifacts. The disclosures accelerated industry adoption of Hugging Face's integrated security scanner badges and widespread migration toward non-executable `safetensors` weights.
Incident record
- Reported
- Severity
- High
- Vector
- Supply Chain
- Affected system type
- Public ML Model Repositories & PyTorch Checkpoints
- Reference URI
https://jfrog.com/blog/data-scientists-targeted-with-malicious-hugging-face-ml-models-over-100-models-found/
Defensive lesson
Audit external model repositories against an internal vetted mirror, mandate safetensors exclusively, and block raw pickle deserialization in ML runtimes.
Research citation
Referenced techniques
- Supply Chain Compromise: Model Repository AML.T0010.003
- User Execution: Unsafe AI Artifacts AML.T0011.000
- Manipulate AI Model: Embed Malware AML.T0018.002
- Publish Poisoned AI Artifacts: Models AML.T0115.001