mlsanityData to 7 Oct 2026

SnapGuard: Lightweight Prompt Injection Detection for Screenshot-Based Web Agents

arXiv 2604.25562 ↗First posted 28 Apr 2026cs.CR cs.AIcited by 3

On the map: LLM agents and tool use → Agent threats, guardrails and governance

also in 1 more
Abstract (arXiv)

Web agents have emerged as an effective paradigm for automating interactions with complex web environments, yet remain vulnerable to prompt injection attacks that embed malicious instructions into webpage content to induce unintended actions. This threat is further amplified for screenshot-based web agents, which operate on rendered visual webpages rather than structured textual representations, making predominant text-centric defenses ineffective. Although multimodal detection methods have been explored, they often rely on large vision-language models (VLMs), incurring significant computational overhead. The bottleneck lies in the complexity of modern webpages: VLMs must comprehend the global semantics of an entire page, resulting in substantial inference time and GPU memory usage. This raises a critical question: can we detect prompt injection attacks from screenshots in a lightweight manner? In this paper, we observe that injected webpages exhibit distinct characteristics compared to benign ones from both visual and textual perspectives. Building on this insight, we propose SnapGuard, a lightweight yet accurate method that reformulates prompt injection detection as multimodal representation analysis over webpage screenshots. SnapGuard leverages two complementary signals: a visual stability indicator that identifies abnormally smooth gradient distributions induced by malicious content, and action-oriented textual signals recovered via contrast-polarity reversal. Extensive evaluations across eight attacks and two benign settings demonstrate that SnapGuard achieves an F1 score of 0.75, outperforming GPT-4o-prompt while being 8x faster (1.81s vs. 14.50s) and introducing no additional memory overhead.

Key facts. Cited by 3 papers in the map (data through 7 Oct 2026). Placed in Agent threats, guardrails and governance, one of 16 directions in LLM agents and tool use. Builds on 34 of its 50 references that are in the map. First posted on arXiv 28 Apr 2026.

Builds on

34 of 50 references.

Closest ancestors · 12

Same direction, newest first

  1. 2025DECEPTICON: How Dark Patterns Manipulate Web Agents28 Dec
  2. 2025VeriGuard: Enhancing LLM Agent Safety via Verified Code Generation3 Oct
  3. 2025WAInjectBench: Benchmarking Prompt Injection Detections for Web Agents1 Oct
  4. 2025HarmonyGuard: Toward Safety and Utility in Web Agents via Adaptive Policy Enhancement and Dual-Objective Optimization6 Aug
  5. 2025PromptArmor: Simple yet Effective Prompt Injection Defenses21 Jul
  6. 2025WebGuard: Building a Generalizable Guardrail for Web Agents18 Jul
  7. 2025VPI-Bench: Visual Prompt Injection Attacks for Computer-Use Agents3 Jun
  8. 2025RedTeamCUA: Realistic Adversarial Testing of Computer-Use Agents in Hybrid Web-OS Environments28 May
  9. 2025WASP: Benchmarking Web Agent Security Against Prompt Injection Attacks22 Apr
  10. 2025ShieldAgent: Shielding Agents via Verifiable Safety Policy Reasoning26 Mar
  11. 2024Attacking Vision-Language Computer Agents via Pop-ups4 Nov
  12. 2024Dissecting Adversarial Robustness of Multimodal LM Agents18 Jun

Other references · 22

  1. 2021Learning Transferable Visual Models From Natural Language Supervisioncited by 33,456
  2. 2014Microsoft COCO: Common Objects in Contextcited by 17,498
  3. 2024The Llama 3 Herd of Modelscited by 14,192
  4. 2023WebArena: A Realistic Web Environment for Building Autonomous Agentscited by 1,908
  5. 2023Not what you've signed up for: Compromising Real-World LLM-Integrated Applications with Indirect Prompt Injectioncited by 1,339
  6. 2023Mind2Web: Towards a Generalist Agent for the Webcited by 1,210
  7. 2025UI-TARS: Pioneering Automated GUI Interaction with Native Agentscited by 584
  8. 2024GPT-4V(ision) is a Generalist Web Agent, if Groundedcited by 547
  9. 2024PoisonedRAG: Knowledge Corruption Attacks to Retrieval-Augmented Generation of Large Language Modelscited by 251
  10. 2020MiniLMv2: Multi-Head Self-Attention Relation Distillation for Compressing Pretrained Transformerscited by 240
  11. 2025UI-TARS-2 Technical Report: Advancing GUI Agent with Multi-Turn Reinforcement Learningcited by 205
  12. 2025DataSentinel: A Game-Theoretic Detection of Prompt Injection Attackscited by 124
10 more
  1. 2024AdaShield: Safeguarding Multimodal Large Language Models from Structure-based Attack via Adaptive Shield Promptingcited by 113
  2. 2025A Survey of WebAgents: Towards Next-Generation AI Agents for Web Automation with Large Foundation Modelscited by 87
  3. 2026DeepSeek-OCR 2: Visual Causal Flowcited by 68
  4. 2025DeepShop: A Benchmark for Deep Research Shopping Agentscited by 42
  5. 2024Safeguarding Vision-Language Models Against Patched Visual Prompt Injectorscited by 26
  6. 2024Embedding-based classifiers can detect prompt injection attackscited by 24
  7. 2024Infogent: An Agent-Based Framework for Web Information Aggregationcited by 19
  8. 2025On the Robustness of GUI Grounding Models Against Image Attackscited by 14
  9. 2025Mitigating Response Delays in Free-Form Conversations with LLM-powered Intelligent Virtual Agentscited by 12
  10. 2026SafePred: A Predictive Guardrail for Computer-Using Agents via World Modelscited by 11

Built on by

Cited by year (2026 to 7 Oct)

Citing papers per year: 2026: 3.

3 papers.

Similar, not cited

Close in wording, no citation either way

  1. 2026WebAgentGuard: A Reasoning-Driven Guard Model for Detecting Prompt Injection Attacks in Web Agents
  2. 2025WebInject: Prompt Injection Attack to Web Agents
  3. 2025BrowseSafe: Understanding and Preventing Prompt Injection Within AI Browser Agents
  4. 2025AgentTypo: Adaptive Typographic Prompt Injection Attacks against Black-box Multimodal Agents
  5. 2026WebSentinel: Detecting and Localizing Prompt Injection Attacks for Web Agents
  6. 2026MIRAGE: Stealthy Visual Prompt Injection for Vulnerability Detection in Web Agents
  7. 2026When AUC 0.998 Is Not Enough: A Candidate Evaluation Protocol for Hidden-State Probes of Indirect Prompt Injection in Multimodal Computer-Use Agents
  8. 2026MUZZLE: Adaptive Agentic Red-Teaming of Web Agents Against Indirect Prompt Injection Attacks