Prompt Injection Vulnerabilities Found in Ollama and HF Tools

BankApprehensive7612 · reddit · 2026-08-07

A security researcher has disclosed prompt injection vulnerabilities across several popular LLM tools. By inserting special HTML-like sequences into user input, attackers can override system prompts.

Affected projects include Ollama, Hugging Face Transformers, and Google Gemma. The author warns that when combined with long-memory and multi-agent runtimes, this vulnerability can easily escalate into dangerous code execution issues.

As a temporary workaround, developers are advised to throw errors when special sequences (like <|turn> or <|imstart|>) are detected in user input.

Original post →

More from Safety

Safety channel →