From Similarity to Vulnerability: Key Collision Attack on LLM Semantic Caching
Not on the map. Why?
Abstract (arXiv)
Semantic caching has emerged as a pivotal technique for scaling LLM applications, widely adopted by major providers including AWS and Microsoft. By utilizing semantic embedding vectors as cache keys, this mechanism effectively minimizes latency and redundant computation for semantically similar queries. In this work, we conceptualize semantic cache keys as a form of fuzzy hashes. We demonstrate that the locality required to maximize cache hit rates fundamentally conflicts with the cryptographic avalanche effect necessary for collision resistance. Our conceptual analysis formalizes this inherent trade-off between performance (locality) and security (collision resilience), revealing that semantic caching is naturally vulnerable to key collision attacks. While prior research has focused on side-channel and privacy risks, we present the first systematic study of integrity risks arising from cache collisions. We introduce CacheAttack, an automated framework for launching black-box collision attacks. We evaluate CacheAttack in security-critical tasks and agentic workflows. It achieves a hit rate of 86% in LLM response hijacking and can induce malicious behaviors in LLM agent, while preserving strong transferability across different embedding models. A case study on a financial agent further illustrates the real-world impact of these vulnerabilities. Finally, we discuss mitigation strategies.
Key facts. Cited by 3 papers in the map (data through 7 Oct 2026). Builds on 25 of its 57 references that are in the map. First posted on arXiv 30 Jan 2026.
Builds on
25 of 57 references.
References · 25
- 2019Exploring the Limits of Transfer Learning with a Unified Text-to-Text Transformercited by 14,491
- 2025Qwen3 Technical Reportcited by 8,195
- 2020Dense Passage Retrieval for Open-Domain Question Answeringcited by 3,779
- 2023Universal and Transferable Adversarial Attacks on Aligned Language Modelscited by 2,914
- 2023A Survey of Large Language Modelscited by 2,537
- 2022Survey of Hallucination in Natural Language Generationcited by 2,056
- 2023SGLang: Efficient Execution of Structured Language Model Programscited by 1,107
- 2018Generating Natural Language Adversarial Examplescited by 422
- 2023Detecting Language Model Attacks with Perplexitycited by 411
- 2023Prompt Cache: Modular Attention Reuse for Low-Latency Inferencecited by 255
- 2024A Survey on Efficient Inference for Large Language Modelscited by 197
- 2021A Survey on Locality Sensitive Hashing Algorithms and their Applicationscited by 40
13 more
- 2024The Early Bird Catches the Leak: Unveiling Timing Side Channels in LLM Serving Systemscited by 29
- 2024GPT Semantic Cache: Reducing LLM Costs and Latency via Semantic Embedding Cachingcited by 21
- 2025Auditing Prompt Caching in Language Model APIscited by 19
- 2025Shadow in the Cache: Unveiling and Mitigating Privacy Risks of KV-cache in LLM Inferencecited by 19
- 2024SCALM: Towards Semantic Caching for Automated Chat Services with Large Language Modelscited by 16
- 2024InputSnatch: Stealing Input in LLM Services via Timing Side-Channel Attackscited by 16
- 2025vCache: Verified Semantic Prompt Cachingcited by 15
- 2024MeanCache: User-Centric Semantic Caching for LLM Web Servicescited by 14
- 2025SentenceKV: Efficient LLM Inference via Sentence-Level Semantic KV Cachingcited by 9
- 2025Advancing Semantic Caching for LLMs with Domain-Specific Embeddings and Synthetic Datacited by 7
- 2025ContextCache: Context-Aware Semantic Cache for Multi-Turn Queries in Large Language Modelscited by 7
- 2025SemShareKV: Efficient KVCache Sharing for Semantically Similar Prompts via Token-Level LSH Matchingcited by 6
- 2025Semantic Caching of Contextual Summaries for Efficient Question-Answering with Language Modelscited by 5
Built on by
Citing papers per year: 2026: 3.
3 papers.
Similar, not cited
Close in wording, no citation either way
- 2026Detokenization Leaks: Reconstructing Local LLM Outputs From Cache Traces
- 2026Agent-Assisted Side-Channel Attacks on Non-Prefix KV Cache in RAG
- 2026Governing the KV Cache: Preventing Timing Side-Channel Leakage in Multi-Tenant LLM Inference
- 2025Can Transformer Memory Be Corrupted? Investigating Cache-Side Vulnerabilities in Large Language Models
- 2026Securing LLMs in the Wild: Privacy and Security Challenges at the Edge
- 2026HijackKV: New Threat in Position-Independent KV Cache Reuse
- 2025Category-Aware Semantic Caching for Heterogeneous LLM Workloads
- 2026Characterizing Contention-Induced Reliability Collapse in KV-Cache Timing Side Channels for Multi-Tenant LLM Serving