Reinforcement Building: Toward Self-Improving Harnesses for Defensive Software Security Agents
Amine Lbath, Aurelien Delaitre, Vadim Okun, Massih-Reza Amini
Abstract
Large language model (LLM) agents have become capable of discovering and exploiting vulnerabilities in real-world software with limited human intervention. This widens an asymmetry that already favors attackers, who need a single overlooked vulnerability, whereas defenders must find and fix vulnerabilities before they are exploited. Defenders therefore need markedly better defensive repair agents to keep up with the growing number of discovered vulnerabilities. With each new generation of models, researchers build multi-agent harnesses that outperform a single-agent baseline. These harnesses, however, are often tuned to a specific model version and may bring smaller gains, or even performance degradation, when used with another model. With the increasing speed at which new models are released, rebuilding a harness by hand for each new generation appears impractical. We present Reinforcement Building (RB), a framework that automatically builds the harness of a defensive agent for a given model. In each round, RB runs the current harness on training vulnerabilities and grades every patch with an execution oracle. An optimizer model then proposes edits to its agents, tools, delegation edges and memory, and a validation gate keeps them only if they strictly improve the harness. Without updating any weights, RB improves the repair success rate of two open-weight models on three held-out benchmarks by 58% to 750% relative to the base harness (8.5 to 36.1 percentage points). On SEC-bench, it outperforms ContraFix, the state-of-the-art harness builder for vulnerability repair, by 21% relative for both models. Compared with reinforcement learning with verifiable rewards (RLVR) on the same data, RB needs 7.4 times fewer training episodes to reach the same success rate on Gemma-4-31B.
Create a lesson
Metadata
- Categories
- cs.CR, cs.AI, cs.SE
Related papers
PRECEPT: Security Self-Improvement of Coding Agents via Evolving Principles
Shared title terminologycs.CRKeyan Guo, Rupam Patir, Haipeng Cai et al.
Poisoning Self-Evolving Security Policies in LLM Agents
Shared title terminologycs.CRAymen Noor, Honglu Jiang
Human Reviewers' Attitudes Toward LLM-generated Security Patches: A Controlled Experiment
Shared title terminologycs.CREmanuele Iannone, Maria Camporese, Nicolás E. Díaz Ferreyra et al.
Agent Smith in Action: Internet-scale, Automated Security Analysis of MCP Tools
Shared title terminologycs.CRMingming Zha, Ying Li, Yuan Tian et al.
Kernel-Layer Runtime Defense for LLM Agents Against Indirect Prompt Injection
Shared title terminologycs.CRAravinda Kashyap, Basavesh Ammanaghatta Shivakumar, Danfeng Yao et al.
AgentLens: Graph-guided Security Auditing for LLM-based Agents
Shared title terminologycs.CRPeizhuo Lv, Tao Chen, Mengya Shi et al.