Mirage: Provable Defense Against LLM KV Cache Timing Side Channels with Topology-Aware Isolation
Abstract
Large Language Models (LLMs) are increasingly deployed as shared multi-tenant services, relying on advanced optimizations like KV cache and prefix sharing to improve throughput and reduce latency. However, these optimizations introduce a critical vulnerability: attackers can exploit time-to-first-token (TTFT) variations between KV cache hits and misses to infer sensitive prompt tokens via prefix-matching side-channel attacks. Existing defenses indiscriminately restrict cross-tenant cache sharing, which incurs prohibitive performance overhead and negates the fundamental efficiency benefits of the KV cache. We propose Mirage, a topology-aware emission obfuscation framework that provably bounds timing leakage without sacrificing the performance gains of cache sharing. Instead of stalling the GPU or forcing redundant recomputations, Mirage delays token emission at the gateway so the attacker observes a natural cache miss distribution, while the GPU seamlessly continues serving other requests at full speed. Mirage uses a Privacy Odometer that persistently tracks the topological novelty of prefix fan-out expansions to distinguish aggressive probing from benign traffic. Once a prefix exceeds a safety threshold, Mirage engages a two-phase policy that uses a dynamic estimator to pad the TTFT to a calibrated cache-miss baseline. On a 500-sample public corpus across three models, Mirage suppresses the timing side-channel to near the random-guessing floor, while maintaining a significantly lower TTFT than defense baselines. We further show that Mirage withstands a strong adaptive adversary and the same principle carries over to semantic caching layers.
Create a lesson
Metadata
- Categories
- cs.CR, cs.AI
Related papers
Your Camera Can Hear You: Side-Channel Acoustic Eavesdropping via Android Camera2 Metadata
Shared title terminologycs.CRGuangyuan Ji, Wenjing Wang, Bingsheng Zhang
Inferring Sensitive Events in Multi-Mode Cyber-Physical Systems via Scheduling Side Channels
Shared title terminologycs.CRYifan Cai, Linh Thi Xuan Phan
Protecting Sensitive Knowledge Under LLM Unlearning: The Proxy Threat and a Superposition-Aware Defense
Shared title terminologycs.CRJiayang Li, Tianqing Zhu, Longxiang Gao et al.
Domain-Invariant and Language-Model-Assisted Acoustic Side-Channel Attacks on Keyboards
Shared title terminologycs.CRBikrant Bikram Pratap Maurya
Where Agent Defenses Fail: A Case Study of Policy Compositions and Measurement Limits
Shared title terminologycs.CRKunwar Singh Sangram, Krishna Mohan Guda Nagavenkata Srinivasa
Leaks by Installments: Cross-Session Answer Disclosure in LLM Tutors and a Ledger-Based Defense
Shared title terminologycs.CRVenkata Muttineni, Karthik Narayan, Christopher David