defense 2025

Who Grants the Agent Power? Defending Against Instruction Injection via Task-Centric Access Control

Yifeng Cai 1, Ziming Wang 1, Zhaomeng Deng 1, Mengyu Yao 1, Junlin Liu 1, Yutao Hu 2, Ziqi Zhang 3, Yao Guo 1, Ding Li 1

1 citations · 13 references · arXiv

α

Published on arXiv

2510.26212

Prompt Injection

OWASP LLM Top 10 — LLM01

Excessive Agency

OWASP LLM Top 10 — LLM08

Key Finding

AgentSentry successfully blocks an instruction injection attack that would forward private emails to an attacker, while allowing the legitimate app-registration task to complete normally.

AgentSentry

Novel technique introduced


AI agents capable of GUI understanding and Model Context Protocol are increasingly deployed to automate mobile tasks. However, their reliance on over-privileged, static permissions creates a critical vulnerability: instruction injection. Malicious instructions, embedded in otherwise benign content like emails, can hijack the agent to perform unauthorized actions. We present AgentSentry, a lightweight runtime task-centric access control framework that enforces dynamic, task-scoped permissions. Instead of granting broad, persistent permissions, AgentSentry dynamically generates and enforces minimal, temporary policies aligned with the user's specific task (e.g., register for an app), revoking them upon completion. We demonstrate that AgentSentry successfully prevents an instruction injection attack, where an agent is tricked into forwarding private emails, while allowing the legitimate task to complete. Our approach highlights the urgent need for intent-aligned security models to safely govern the next generation of autonomous agents.


Key Contributions

  • Formalizes the threat model for multimodal indirect instruction injection against AI agents operating on unmodified mobile OSes
  • Proposes Task-Centric Access Control as a security paradigm: dynamic, minimal, temporary permissions scoped to the user's specific task
  • Presents AgentSentry, a lightweight runtime framework that prevents instruction injection (email exfiltration) while completing legitimate tasks unimpeded

🛡️ Threat Analysis


Details

Domains
nlpmultimodal
Model Types
llmvlmmultimodal
Threat Tags
inference_timeblack_box
Applications
mobile ai agentsgui automation agentsmcp-based agents