迈向可靠的本地安全智能体:面向Linux提权任务的可验证后训练 Towards Reliable Local Security Agents: Verifiable Post-Training for Linux Privilege Escalation 预印本

⚠️ 本文为 预印本(arXiv 公开版本),尚未经过正式同行评审。作者自发公开,结论未经期刊审稿验证,阅读时请知悉。
发布时间:2026-03-18
👁️ 预览文献
💡 AI 中文简介
针对安全领域大模型多为闭源云端、难以在敏感代码上使用的问题,本研究提出两阶段后训练方法,将小型本地模型训练成安全智能体。以Linux提权为测试场景,先对4B模型做监督微调,再用可验证奖励做强化学习。在12个提权场景测试中,成功率从基线翻倍提升至93.3%,仅次于Claude Opus 4.7,且每次成功提权的推理成本降低80倍以上。
领域人工智能安全 / 大语言模型智能体
适合谁读需要一定专业背景(了解LLM训练与安全攻防基础)
核心贡献1. 提出两阶段后训练方案(监督微调+可验证奖励强化学习),将4B小模型打造成可执行多步交互推理的本地安全智能体;2. 在Linux提权任务上验证了本地小模型可达到接近顶尖闭源模型的性能,并大幅降低推理成本。
关键数据在12个Linux提权场景的留出基准上,20轮交互预算内:监督微调使基线成功率翻倍;强化学习后PrivEsc-LLM 4B成功率达93.3%,仅次于Claude Opus 4.7;每次成功提权的预期推理成本降低超过80倍。
推荐理由想用本地小模型做安全任务又怕效果差、成本高?这篇论文给出了可复现的两阶段训练配方,4B模型就能达到93.3%的提权成功率,成本还降了80倍,安全从业者和LLM智能体研究者都值得一读。
关键词["本地安全智能体", "Linux提权", "后训练", "强化学习", "可验证奖励", "小语言模型"]

原文摘要

查看英文原文摘要

LLM agents are becoming increasingly important in the security domain, but leading systems are often closed-source, cloud-based, hard to reproduce or use with sensitive code. This creates a need for small, local models that can perform security tasks under strict resource constraints, though effective methods for developing them remain unexplored. In this paper, we address this gap by proposing a two-stage post-training recipe that turns a small local language model into a security agent. To this end, we focus on Linux privilege escalation as a representative setting to systematically study the training of local models, as the task is both automatically verifiable and requires multi-step interactive reasoning. Using an experimental setup that mitigates data leakage, we post-train a small 4B model in two stages: supervised fine-tuning on traces from procedural privilege-escalation environments, followed by reinforcement learning with verifiable rewards. On a held-out benchmark of 12 Linux privilege-escalation scenarios, supervised fine-tuning doubles the baseline success rate under a tight budget of 20 interaction rounds, and subsequent reinforcement learning training improves our model, PrivEsc-LLM 4B, to 93.3% success, behind only Claude Opus 4.7 at this budget. At the same time, the expected inference cost per successful escalation decreases by more than 80x. Our findings not only show that small local models can be adapted to complex security tasks, but also document the challenges involved, offering guidance for transferring this recipe to other settings.