Retrieval-Augmented Generation (RAG) systems are essential to contemporary AI applications, allowing large language models to obtain external knowledge via vector similarity search. Nevertheless, these systems encounter a significant security flaw: hubness - items that frequently appear in the top-$k$ retrieval results for a disproportionately high number of varied queries. These hubs can be exploited to introduce harmful content, alter search rankings, bypass content filtering, and decrease system performance.
We introduce hubscan, an open-source security scanner that evaluates vector indices and embeddings to identify hubs in RAG systems. Hubscan presents a multi-detector architecture that integrates: (1) robust statistical hubness detection utilizing median/Median Absolute Deviation (MAD)-based z-scores, (2) cluster spread analysis to assess cross-cluster retrieval patterns, (3) stability testing under query perturbations, and (4) domain-aware and modality-aware detection for category-specific and cross-modal attacks. Our solution accommodates several vector databases (FAISS, Pinecone, Qdrant, Weaviate) and offers versatile retrieval techniques, including vector similarity, hybrid search, and lexical matching with reranking capabilities.
We evaluate hubscan on Food-101, MS-COCO, and FiQA adversarial hubness benchmarks constructed using state-of-the-art gradient-optimized and centroid-based hub generation methods. Hubscan achieves 90% recall at a 0.2% alert budget and 100% recall at 0.4%, with adversarial hubs ranking above the 99.8th percentile. In testing, domain-scoped scanning recovered 100% of targeted attacks that evaded global detection. Production validation on 1M real web documents from MS MARCO demonstrates significant score separation between clean documents and adversarial content.
One Shot Dominance: Knowledge Poisoning Attack on Retrieval-Augmented Generation Systems
State Key Laboratory of Intelligent Game(智能游戏国家重点实验室);Science and Technology on Integrated Information System Laboratory, Institute of Software Chinese Academy of Sciences(中国科学院软件研究所综合信息系统技术国家级重点实验室);University of Chinese Academy of Sciences(中国科学院大学);Nanyang Technological University(南洋理工大学)
Hidden in the Metadata: Stealth Poisoning Attacks on Multimodal Retrieval-Augmented Generation
The City University of New York, CSI, Staten Island, NY 10314, USA(纽约城市大学,CSI,史泰登岛分校);The City University of New York, Graduate Center, New York, NY 10016, USA(纽约城市大学研究生中心)
RevPRAG: Revealing Poisoning Attacks in Retrieval-Augmented Generation through LLM Activation Analysis
School of Computer Science, Fudan University(复旦大学计算机科学学院);Department of Computer Science, Worcester Polytechnic Institute(沃思堡理工学院计算机科学系);Institute of Big Data, Fudan University(复旦大学大数据研究院)
Knowledge Poisoning Attacks on Medical Multi-Modal Retrieval-Augmented Generation
Tsinghua University(清华大学);Beijing University of Posts and Telecommunications(北京邮电大学);Northwestern Polytechnical University(西北工业大学);ETH Zurich(苏黎世联邦理工学院)
Hidden in Memory: Sleeper Memory Poisoning in LLM Agents
SPAR;ELLIS Institute Tübingen(图宾根ELLIS研究所);MPI for Intelligent Systems(智能系统马克斯·普朗克研究所);Tübingen AI Center(图宾根人工智能中心);APTA;CISPA Helmholtz Center for Information Security(信息安全海德堡中心)
ProGRank: Probe-Gradient Reranking to Defend Dense-Retriever RAG from Corpus Poisoning
Chalmers University of Technology, Sweden(瑞典查尔姆斯理工大学);University of Leeds, United Kingdom(英国利兹大学);Carl von Ossietzky University of Oldenburg, Germany(德国奥尔登堡卡尔·冯·奥西特齐大学)
EcoSafeRAG: Efficient Security through Context Analysis in Retrieval-Augmented Generation
Institute of Information Engineering, Chinese Academy of Sciences(信息工程研究所,中国科学院);School of Cybersecurity, University of Chinese Academy of Sciences(网络安全学院,中国科学院大学);State Key Laboratory of Cyberspace Security Defense(网络空间安全防御国家重点实验室)
Assessing the Operational Impact of Poisoning Attacks over Augmented 3D Point Cloud Public Datasets for Connected and Autonomous Vehicles
SAMOVAR, Télécom SudParis, Institut Polytechnique de Paris(SAMOVAR, Télécom SudParis, Institut Polytechnique de Paris);Universidad Carlos III de Madrid