ai ml6 min read

LLMs on Kubernetes Part 1: Understanding the Threat Model

6 similar posts
  • Ollama
  • Open WebUI
  • ChatGPT
  • Claude
  • LiteLLM
  • Kong AI Gateway
  • Portkey
  • kgateway
  • Gloo
  • mirrord

AI Summary

Running large language models (LLMs) on Kubernetes introduces distinct threat models that standard container scheduling and isolation cannot solve. While Kubernetes successfully manages workload lifecycles, it cannot evaluate natural language prompts, monitor probabilistic outputs for data leaks, or restrict tool privileges. The article maps four critical OWASP LLM risks—Prompt Injection, Sensitive Information Disclosure, Supply Chain risks, and Excessive Agency—to familiar infrastructure challenges like input validation, secret scrubbing, artifact provenance, and least-privilege access, arguing that these policies belong in a dedicated gateway layer rather than the inference engine.

Key Takeaways

  • Kubernetes provides effective scheduling and pod isolation, but remains blind to application-layer semantics, prompt intents, and probabilistic model behavior.
  • The OWASP Top 10 for Large Language Model Applications provides a foundational framework for categorizing risks such as prompt injection, supply chain tampering, and excessive agency.
  • Inference servers like Ollama focus strictly on running models efficiently; security policies, prompt filtering, and token validation must be handled by an independent gateway layer.

Why it matters

As enterprises increasingly host LLMs locally on Kubernetes clusters using tools like Ollama and Open WebUI, relying solely on infrastructure-level isolation is insufficient. Understanding the LLM threat model enables engineers to design proper application-layer defenses, implement appropriate policy gateways, and prevent critical vulnerabilities like data leakage and unverified model supply chains.

Conversation0

What would you add from your experience?

Checking your session…

Every good conversation starts with one perspective.