Searcharxiv⌕ Search

arXiv · 2609.35908

Similarity Is Not Validity: Defending LLM Semantic Caches Against Poisoning

Abstract

Semantic caches reduce LLM serving costs by reusing previously generated answers for semantically similar queries. However, retrieval is based solely on embedding similarity between the incoming query and cached queries. This design enables cache poisoning: an attacker can cache a malicious response under a query with high cosine similarity to benign requests. The vulnerability stems from a gap between retrieval similarity and answer validity. From an information-bottleneck perspective, query embeddings can lose information needed to distinguish valid from invalid cache hits, which limits any matching algorithm that uses only these embeddings. We propose a novel defense that recovers this necessary information from the raw text of the cache key. Across poisoning attacks, adversarial queries share a rewrite-residual structure: they pair a rewrite of the target query with residual content. The rewrite maintains high similarity, while the residual elicits the malicious response. Deleting the residual makes the remaining rewrite more similar to the incoming query. We exploit this structure using Deletion Gain to search shortened variants of the cached query for similarity gains, and an Answer Check to test whether the removed text contributes to the stored answer. We prove that Deletion Gain stays positive when a deletion leaves text close enough to the rewrite, and we search for such deletions with a sliding window. Across three poisoning attack classes, our defense blocks 82.0% to 98.2% of poisoned entries at a 5% false-positive rate, with negligible serving overhead.

Explore related subjects

Keep this discovery

Explore connections, maps & timelines

BibTeXRIS

Zihan Zhang, Shuangjie Yao, Zesen Liu, Zhixiang Zhang, Wai Ip Lai, Dung Hiu Hilton Yeung, Chun Kit Zhang, Fuchen Ma, Yuanyuan Yuan, Yu Jiang, Dongdong She. 2026-09-28. Similarity Is Not Validity: Defending LLM Semantic Caches Against Poisoning. https://arxiv.org/abs/2609.35908

Cite the original work for its findings. Save a collection to share your selection of sources.

KEEP EXPLORING

Related papers

When Authentication Is Not Enough: Breaking Behavior-Based Driver Authentication Systems

Researchers extensively explored behavior-based driver authentication systems in vehicles. Pushed by advances in Artificial Intelligence (AI), these systems employ powerful models to identify drivers based on unique biometric behaviors. However, existing work prioritizes AI performance metrics, neglecting secure integration with real-world automotive environments and the threat of adversarial attacks that can fool the authentication system. In this paper, we propose for the first evasion attacks against behavior-based driver authentication systems, allowing an attacker to impersonate the legitimate driver. Our attacks exploit long-standing CAN bus weaknesses that allow the injection of forged frames without jeopardizing the attacker's safety while stealing the vehicle. When legitimate data samples are available, we propose \textbf{SMARTCAN}, a safety-aware replay attack. If the attacker can only use the authenticator as an oracle, we propose \textbf{GANCAN}, which trains a Generative Adversarial Network's generator using reinforcement learning on the authenticator's responses. Our attacks achieve a success rate up to 100\% against all the considered models and, in the worst case, require 22 minutes to steal a vehicle. Acknowledging our identified vulnerabilities, we discuss the requirements for a safe and effective deployment of these systems in real-world scenarios.

cs.CR↗

A CRT Framework for Montgomery-Type Modular Reduction

Montgomery reduction is one of the fundamental techniques for efficient modular arithmetic. In this paper, we present a new interpretation of Montgomery-type reduction algorithms through the Chinese Remainder Theorem (CRT). We show that the classical Montgomery reduction algorithm arises naturally from the CRT identity, which further reveals a common algebraic invariant underlying a family of Montgomery-type reduction algorithms. This leads to a unified CRT framework for their derivation, analysis, and verification. Within this framework, several recent variants of Montgomery reduction are interpreted in a uniform manner, their correctness proofs become transparent, and their differences are seen to lie only in the representation of the correction term and the evaluation of a common CRT quotient. The framework also provides a convenient tool for analyzing existing reduction algorithms, allowing incorrect parameter ranges to be identified and counterexamples to be constructed naturally.

cs.CR↗

Cover-Parameterised Multichannel Hybrid Steganography: Compositional Security, Detectability, and Robustness

Secure covert communication across multiple observable channels requires concealing both the transmitted objects and the relationships among them while resisting active manipulation. This paper introduces a cover-parameterised multichannel hybrid steganographic framework that combines message-independent cover synthesis with adaptive cover modification. Synthesised cover-parameter objects condition a keyed QIM-style mask, and the resulting masked payload is embedded into an existing image using QIM-Fused-CF, which integrates fused S-UNIWARD/MiPOD distortion costs, complexity-aware region refinement, SLIC-guided constraints, and syndrome-trellis coding. The protocol distributes each authenticated epoch across three channels and incorporates freshness verification, bounded scheduling, synchronisation, and re-synchronisation. We formalise cover-parameter indistinguishability $(\textsf{CP-IND})$ and unlinkability $(\textsf{CP-UNL})$, multichannel trace indistinguishability $(\textsf{IND-STEGO-MC})$, and an active $\textsf{MC-ATTACK}$ model covering message recovery, replay, and authenticated substitution. The resulting bounds separate masking, embedding, scheduling, authentication, and receiver-state contributions. Experiments on 10,000 BOSSBase images achieve zero bit-error rate for all valid embeddings and structural similarity above $0.9995$ across payloads of $0.10$--$0.40$~bpp. At $0.10$ and $0.20$~bpp, SRM+EC, Ye-Net, and Yedroudj-Net produce AUC values of $0.5017$--$0.5444$ and $0.5424$--$0.5678$, respectively, whereas detectability increases substantially at $0.40$~bpp. These results identify a practical low-to-moderate-payload operating region and demonstrate that secure multichannel steganography requires the joint design of synthesis, masking, embedding, scheduling, authentication, and receiver state.

cs.CR↗