Malicious GGUF Models on Hugging Face: 5 Poisoned Models, 2,428 Downloads — Check Yours Now
Five malicious GGUF models on Hugging Face were downloaded 2,428 times before anyone caught them, according to a Malspark report published on 27 November 2026 — two days ago. Hugging Face has since disabled all five, but a copy of one was still listed on Ollama on the morning of 29 November. If you run local models, check your downloads now: the poison was not in the weights, but in the chat template and in bytes hidden after the last tensor, where loaders never look.
What Malspark found
Security researcher Root0ne, writing as Düzgün on Malspark, scanned all 3,273,389 public model repositories on Hugging Face on 26 November 2026, including 226,310 GGUF repositories holding 2.56 petabytes of weights. The scan parsed 572,184 chat templates statically, Five repositories remained, all still online on 27 November, from two accounts.
One figure needs care: 2,428 is a count of download events, not victims — Hugging Face counts downloads, not people. By 28 November the combined total had risen to 2,807.
| Repository | Campaign | Method | Downloads (27 Nov) |
|---|---|---|---|
| Mir2k/Huihui-Qwen3.5-9B-abliterated-GGUF | Mir2k | Reply prefix plus hidden executable | 1,488 |
| Mir2k/Inkling-2-Mini-Uncensored-GGUF | Mir2k | Reply prefix plus compressed executable | 458 |
| timdedid/qwen3.8-cyber-uncensored | timdedid | Agent tool hijacking | 271 |
| timdedid/qwen3-cyber-UNCENSORED-2 | timdedid | Agent tool hijacking | 136 |
| timdedid/qwen3-cyber-UNCENSORED | timdedid | Agent tool hijacking | 75 |
| Total | 2 actors | 2,428 |
Image credit: Malspark — where data can hide inside a GGUF file.
How the attack works: two tricks, not one
GGUF is the file format most people use to run large language models locally in tools such as llama.cpp, Ollama and LM Studio. Every GGUF file carries a chat template — a small Jinja2 program stored under the metadata key tokenizer.chat_template — which the runtime applies to every prompt before the model reads it. Malspark calls this abuse "chat template poisoning": the model answers normally, while the template quietly adds instructions the user never sees.
The first trick is the poisoned template. In the timdedid models, a trigger phrase in the user's message makes the template insert a fake system directive. In the Mir2k models, it adds a system message telling the model to begin every answer with one PowerShell line, which a user may copy and run. The attacks need no template-engine escape — ordinary logic is enough, because the added text never appears on screen.
The second trick is specific to GGUF. A GGUF file's header and tensor table define exactly where the model data ends, and runtimes read only the byte ranges the header points to, ignoring everything after the last tensor with no warning. An attacker can therefore append a whole Windows executable after the weights, and the model still loads and chats normally. Malspark says this combination — an executable appended after the last tensor, plus a template switched on days later — has no earlier public report in live uploads. In Malspark's tests, antivirus and pickle scanners raised no alert on either live Mir2k file.
Image credit: Malspark — timeline of the Mir2k campaign.
The Mir2k campaign: plant first, arm later
Mir2k is a new Hugging Face account with French traces throughout its model card, template, commit messages and malware strings. On 22 November it created 14 repositories; twelve are empty placeholders named after expected releases such as Qwen4-27B, ready to be filled when those models appear.
The timeline is what makes this campaign sneaky. On 22 November, Mir2k uploaded the Huihui-Qwen3.5-9B model with the executable already appended after its last tensor — but with its original, clean template. On 24 November, the Inkling-2-Mini model followed with the same executable in compressed form, again with a clean template. On 26 November, both templates were replaced twice, the second version searching the whole user profile. Downloads made before 26 November therefore contain the payload but not the trigger. As Malspark puts it: "The victim never downloads anything except the model itself."
The armed template adds a French system message telling the model to begin every reply with one PowerShell line, then answer normally. That line finds the largest .gguf file in the user profile, reads its hidden bytes and writes them to %TEMP%\d.exe. Both models unpack to the same 11.47 MB Windows program, which Malspark calls "ollie" — 10.25 MB of it bundled Tor 0.4.9.16. Once started, ollie exits on virtual machines; on a real machine, a scheduled task runs it every 10 minutes, two watchdog processes keep it alive, and its process is marked as critical, so ending it crashes Windows. It steals saved passwords from Chrome, Edge and Brave, targets Phantom and MetaMask wallets, logs keys, reads the clipboard, captures screen and webcam, and mines Monero when idle. Its folders are named "ollie" under AppData\Roaming. One step failed: its fodhelper.exe UAC bypass paths were compiled without backslashes, so Windows never finds them.
The timdedid campaign: aimed at AI agents
The second account, timdedid, published three byte-identical copies of a Qwen3 1.7B model aimed at security users on 21 and 22 November, together with an Ollama mirror named timdedid/qwen3-1.7b-cyber. Its template is the official Qwen3 template with one addition: when the user's latest message contains "What is", it inserts a fake [SYSTEM DIRECTIVE] telling an agent with shell access to download a script to C:\Windows\Temp\payload.ps1 and run it hidden. A plain chat user sees nothing; the target is an agent with shell access. The README even advises against replacing the embedded template, which keeps the trigger in place.
What that second-stage script would have installed is unknown — Malspark did not recover it. The trap is proven; its payload is not. Nor does anything happen on its own: simply loading one of these GGUF files executes nothing, because the loader never runs trailing bytes. The Mir2k payload needs a person to copy and run the PowerShell line the model prints; the timdedid trap needs an agent with shell access to act on the hidden directive. Downloading the file is exposure, not infection — but the file on disk stays a live risk.
Hugging Face disabled all five — but one copy is still on Ollama
Hugging Face has disabled all five. An independent check of the Hugging Face API at 14:22 CET on 28 November found all five marked disabled for a content-policy breach, and neither account showed any public model afterwards. The takedown does not remove copies already downloaded, or files hosted elsewhere.
Malspark's report also lists an Ollama mirror, timdedid/qwen3-1.7b-cyber. Independent checks found it still listed on Ollama: 42 downloads on Saturday 28 November, and 228 by 08:53 AM ET on Sunday 29 November, with the hidden directive still in its template. Ollama has not been verified to have removed the copy. Treat that listing as live until Ollama itself says otherwise.
Image credit: Screenshot of huggingface.co via Analytics Vidhya.
How to check if you are affected
If you downloaded any local model in the last two weeks, work through these steps first.
- Search your model folders for the five names. Look for the two Mir2k repos and the three timdedid repos in your llama.cpp and LM Studio directories, and run
ollama listfor timdedid/qwen3-1.7b-cyber. Delete any match, including copies from before 26 November. - Scan every GGUF file you keep. Install Malspark's open-source scanner, gguf-radar, with
pip install git+https://github.com/Root0ne/gguf-radarand rungguf-radar scan ./model.gguf. It checks the template and trailing bytes without running anything, andsanitizerebuilds a clean file with unchanged weights. - Check Windows machines that ran a Mir2k model. Look for an "ollie" folder under AppData\Roaming, a d.exe in the temp folder, a scheduled task repeating every 10 minutes and a local Tor listener on port 9050. Do not just kill it — isolate the PC and reinstall.
- Rotate what ollie targets. Change every password saved in Chrome, Edge or Brave from a clean device, and move Phantom or MetaMask funds to a new wallet whose seed phrase was never typed on the affected PC.
- Pin the template for agents. Pass a reviewed template with
--chat-template-filein llama.cpp, or set TEMPLATE in an Ollama Modelfile. Do not let an agent run shell commands from a community model without confirmation. - Treat model output as untrusted. A command at the top of every answer, unrelated to your question, is a red flag. Never paste a command a model prints into a terminal without reading it first.
INORYVA has covered similar supply-chain cases before: the tampered Claude Code extension that spread malware through svc-telemetry, the AI scan that found three Bitcoin Core vulnerabilities, the time Binance confirmed a $6.3 billion security breach, and the reported DeepSeek and Moonshot distillation case. In AI tooling, the download is the trust decision — check it before the run.
Key Takeaways
- Malspark's 26 November scan of 3,273,389 public Hugging Face repositories found 5 malicious GGUF models from 2 accounts, with 2,428 downloads — downloads, not victims.
- Mir2k hid an 11.47 MB Windows trojan called ollie after the last tensor of two "uncensored" models, then switched on a poisoned template on 26 November that makes the model print a PowerShell line to unpack it.
- timdedid's three Qwen3 1.7B copies target AI agents: a "What is" trigger inserts a fake directive ordering an agent to download and run a script, whose payload was never recovered.
- Hugging Face disabled all five by 28 November, but the Ollama mirror timdedid/qwen3-1.7b-cyber was still listed on 29 November.
- Check your model folders for the five repo names, delete any match, scan kept files with gguf-radar, and never paste a command a model prints.
Conclusion
The GGUF malware incident is a warning about where trust now sits in local AI. The models answered normally, the loaders raised no warning, and the scanners stayed quiet — the attack lived in the parts of the file nobody inspects: the chat template and the bytes after the last tensor. Hugging Face acted within a day of the 27 November report, but 2,428 download events had already happened, and at least one copy is still live on Ollama. The fix is unglamorous and it works: check the five names, scan with gguf-radar before you load, and treat anything a model tells you to run as untrusted.


Comments
Post a Comment