AdvSim2Real : Training Web Agents Against Adaptive Prompt Injection in a Web World Model
Sarim Hashmi, Mukul Ranjan, Kshitij Mishra, Mikhail Kuznetsov, Praneeth Vepakomma, Nils Lukas
Abstract
Web agents complete user requests by reading and acting on pages that third parties write, so an instruction planted on a page can redirect the agent away from the user's goal. The agent cannot simply ignore the page, because the page also holds the values and controls the task requires. Current defenses fine-tune the agent on injections fixed before training, and attackers that adapt to the trained model bypass them. Adversarial training lets the attacker adapt but keeps the tasks fixed, so a task stops teaching once the agent solves it. We introduce AdvSim2Real, which co-evolves a task curriculum, an injection adversary, and the agent inside a frozen web world model. The curriculum is rewarded for tasks the agent solves about half of the time, and the adversary only for a success flip, an injection that turns a judged success into a failure. Training in the simulator makes a 4B agent both more capable and more robust: its completion rises with and without attacks, holds against a frontier-model adversary it never trained against, and its capability gain carries over to a real browser. On 150 web tasks, AdvSim2Real raises completion under this unseen adversary by 33.6\% relative to the base agent.
Create a lesson
Metadata
- Categories
- cs.CL, cs.AI, cs.LG
- Comments
- Code at https://github.com/Sarim-MBZUAI/advsim2real
Related papers
MINE: A Training-Free Defense against Indirect Prompt Injection via Mutual Information and Embedding Variance
Shared title terminologycs.CLTruong Phan, Ngoc-Quan Pham, Dat Quoc Nguyen
Failure Broadens, Success Sharpens: Continual Adaptation of Tool-Use Agents Across Diverse Tasks with Dual-Polarity Memory
Shared title terminologycs.CLTianmai M. Zhang, Hoda Shajari, Amr Hendy et al.
AdaptEvo: Learning under Imperfect Supervision through Confidence-Adaptive Training with Knowledge Evolution
Shared title terminologycs.CLAllSpark Team
CoTrace: Data Recipes for Training Terminal Agents with Harness-Model Co-Evolution
Shared title terminologycs.CLJixuan Chen, Jiaxin Zhang, Qinyuan Ye et al.
Training Advisors for LLM Agents from Task Outcomes
Shared title terminologycs.CLSergei Polezhaev, Barys Liskavets, Ori Press et al.
ToolRACER: A Robust Agentic Conversation Emulation Resource for Agent Training and Evaluation
Shared title terminologycs.CLArkajyoti Chakraborty, Aryan Tayal, Ishika Agarwal et al.