arXiv:2603.22853cs.CRcs.AI2026-03被引 8

检测大模型代理应用的漏洞,覆盖代码、配置和密钥安全

Agent Audit: A Security Analysis System for LLM Agent Applications

  • 通过数据流分析与权限风险检查,识别代理代码中的安全隐患
  • 在22个样本中检出40个漏洞,误报仅6个,扫描速度低于1秒
  • 支持开发流程集成,适合关注代理系统安全的开发者使用

开发者部署大模型代理时,应审查模型、工具代码还是部署配置?实际中,多数安全问题并非源于模型权重,而是周边软件栈:未经验证的输入传递至危险操作、部署文件中暴露的凭证、过度授权的Model Context Protocol(MCP)配置。我们提出Agent Audit,一个针对大模型代理应用的安全分析系统。该系统通过代理感知的流水线,结合数据流分析、凭证检测、结构化配置解析与权限风险检查,分析Python代理代码和部署产物。结果以终端、JSON和SARIF格式输出,可直接集成到本地开发与CI/CD流程。在包含42个已标注漏洞的22个样本基准测试中,成功检出40个漏洞,仅6个误报,召回率显著优于常见SAST基线,且扫描时间低于1秒。Agent Audit开源,可通过pip安装。现场演示中,用户扫描存在漏洞的代理仓库,可直观看到系统如何识别工具函数、提示词等中的安全风险。发现项关联源码位置与配置路径,支持导出至VS Code和GitHub Code Scanning进行交互式审查。

原文摘要 · Abstract (English)

What should a developer inspect before deploying an LLM agent: the model, the tool code, the deployment configuration, or all three? In practice, many security failures in agent systems arise not from model weights alone, but from the surrounding software stack: tool functions that pass untrusted inputs to dangerous operations, exposed credentials in deployment artifacts, and over-privileged Model Context Protocol (MCP) configurations. We present Agent Audit, a security analysis system for LLM agent applications. Agent Audit analyzes Python agent code and deployment artifacts through an agent-aware pipeline that combines dataflow analysis, credential detection, structured configuration parsing, and privilege-risk checks. The system reports findings in terminal, JSON, and SARIF formats, enabling direct integration with local development workflows and CI/CD pipelines. On a benchmark of 22 samples with 42 annotated vulnerabilities, Agent Audit detects 40 vulnerabilities with 6 false positives, substantially improving recall over common SAST baselines while maintaining sub-second scan times. Agent Audit is open source and installable via pip, making security auditing accessible for agent systems. In the live demonstration, attendees scan vulnerable agent repositories and observe how Agent Audit identifies security risks in tool functions, prompts, and more. Findings are linked to source locations and configuration paths, and can be exported into VS Code and GitHub Code Scanning for interactive inspection.

安全审计LLM代理漏洞检测

Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。