Manipulating LLM Web Agents with Indirect Prompt Injection Attack via HTML Accessibility Tree
Sam JohnsonViet PhamThai Le
Sam Johnson
Viet Pham
Thai Le
+3
This work shows that LLM web agents using the accessibility tree to parse HTML are vulnerable to indirect prompt injection attacks. Adversaries embed universal adversarial triggers, optimized via the Greedy Coordinate Gradient algorithm, into webpage HTML. Experiments with a Llama-3.1-based Browser Gym agent achieve high attack success rates on real websites, including credential exfiltration and forced ad clicks, highlighting critical security risks.

arXiv ·
· July 20, 2025