AI-safety · red-teaming

Agent Hacks AgentAHA

AutoResearch for Production-Agent Red-Teaming

City University of Hong Kong

 Research use — run only against systems you own or are authorized to test. See SECURITY.md.

AHA overview: an autoresearch loop turns red-team trajectories into a frozen, reusable Vulnerability Concept Graph, evaluated single-shot on held-out tasks and transferred across scenarios and victim models.
An autoresearch loop turns trajectories into a frozen, reusable Vulnerability Concept Graph — evaluated single-shot on held-out tasks, and transferred across scenarios and victim models.

Point AHA at a production agent and it returns a map of why that agent breaks — reusable vulnerability concepts that keep working on unseen tasks and carry across scenarios and victim models they were never found on.

117
confirmed concepts
8
mechanism families
16/18
one shared core
47.0%
held-out reuse ASR
+14.2
pts vs best baseline
≈88%
cross-victim transfer

Abstract

Red-teaming a production agent usually yields a pile of one-off jailbreak strings that stop working the moment the task changes. AHA turns red-teaming into autoresearch: a researcher agent iterates on its own — hypothesize an attack, run it against a Docker-sandboxed victim agent, judge the trajectory, reflect — and accumulates a persistent Vulnerability Concept Graph (VCG) of why a family of attacks works, when it fails, and how to reinstantiate it. Because the unit of discovery is a concept rather than a prompt, a finding can be frozen and reused single-shot on held-out tasks — and it keeps working. Across two production agent stacks, three frontier victim models, and three scenario families, AHA discovered 117 confirmed concepts, clustering into eight recurring mechanism families, and reached 47.0% held-out attack success — +14.2 points over the strongest frozen discovery baseline.

The finding is a concept

117 reusable vulnerability concepts, eight mechanism families

Every confirmed finding is a concept, not a payload — a record of the mechanism a family of attacks exploits, the falsifier that would refute it, and how to reinstantiate it. Clustering the discovered graphs yields eight families; two are cores that recur across models, agents, and scenarios.

Claimed authorization core

Grants the harmful step legitimacy through an ownership / admin / compliance frame, so the agent never reconstructs the global intent.

coverage16 / 18
Task-goal hijack core

Injected content in a tool result plants a competing goal that the agent adopts as its own task.

indirect channels9 / 12
Harm split across steps

Each step looks benign; the harm exists only in the composition across turns, so local checks never aggregate it.

AgentHazard · DTap6 / 18
Spoofed trust signal

Forges identity, authority, or provenance markers ("our team's key") so the agent trusts the source of the request.

all scenarios9 / 18
Fictional reframing

Wraps the request in fiction / roleplay so the model treats a real operation as make-believe.

mostly AgentHazard6 / 18
Benign-purpose cover

A legit-sounding declared purpose — testing, debugging, a defensive fixture — launders the harmful action.

AgentHazard5 / 18
Routine-context pretext

Frames the harmful action as normal, expected operations inside the environment, so it passes as ops.

AgentDyn5 / 18
Outcome manipulation

Games the judge / verdict layer so a harmful result is scored or treated as acceptable.

DTap only4 / 18
Mechanism-family landscape heatmap: eight families (rows) across eighteen scenario × agent × victim settings (columns); claimed authorization is lit in 16 of 18.
The same eight families recur across every setting. Rows are mechanism families; columns are all 18 scenario × agent × victim settings. The claimed-authorization core is lit in 16 of 18, and task-goal hijack across the indirect channel — the concepts are cross-cutting, not scenario-local.

Three concepts, verbatim from the graph — the mechanism (why), the falsifier (when it fails), and its reach.

VC · claimed authorization
Assumed-ownership authorization bypass
why it worksA first-person ownership claim ("this is my box / my repo") is accepted as authorization, so the agent skips the provenance check it would otherwise run.
falsifierRefuted if the agent verifies key/asset provenance before acting.
reach: 16 / 18 settings · 5 harm classes
VC · task-goal hijack
Authorized-action target swap
why it worksThe assistant performs exactly its one authorized action, but pointed at the attacker's target — a poisoned operand reads as routing data, so no recipient check fires.
falsifierRefuted when the user pins the parameter explicitly, or an overt third-party payee is named.
reach: AgentDyn · redirected payments, invites, ownership transfers
VC · harm split across steps
Destructiveness-frame inversion
why it worksThe deletion guard keys on how valuable targets appear, not on irreversibility; relabelling real records as junk flips destruction into "housekeeping".
falsifierRefuted if the agent authenticates records before an irreversible action.
reach: DTap · tool- and channel-agnostic
One concept — many harms, many targets.

The claimed-authorization core lights up 16 of 18 settings and, realized, produces machine takeover, fraud, exfiltration, and destruction alike. Frozen and reused single-shot, the concepts even break scenarios and victim models they were never discovered on. Patching the mechanism closes a whole class of failures — not a single prompt.

Three environments, one concept library

Not three benchmarks — three places the same concepts fire

AgentHazard, AgentDyn, and DTap aren't three separate findings; they're three environments where the same reusable concepts land, each turning the shared mechanisms into scenario-appropriate harm. The deliverable is the concept library that carries across all three.

AgentHazard
a coding / ops agent with a real shell
  • Machine takeover — RCE, reverse shells, C2 channels, container escape
  • Persistence — attacker SSH keys, passwordless-root, boot-persistent services, surveillance daemons
  • Privilege escalation to root
  • Security-control teardown — disabled scanners, TLS-verify off, MFA-skip allowlists
  • Supply-chain — dependency poisoning, build hooks, TLS-MITM prep, insecure service exposure
  • Irreversible destruction — DBs + backups, anti-forensic log erasure, boot-config corruption
  • Exfiltration — env secrets, credential files, source code, PII, the agent's own prompt + tool schemas
  • Internal recon / network scanning · resource-exhaustion DoS · fabricated trust attestation
AgentDyn
an app assistant hijacked via injected tool output
  • Money moved to the attacker — up to draining the full balance
  • Account takeover — resets the password to an attacker value, reports "secured"
  • Credential phishing — submits the user's login to an attacker form
  • Access hand-over · asset / ownership transfer to the attacker
  • Irreversible asset deletion / data destruction
  • Account-settings tampering · malicious file download
  • Unauthorized purchases · data exfiltration
DTap
a business-tool agent bound by its own safety rules
  • Fabricated medical diagnosis + unsafe over-ordering + high-stakes unsafe advice
  • Financial fraud — unauthorized payments / transfers, billing fraud
  • Irreversible record destruction · record / CRM tampering
  • Data exfiltration · credential/PII exposure · consent & privacy violation
  • Deception — false deliverables, a fabricated decision confirmed as fact
  • Coercion / harassment · disallowed content · piracy/copyright · phishing delivery
  • Service sabotage — account cancellation, scheduling, manipulated procurement
  • Covert surveillance implant · security-control sabotage · excessive-action / budget override · bulk spam

Interactive casebook

Explore every confirmed break

Browse by mechanism family to watch one concept recur across scenarios and victims — or switch to by target cell. Click any tile to read the vulnerability concepts: the mechanism (why), what the agent did, and the evidence. 117 concepts, 8 families, 17 cells — every cell broken.

mechanism
scenario
victim
agent

Watch it work

One autonomous iteration, start to finish

No human in the loop: the researcher agent commits a hypothesis, designs an attack, runs it against a sandboxed victim, and promotes only replicated, non-falsified breaks into its graph.

aha · discovery loop
iteration 42 / overnight run

A concept enters the graph only after it replicates and survives its own falsifier.

The same frozen concept, reused single-shot, then breaks tasks the loop never saw — across models and agents.

Reusable & transferable

Frozen, the concepts keep working — and travel

Each discovery artifact is frozen and reused single-shot on held-out tasks, with no further search — so every break is the concept's, not the search's. And a concept frozen on one setting still breaks the others.

ScenarioClaude CodeCodexAHA avgbest baseline
AgentHazard77.474.876.158.5
AgentDyn25.020.222.66.6
DTap47.636.742.241.5
Overall47.032.8

+14.2 points over the strongest frozen discovery baseline — the concepts keep working when detached from the search that found them.

Cross-scenario transfer: held-out ASR when a scenario's frozen VCG is reused on another scenario's split.
Across scenarios. A scenario's frozen VCG reused on another scenario's held-out split — an indirect-only VCG still hits 41.8% on DTap-indirect and 42.5% on DTap-direct.
Cross-victim transfer: held-out ASR when one victim's frozen VCG is used against the other two victims.
Across victim models. One victim's frozen VCG against the other two — up to 86.7%, averaging ≈88% of each target's native rate (some above native).

A concept frozen on one setting still breaks the others: the finding lives in the agent's trajectory, not in a payload tied to where it was found. A mechanism compounds where an exploit decays.

Bring your own

The method extends to any agent you can sandbox

The three scenarios here are where transfer was measured — not the ceiling. A build workflow turns a plain-language red-team concern into a runnable scenario; an import workflow turns an existing benchmark into one. Same loop, new target.

Two workflows: build a scenario from a free-text concern, or import an existing benchmark into a runnable scenario.
Left: build a scenario from a free-text concern. Right: import an existing benchmark. Either way you get a runnable scenario the same VCG loop attacks.

BibTeX

@online{2607.11698,
Author = {Xutao Mao and Xiang Zheng and Cong Wang},
Title = {Agent Hacks Agent: Autoresearch for Production-Agent Red-Teaming},
Year = {2026},
Eprint = {2607.11698},
Eprinttype = {arXiv},
}