Peer Pressure: Execution-Verified Co-Evolution of Attacker and Defender Populations for Code Security
LLM code agents increasingly ship code with little oversight, yet defenders trained on static vulnerability datasets fall behind adapting adversaries.
ProofPaper ↗
Key points
- We co-train attacker and defender instead, and let execution decide every reward: an attacker (Red) edits a real repository and earns nothing unless its patch applies, builds, passes the tests, completes its development task and reproduces a real exploit in an isolated container, whose path also labels the entry point, the critical operation and the trace between them.
- Peer-Relative Policy Optimization (PRPO) makes both sides populations of LoRA adapters over one frozen base and credits each against same-role peers that faced an identical condition, placing the population inside the policy-gradient baseline rather than the opponent pool, with a tournament preserving diversity.
- PRPO's 7B diff reviewer reaches 64.8% balanced accuracy on four unseen applications in three untrained languages, 5.5 points above supervised security fine-tuning and 4.4 above a frozen frontier reviewer (Claude Opus 4.8), which it leads by 15.8 on the application it trains on.
- Run unchanged on jailbreak defense, the same algorithm matches or exceeds WildGuard's static F1 at equal corpus and model size.
Sources (1)
- [1]Peer Pressure: Execution-Verified Co-Evolution of Attacker and Defender Populations for Code SecurityarXiv (AI, ML, NLP, CV, robotics, multi-agent) · Oct 17, 10:36 PM
LLM code agents increasingly ship code with little oversight, yet defenders trained on static vulnerability datasets fall behind adapting adversaries.
We co-train attacker and defender instead, and let execution decide every reward: an attacker (Red) edits a real repository and earns nothing unless its patch applies, builds, passes the tests, completes its development task and reproduces a real exploit in an isolated container, whose path also labels the entry point, the critical operation and the trace between them.
Extractive summary: sentences quoted from the sources.
Before this
- Oct 17, 2026The Missing Compliance Class: LLM Graders That Collapse Jailbreak Success, and a Free Check
- Oct 17, 2026Pair-Aware Optimization: Coordinating Exploration and Refinement for Jailbreaking LLM Agents
- Oct 17, 2026Medical Fine-Tuning Reshapes, Not Reduces, Patient-Facing AI Risk: A Rubric-Based, LLM-Judge Evaluation Framework
- Oct 17, 2026HybridResearcher: Bridging the Structured-Unstructured Boundary for Deep Research Agents
- Oct 15, 2026Granite Switch 4.1: Chat, Decisions, and Speech from One Endpoint
- Oct 15, 2026NVIDIA Nemotron 3.5 Super VL Powers Specialized Agents with Multimodal Reasoning