arXivDaily arXiv每日学术速递 周一至周五更新
感恩节,周五至周末无更新,大家顺遂。周一再来吧
arXiv 2601.21586cs.CR
收藏

ICL-EVADER: 零查询黑盒对抗攻击及对In-Context学习及其防御

ICL-EVADER: Zero-Query Black-Box Evasion Attacks on In-Context Learning and Their Defenses

University of Science and Technology of China(中国科学技术大学);Shandong University(山东大学);Monash University(蒙纳士大学)

Ningyuan He, Ronghong Huang, Qianqian Tang, Hongyu Wang, Xianghang Mi, Shanqing Guo

AI总结:

ICL-Evader提出零查询黑盒对抗攻击方法,揭示ICL的脆弱性并提供防御方案。

摘要:

上下文学习(ICL)已成为一种强大的、数据高效的文本分类范式,利用大型语言模型。然而,其对现实对抗威胁的鲁棒性仍鲜有探索。我们引入ICL-Evader,一种新颖的黑盒对抗攻击框架,其在高度实用的零查询威胁模型下运行,要求攻击生成过程中不接触模型参数、梯度或基于查询的反馈。我们设计了三种新型攻击:Fake Claim、Template和Needle-in-a-Haystack,利用LLM在处理上下文提示时的固有局限性。在情感分析、毒性及非法推广任务中评估,我们的攻击显著降低分类器性能(例如,达到95.3%的攻击成功率),远超传统NLP攻击在同一约束下的效果。为应对这些漏洞,我们系统研究了防御策略,并识别出一种联合防御配方,能有效缓解所有攻击且最小化实用损失(<5%的准确率下降)。最后,我们将防御洞察转化为自动化工具,主动强化标准ICL提示以对抗对抗性逃避。本工作对ICL进行了全面的安全评估,揭示了关键漏洞,并提供了构建更稳健系统的实用解决方案。我们的源代码和评估数据集可在:https://github.com/ChaseSecurity/ICL-Evader 公开获取。

英文摘要:

In-context learning (ICL) has become a powerful, data-efficient paradigm for text classification using large language models. However, its robustness against realistic adversarial threats remains largely unexplored. We introduce ICL-Evader, a novel black-box evasion attack framework that operates under a highly practical zero-query threat model, requiring no access to model parameters, gradients, or query-based feedback during attack generation. We design three novel attacks, Fake Claim, Template, and Needle-in-a-Haystack, that exploit inherent limitations of LLMs in processing in-context prompts. Evaluated across sentiment analysis, toxicity, and illicit promotion tasks, our attacks significantly degrade classifier performance (e.g., achieving up to 95.3% attack success rate), drastically outperforming traditional NLP attacks which prove ineffective under the same constraints. To counter these vulnerabilities, we systematically investigate defense strategies and identify a joint defense recipe that effectively mitigates all attacks with minimal utility loss (<5% accuracy degradation). Finally, we translate our defensive insights into an automated tool that proactively fortifies standard ICL prompts against adversarial evasion. This work provides a comprehensive security assessment of ICL, revealing critical vulnerabilities and offering practical solutions for building more robust systems. Our source code and evaluation datasets are publicly available at: https://github.com/ChaseSecurity/ICL-Evader .

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑