On 27 November 2026, the security site Malspark reported five GGUF models on Hugging Face that carried malware. Two accounts published them, Mir2k and timdedid, and both used the same piece of the file: the chat template that every local runtime applies before the model reads a prompt [1]. By 28 November, Hugging Face had disabled all five repositories, but one copy was still listed on Ollama [2].
The 2,428 figure in the headlines counts downloads, not victims. Anyone who runs local models in llama.cpp, LM Studio or Ollama should still check their files and pin the templates their agents use.
What is the Hugging Face GGUF malware, and who was behind it?
The Hugging Face GGUF malware is a set of five model repositories whose chat templates were rewritten to deliver malware or hijack AI agents [1]. Malspark found them in a static scan of 3,273,389 public Hugging Face model repositories on 26 November 2026, which included 226,310 GGUF repositories and 572,184 chat templates [1].
The five repositories, with Malspark's download counts as of 27 November:
| Repository | Account | Method | Downloads |
|---|---|---|---|
| Mir2k/Huihui-Qwen3.5-9B-abliterated-GGUF | Mir2k | Reply prefix with hidden executable | 1,488 |
| Mir2k/Inkling-2-Mini-Uncensored-GGUF | Mir2k | Reply prefix with hidden 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 |
The two names are account labels. Brandefense points out that they do not identify the real people behind the uploads [3].
Why is 2,428 a download count and not a victim count?
The number counts downloads, and a download is not an infection. Malspark's headline cites 2,400+ victims, but the body of the same post says Hugging Face counts downloads, not people, so the number of affected users is lower or equal [1].
Other analysts read it the same way. Spectrum writes that downloads do not establish infections [4], and Brandefense calls the figure a platform counter, not a count of distinct people or infected devices [3]. For an infection, a user had to download a Mir2k file on or after 26 November and then paste the printed command into PowerShell, or run a timdedid model inside an agent allowed to execute shell commands and send it a prompt containing What is [1].
The counter also moved fast. At the scan on 26 November, the five repositories had 1,502 downloads, and the count grew by more than half in one day, mostly on the two Mir2k models [1]. i10x read the counters again on 28 November and found 2,807 before the takedown [2].
How can a chat template turn a GGUF model into malware?
The chat template is a small Jinja2 program stored in the GGUF metadata under tokenizer.chat_template, and the runtime runs every conversation through it to build the text the model reads [1]. Text the template adds never shows in the chat window [1].
Neither campaign broke out of the template engine. C++ runtimes render templates in a restricted engine with no Python behind it, so the attackers used ordinary template logic to add hidden instructions [1]. The model then answers normally, while following an order the user never saw.
Mir2k paired this with a second trick specific to GGUF. The header and tensor table say exactly where the model data ends, and runtimes such as llama.cpp and LM Studio read only those byte ranges [1]. Bytes appended after the last tensor are ignored, change nothing about how the model behaves, and raise no warning, so an attacker can park a whole executable there [1].
The template method is not new. Pillar Security showed hidden instructions in GGUF chat templates in July 2025, but Malspark found no earlier public report of the full Mir2k combination in a real attack [1].
How did the Mir2k attack work?
Mir2k planted the payload first and switched it on days later. On 22 November, the account created 14 repositories; 12 were empty placeholders named after expected releases such as Qwen4-27B, DeepSeek-V4, Llama-4-Scout and gemma-4-27b [1].
The timeline, from the repository history [1]:
- 22 November: the Huihui model is uploaded with a Windows executable appended after its last tensor, plus about half a megabyte of filler, and a clean template.
- 24 November: the Inkling model follows with the same executable compressed with raw Deflate, which removes every file signature, again with a clean template.
- 26 November, morning: both templates are replaced within about an hour. Nine hours later they are replaced again, this time searching the whole user profile for the model file.
The armed template adds a French system message telling the model to begin every reply with one PowerShell line, copied character by character [1]. That line finds the largest .gguf file in the user profile, reads its last bytes, writes them to %TEMP%\d.exe and starts it [1]. Copies downloaded before 26 November hold the payload but not the trigger [1].
What does the ollie trojan do?
Malspark calls the implant ollie. Both models unpack the same 11.47 MB Windows x64 program, and 10.25 MB of that is a bundled copy of Tor [1]. According to Malspark's static analysis, it does the following [1]:
- Exits if it finds VirtualBox, VMware or Sandboxie drivers, or usernames such as
sandboxandtest. - Persists through a scheduled task that runs every 10 minutes, two watchdog processes, and registry keys, and marks its process as critical, so ending it crashes Windows.
- Talks to its operator over a Tor onion service and sends saved passwords from Chrome, Edge and Brave.
- Targets the Phantom and MetaMask wallet extensions, and supports keylogging, clipboard reading, screenshots, screen streaming and webcam capture.
- Mines Monero with RandomX over Tor when the machine is idle.
It stores its files in folders named ollie under AppData\Roaming, close enough to Ollama to look familiar [1]. In Malspark's tests, antivirus engines and pickle scanners raised no alert on either live Mir2k file [1].
How did the timdedid templates target AI agents?
The timdedid account went after agents with shell access instead of people. On 21 and 22 November, the account published three byte-identical copies of a Qwen3 1.7B model aimed at security users, plus an Ollama mirror named timdedid/qwen3-1.7b-cyber [1].
The 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 to call its powershell tool, download a script into C:\Windows\Temp\payload.ps1 and run it in a hidden window [1]. The README advised against replacing the embedded template, which kept the trigger in place [1].
A plain chat user sees nothing. The risk falls on coding and desktop agents that may run commands on their own [2]. Malspark did not recover the second-stage script, so what it would have installed is unknown [1].
Are the malicious models still online?
Not on Hugging Face. At 14:22 CET on 28 November, the Hugging Face API marked all five repositories as disabled for breaching its content policy, i10x reports [2]. The Mir2k Huihui page now reads "Access to this model has been disabled" [5].
The Ollama copy stayed online. i10x found timdedid/qwen3-1.7b-cyber still listed with 42 downloads, read the first 16 MB of the file without loading it, and found the same hidden directive [2]. The site did not test whether a given Ollama version applies that embedded template [2].
Spectrum adds a detection gap: the printed command shows up only where chat transcripts or agent tool calls are logged, and endpoint telemetry can show the unpacking but not that a model caused it [4]. So a takedown on the hub does not tell you whether a machine that already pulled the file ran the payload.
What should local LLM users do now?
Start with the files you already have, then change how your tools handle templates. The steps below come from Malspark, i10x and Brandefense:
- Search your model folders. Look for the five repository names and the Ollama tag
timdedid/qwen3-1.7b-cyberin llama.cpp and LM Studio folders and inollama list, and delete them, including copies from before 26 November [2]. - Never run a command a model suggests without reading it. Malspark advises treating every model-suggested command as untrusted [1]. A command at the top of every answer, unrelated to your question, is a red flag on its own [2].
- Pin a reviewed template when the model has tools. Pass a template you have read with
--chat-template-filein llama.cpp, or setTEMPLATEin an Ollama Modelfile, so the embedded one is out of the loop [1]. - Scan GGUF files before loading them. Malspark's open-source tool gguf-radar checks the template and the bytes after the last tensor without running anything, and can write a clean copy with identical weights [1]. i10x gives the install line as
pip install git+https://github.com/Root0ne/gguf-radar[2]. - Log what agents run. Brandefense suggests recording shell-tool calls and checking for actions that follow right after model output [3].
If a Windows machine ran a Mir2k model downloaded on or after 26 November, check for an ollie folder under AppData\Roaming, a d.exe in the temp folder, a scheduled task that repeats every ten minutes and a Tor listener on port 9050 [2]. Because ending the process crashes Windows, i10x advises isolating the PC and reinstalling, then changing saved browser passwords from a clean device and moving wallet funds to a new seed [2].
Which models are safe to download?
The usual advice has been to prefer GGUF or Safetensors over pickle files, and a GGUF loader still never executes code, but this campaign went around that rule rather than breaking it [2]. The format alone is not a safety signal, so prefer models from publishers you can identify, and be careful with unofficial "uncensored" uploads in the first days after a big release, which is the pattern Mir2k's empty placeholder repositories point to [2].
Malspark asks model hubs to reject GGUF files with bytes after the last tensor or non-zero padding [1]. As of 28 November, i10x found no announcement from Hugging Face on that change [2].



