arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2410.02644cs.CRcs.AI
收藏

Agent Security Bench (ASB):基于LLM的智能体中攻击与防御的形式化与基准测试

Agent Security Bench (ASB): Formalizing and Benchmarking Attacks and Defenses in LLM-based Agents

Zhejiang University(浙江大学);Rutgers University(罗格斯大学)

Hanrong Zhang, Jingyuan Huang, Kai Mei, Yifei Yao, Zhenting Wang, Chenlu Zhan, Hongwei Wang, Yongfeng Zhang

AI总结:

本文提出Agent Security Bench (ASB)框架,形式化并基准测试了基于LLM的智能体攻击与防御,涵盖10场景、400余工具及27种方法,揭示高达84.30%的攻击成功率及防御局限,并引入平衡实用与安全的新指标。

摘要:

尽管由大型语言模型(LLMs)驱动的基于LLM的智能体能够利用外部工具和记忆机制解决复杂的现实任务,但它们也可能引入严重的安全漏洞。然而,现有文献并未全面评估针对基于LLM的智能体的攻击与防御。为了解决这一问题,我们引入了Agent Security Bench (ASB),这是一个旨在形式化、基准测试和评估基于LLM的智能体攻击与防御的综合框架,包含10个场景(如电子商务、自动驾驶、金融)、针对这些场景的10个智能体、超过400个工具、27种不同类型的攻击/防御方法以及7个评估指标。基于ASB,我们在13个LLM主干上对10种提示注入攻击、1种记忆中毒攻击、1种新颖的Plan-of-Thought后门攻击、4种混合攻击以及11种相应的防御进行了基准测试。我们的基准测试结果揭示了智能体运行不同阶段(包括系统提示、用户提示处理、工具使用和记忆检索)的关键漏洞,最高平均攻击成功率达84.30%,但当前防御效果有限,揭示了社区在智能体安全方面亟待开展的重要工作。我们还引入了一个新指标来评估智能体平衡实用性与安全性的能力。我们的代码可在 https://github.com/agiresearch/ASB 找到。

英文摘要:

Although LLM-based agents, powered by Large Language Models (LLMs), can use external tools and memory mechanisms to solve complex real-world tasks, they may also introduce critical security vulnerabilities. However, the existing literature does not comprehensively evaluate attacks and defenses against LLM-based agents. To address this, we introduce Agent Security Bench (ASB), a comprehensive framework designed to formalize, benchmark, and evaluate the attacks and defenses of LLM-based agents, including 10 scenarios (e.g., e-commerce, autonomous driving, finance), 10 agents targeting the scenarios, over 400 tools, 27 different types of attack/defense methods, and 7 evaluation metrics. Based on ASB, we benchmark 10 prompt injection attacks, a memory poisoning attack, a novel Plan-of-Thought backdoor attack, 4 mixed attacks, and 11 corresponding defenses across 13 LLM backbones. Our benchmark results reveal critical vulnerabilities in different stages of agent operation, including system prompt, user prompt handling, tool usage, and memory retrieval, with the highest average attack success rate of 84.30\%, but limited effectiveness shown in current defenses, unveiling important works to be done in terms of agent security for the community. We also introduce a new metric to evaluate the agents' capability to balance utility and security. Our code can be found at https://github.com/agiresearch/ASB.

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

↑