← Terug naar overzicht

whichllm versions before 0.5.16 contain a code injection vulnerability in the run and snippet commands. A remote attacker who controls a HuggingFace repository can achieve arbitrary code execution by crafting a malicious GGUF filename containing double quotes or special characters. The vulnerable script generation function in cli.py interpolates HuggingFace-derived values, including GGUF variant filenames from the Hub API siblings rfilename field, directly into Python source code without proper escaping. This allows the crafted filename to break out of the generated string literal and execute injected code on the victim's machine. Exploitation occurs before any model download takes place, lowering the bar for attack. The vulnerability has been patched in version 0.5.16.

Affected products

  • whichllm

Related CVE's

  • CVE-2026-58474

Categories

  • Emerging Technologies
  • Supply Chain & Dependencies