Manuscript Offprint

arXiv:2610.27244

AutoRedClaw: Automated Red-Teaming for Claw-Style Agents

Hao Li, Tongyan Hu, Weidi Luo, Shanghao Shi, Xiaogeng Liu, Aiden Suh, Yulong Cao, Ning Zhang, William Yeoh, Yevgeniy Vorobeychik, Chaowei Xiao

ABSTRACT

Agent systems are shifting from task-scoped tool-use agents to persistent, personalized assistants such as OpenClaw. These claw-style agents maintain configuration files (e.g., AGENTS.md), long-term memory, and reusable skills. Once poisoned, this persistent state is repeatedly reloaded into the agent's context, creating persistent threats across tasks and sessions. Existing security evaluation systems struggle to evaluate these complex claw-style systems since they rely heavily on manually constructed test cases and environments, which limits their scale and coverage; in addition, these manually designed cases quickly become outdated as agents evolve, and their evaluation settings leave a gap with how claw-style agents are deployed in practice. To address this, we introduce AutoRedClaw, an automated red-teaming framework that generates end-to-end attacks together with the environments needed to execute them. AutoRedClaw combines a strict quality-checking protocol with execution-based validation to ensure the correctness, realism, and effectiveness of generated samples, and adopts task-driven environment construction to keep costs low. To achieve broad coverage, it organizes generation along risk categories, attack strategies, attack stages, and attack surfaces, and uses experience-guided exploration to steer generation toward under-explored regions. AutoRedClaw achieves an effective attack rate above 30% at less than $0.10 per successful sample. From its outputs, we construct RedClaw-Bench, a 330-case benchmark that yields substantially higher attack success rates (ASRs) than AgentDojo, AgentDyn, and DTap. Across seven harnesses and four frontier models, most agent systems exceed 50% ASR, showing that our red-teaming pipeline provides a strong evaluation signal even for the most advanced agent systems and demonstrating the effectiveness of our approach. Our code and benchmark are released at https://github.com/SaFo-Lab/AutoRedClaw.

1 INTRODUCTION

The AI agent systems are rapidly shifting from task-scoped tool-use agents to persistent, personalized assistants, such as OpenClaw (Steinberger, 2026). These claw-style agents have rapidly attracted widespread attention, with OpenClaw gaining over 100,000 GitHub stars in roughly two months (Steinberger, 2026). At the core of this shift is the agent harness, which provides the persistent and flexible infrastructure that enables agents to adapt over time, deliver personalized services, and handle complex everyday tasks. However, the complex and evolving nature of the harness also expands the attack surface beyond external interactions to the agent's persistent internal state. Traditional tool-using agents primarily encounter indirect prompt injection through the external environment during task execution (Greshake et al., 2023; Debenedetti et al., 2024). In contrast, claw-style agents expose additional attack surfaces in agent configuration (e.g., AGENTS.md), long-term memory (e.g., MEMORY.md), and reusable skills (Wang et al., 2026; Schmotz et al., 2026). Once these artifacts are poisoned, malicious instructions persist across tasks and sessions and are repeatedly reintroduced into the agent's context during subsequent executions (see Figure 1). More concerningly, these poisoned artifacts can even be incorporated into the system prompt as authoritative guidance, making the injected instructions more likely to be followed.

Figure

Figure 1: Agent systems transfer from tool-use agents to persistent personalized agents.

However, existing tool-using agent security benchmarks, such as AgentDojo (Debenedetti et al., 2024), are no longer sufficient to evaluate such persistent threats in claw-style agent systems, which have already been widely observed in practice. For example, ClawWorm (Zhang et al., 2026b) demonstrates that adversarial messages can induce OpenClaw agents to poison their own AGENTS.md with malicious instructions, which mislead subsequent executions and cause harmful actions. Meanwhile, malicious skills on ClawHub have been found to disguise credential theft and malware installation as routine setup requirements, turning capability extension into an entry point for compromise and leading to significant credential leakage and destructive behavior (Beurer-Kellner et al., 2026).

In response to these threats, several recent security benchmarks have been proposed for claw-style agents. For example, ClawSafety (Wei et al., 2026) constructs 120 adversarial cases that inject malicious instructions through skill files, emails, and webpages in realistic professional workspaces. ClawsBench (Li et al., 2026c) evaluates task completion and unsafe behavior across 44 tasks in five simulated applications, including Gmail, Slack, and Google Docs. SafeClawArena (Niu et al., 2026) evaluates 406 adversarial tasks in containerized agent deployments, covering skill supply-chain attacks, persistent-state exploitation, cross-boundary data flows, and indirect prompt injection. Nevertheless, prior benchmarks have significant limitations:

  1. High construction costs severely restrict scale and coverage. Existing benchmarks require extensive manual effort to design attack cases, involving user tasks, attacker goals, malicious content, and success criteria (Debenedetti et al., 2024; Li et al., 2026c; Zhang et al., 2026a; Wang et al., 2026; Chen et al., 2026; Niu et al., 2026). Beyond case design, supporting each new application also requires substantial engineering effort to implement its functionality, prepare task-relevant state, and enable realistic interactions. As a result, expanding benchmark coverage requires costly construction of new environments rather than simply adding more test cases, leaving many real-world applications and workflows beyond what manually constructed environments can support. Automating attack case generation alone cannot overcome this bottleneck, since generated cases remain confined to the underlying environments.

  2. Static benchmarks rapidly become outdated. Existing benchmarks typically rely on fixed collections of tasks, attacks, and environments, while frontier models and agent harnesses continue to evolve. New capabilities, skills, and workflows introduce attack opportunities that existing test collections were not designed to capture (Zhan et al., 2024; Debenedetti et al., 2024; Li et al., 2026a). As a result, static benchmarks can quickly fall behind emerging threats and provide only outdated coverage of evolving agent systems.

  3. Incomplete coverage of the attack chain. Even within the threats they cover, existing benchmarks often evaluate only part of the attack chain. For example, many begin with an already poisoned state, such as a compromised AGENTS.md file, and test whether malicious instructions trigger harmful behavior (Gadgil et al., 2026). This captures the downstream effects of persistent compromise but does not examine how realistic external interactions can induce the agent to poison its own persistent state. As a result, the critical transition from external influence to persistent compromise is assumed rather than properly evaluated.

  4. Capability interface gap with real-world deployments. Many existing security evaluations extend agent capabilities through dedicated function-calling (Debenedetti et al., 2024) or MCP tools (Chen et al., 2026). However, in practice, claw-style agents more commonly acquire new capabilities through other means. Loading the tool definitions of many MCP servers can substantially increase context consumption, and claw-style agents instead commonly rely on progressive disclosure through skills and CLIs, carried out with native tools such as the shell and the browser. For example, they typically work with Gmail or GitHub by running a CLI or visiting the web interface. As a result, existing benchmarks under-represent this native tool-based operation and the attack surfaces it exposes, leaving a gap between evaluation settings and real deployments.

To summarize, existing benchmarks face two fundamental challenges: their reliance on manual construction makes it difficult to keep pace with rapidly evolving agent systems, and a significant gap remains between their evaluation settings and real-world deployments. To tackle these challenges, we introduce AutoRedClaw, an automated red-teaming framework for constructing and executing security evaluations of diverse claw-style agents. AutoRedClaw enables the automatic generation of end-to-end attacks and the environments needed to study them at minimal cost. The generated tasks and environments are designed to align with the native workflows of claw-style agents in real-world deployments. To ensure the feasibility of the generated cases and environments, we propose a strict quality-checking protocol and an execution-based validation probe workflow, which together help ensure the correctness, realism, and effectiveness of our generated samples. In addition, we propose a task-driven environment construction mechanism that limits environment construction and resource use to what each task requires. These designs can effectively reduce red-teaming costs and improve evaluation efficiency. To ensure evaluation coverage, we introduce 9 risk categories, 12 attack strategies, 2 attack stages, and 5 attack surfaces to guide the red-teaming process in generating diverse test cases, thereby achieving comprehensive evaluation. We also apply an experience-guided exploration mechanism to guide the red-teaming process toward previously unexplored areas. Together, these designs enable effective, comprehensive, and realistic security evaluation of claw-style agents at low cost.

With DeepSeek-V4-Pro as the generator and OpenClaw as the probe harness, AutoRedClaw achieves an effective attack rate above 30% at less than $0.10 per successful sample. From the generated cases, we construct RedClaw-Bench, a frozen benchmark of 330 cases spanning five attack surfaces, nine risk categories, and twelve attack strategies, which yields substantially higher ASRs than AgentDojo, AgentDyn, and DTap. Evaluating seven advanced harnesses, including functionality-oriented, security-oriented, and coding agents, with four frontier models, we find that most agent systems exceed 50% ASR, while the remaining ones incur a significant sacrifice in functionality. These results demonstrate the effectiveness and efficiency of our red-teaming pipeline, as well as the strong evaluation signal our approach provides even for the most advanced agent systems.

References (30)