Skip to main content

⬅️ Back to README

Security Threat Model and Controls

OWASP Top 10 for LLMs Mapping​

OWASP ThreatLLM-Shield-Proxy Mitigation
LLM01: Prompt InjectionPattern neutralization for selected instruction-like text in tool content. Not a general prompt-injection defense.
LLM02: Insecure Output HandlingLimits JSON/SSE parsing depth. Sanitizes markdown image URLs to prevent exfiltration.
LLM04: Model Denial of ServiceBuffer, recursion, and payload size limits mitigate basic resource exhaustion attacks.
LLM06: Sensitive Information Disclosure3-tier detection cascade redacts recognized PII before egress.
LLM07: Insecure Plugin DesignEnforces JWT/DPoP authentication and RBAC policies on tool calls.
LLM08: Excessive AgencyMCP tool allowlist policies. Agent loop circuit breaker stops repetitive polling.

22-Vector Threat Matrix Verification​

The project includes automated adversarial testing for specific threat vectors.

Threat VectorProxy Defense Mechanism
Streaming Packet SplittingSliding-window prefix-overlap buffer holds incomplete tokens.
Early Stream TerminationDeterministic buffer flush on upstream disconnect.
Unicode SmugglingStrips zero-width characters and normalizes Unicode.
BiDi EvasionStrips Right-to-Left Overrides before regex matching.
Base64 ObfuscationSkips inspection inside long Base64 payloads to prevent ReDoS, while preserving boundary detection.
Markdown Image ExfiltrationSanitizes outbound query parameters in markdown image URLs.
JSON Recursion BombStrict parsing depth limit (max_depth=20).
Slowloris Memory Exhaustion64KB buffer limit and 1MB SSE line limit.
SSRF / DNS RebindingResolves all domains in tool calls and rejects loopback, link-local, and cloud metadata IPs.
Audit Log TamperingSHA-256 hash chaining and Ed25519 digital signatures.
DPoP Proof ReplayRFC 9449 jti replay cache rejects reused cryptographic proofs.

Vulnerability Reporting​

The project publishes security fixes for the latest release line only.

If you discover a security vulnerability, do not open a public GitHub issue.

Report the issue confidentially to:

  • Contact: Ninad Phalak
  • Email: ninad.phalak@gmail.com

Please include reproduction steps and an impact assessment. We aim to respond within 48 hours.