GGUF模型投毒感染2400次下载
推荐指数 63.0 NO. 018 · 2026.11.29
发布2026/11/28Score242Comments75
简介
攻击者在Hugging Face上的GGUF模型文件中植入恶意chat template,模型回答正常但会在用户不可见的系统提示中插入PowerShell命令等恶意指令,甚至将完整恶意程序附加在模型文件末尾。327万公开仓库中检出5个恶意模型,累计2428次下载。
编辑判断
这是首个针对本地LLM分发链的大规模投毒案例,攻击面设计得很精巧:利用的是GGUF加载器不会校验文件尾部数据的特性,而且chat template在推理时自动执行、用户端完全无感知。 Hugging Face目前对模型文件的内容安全扫描明显落后于Python依赖包(HF没有类似PyPI的恶意代码检测机制),这是一个结构性漏洞。 如果你团队在用ollama、llama.cpp或类似工具跑社区模型,建议立即加入对下载模型的template字段审计流程,或者改用经过签名的模型分发渠道;做AI Infra安全的创业者,这里有一个明确的工具缺口。
社区反馈
负面 60 条评论
核心争论:用户是否应对'可信'平台分发的大体积可执行blob保持同等安全警惕
Downloading and executing gigabyte-sized blobs would’ve been unthinkable in the past. Combine that with the size/popularity of a centralized, “trusted” (even thought it’s really not, it’s just user uploads after all) platform for distribution and it was only a matter of time until this would be
Arent linux drivers often small or medium sized blobs?
What does this have to do with Linux drivers? Most of them are open source, so no blobs at all. Some require firmware blobs, but those are also not from unknown sources.