Google Agent Anomaly Detection flags 87%, after the fact
Google's async agent monitor flagged 87% of the harmful instructions agents carried out across five outside benchmarks, but caught only 4 of 18 memory-poisoning cases. A decode for teams running ADK agents with real tools.
Picture a platform engineer at a 40-person logistics company who built an accounts-payable agent last quarter. It reads vendor email, pulls invoices and queues payments. Today the safety net is a weekly skim of logs and the hope that the model refuses anything odd. The failure is the one AI郵報 uses as its example. A tool returns a bill with a second payment instruction hidden inside it. The agent follows it, and every tool call still reads as "make a payment." Nobody notices until the money is gone and someone has to rebuild the session by hand.
Google's answer is Agent Anomaly Detection, a Private Preview feature on Gemini Enterprise Agent Platform. It reads an agent's traces and logs after the agent runs and flags sessions where the agent acted outside its intended boundaries. On Nov 12, 2026, Google's Developers Blog published results from five public agent-security benchmarks written by other teams. The headline: it flagged 87% of the harmful instructions the agent actually carried out. The fine print on memory poisoning, warm-up and false alarms matters as much as that number.
What a hijack is
An agent works by reading text and acting on it. Every tool call pulls in text someone else wrote, and whoever controls that text can try to steer the agent, per Google's post. OWASP calls this agent goal hijack. Google's test covered three ways it happens:
- Hidden in what a tool returns. The attacker never talks to the agent. They plant an instruction in data the agent reads while doing its real job, the attack known as indirect prompt injection. Deedglass gives an illustration: a user asks for a summary of unread email, and one email tells the assistant to forward a document to an outside address. The invoice above is the same attack. AgentDojo, InjecAgent and AgentDyn test this.
- Planted in memory. Agent Security Bench (ASB) puts the instruction in the agent's long-term memory. Google calls this poisoned memory.
- Asked for directly. In AgentHarm, the user asks for the harmful action outright, so the agent always reads it.
A planted instruction only matters if the agent reads it and acts. In many cases the agent never opens the email or file that holds it, so Google sorted each harmful session three ways: never read, resisted, or carried out. The 87% below is about the last group.
What it is
Per Google's post, Agent Anomaly Detection was announced in September and is in Private Preview. It targets agent goal hijack, which Google notes OWASP ranks first in its Top 10 for Agentic Applications (2026). Here is how each capability maps to the accounts-payable problem:
- It reads traces and logs asynchronously, without adding latency. Your agent isn't slowed down. The flip side, per Google, is that it flags a session for review after the agent has already acted. AI郵報 is blunt about this: the results don't show it stopping a transfer or a data send as it happens.
- It learns each agent's normal behavior. In the main study, every agent first ran at least 300 benign sessions as a baseline. A separate AgentDyn comparison, covered below, looked at shorter and longer histories. This is the piece that could spot "payment, but to the wrong payee" when the tool name alone looks normal.
- Each finding carries a threat category. Google says four of its five categories align with the OWASP agentic Top 10. That gives a reviewer something to triage by besides "anomaly."
- Findings go to Google's security console. According to Tech Bytes, findings export to Google Cloud Security Command Center, and the system works from OpenTelemetry traces. Google's own post doesn't name either.
The test setup is what makes the number worth reading. Google ran the benchmark cases unchanged: AgentDojo (NeurIPS 2024), InjecAgent (ACL 2024 Findings), Agent Security Bench (ASB, ICLR 2025), AgentDyn (2026) and AgentHarm (ICLR 2025). The agent was built with ADK and ran gemini-2.5-flash on each benchmark's simulated apps, for 1,774 scored sessions in total. Each benchmark's own Python check read the final app state, such as whether money left the account, to label the session. A model never decided the label. Deedglass explains why AgentDojo grades this way: an LLM judge could itself be hijacked by the injection it is evaluating.
The results, per Google (Nov 12, 2026):
- The model didn't follow about half of the harmful instructions it read. It refused three in four direct requests for harm and ignored or failed at about 30% of instructions hidden in tool output.
- Of the instructions the agent carried out across all five benchmarks, 87% were flagged. Google breaks that out for four: 85% on AgentDojo, 87% on InjecAgent, 99% on AgentDyn and 81% on AgentHarm. ASB's memory-poisoning sessions are reported separately (below), and Google doesn't say how much they weigh in the 87%.
- Counting every harmful session, including the ones the agent never read or resisted, the flag rate was 45% to 62%.
- In 8 of 11 apps it flagged at least 95% of carried-out instructions. The lowest was AgentDojo's Slack app at 63%.
- False alarms ran 2% to 4% on office-style benign tasks and 16% on AgentHarm, whose benign tasks post to social media, run terminal commands and download files.
- Poisoned memory, via ASB, is the clear gap: 4 of 18 caught.
Alternatives. We didn't fetch a competing product's page, so there is no like-for-like comparison here. The sources do describe controls that sit before execution, which Google itself says to pair with this one:
- Restricting tools before the agent reads untrusted data cut AgentDojo attack success to about 7.5%, per Deedglass's summary of the AgentDojo paper. The trade-off: it fails when the needed tools can't be planned in advance, or when the tools a task needs also enable the attack.
- Model Armor scanning plus Google's preview Semantic Governance Policy engine check prompts and proposed tool calls before they run, per Tech Bytes. The trade-off: it keeps you on Google's stack, and the policy engine is in preview.
- Out-of-band enforcement such as CaMeL separates control flow from data flow. DeepInspect's blog reports it solves 67% of AgentDojo tasks with provable security properties. The trade-off: DeepInspect also notes a June 2026 paper flagging that these defenses were validated only on static benchmarks.
Who it's for
Pick it up if you already run ADK agents on Gemini Enterprise Agent Platform and those agents have steady traffic. The system needs a few hundred sessions of history to work well. You also need someone who reviews findings. This is an audit and detection layer, and its value shows up in how fast you can find and scope a session that went wrong. It fits best where your agents mostly do office-style work, the setting where Google measured 2% to 4% false alarms.
Skip it, or don't count on it, in these cases:
- You need to block actions before they run. It doesn't block, by Google's own description.
- Your main risk is long-term memory. Saved preferences, document summaries and agent notes are the attack path it caught least, at 4 of 18.
- Your agents are new or low-volume. They won't have the baseline it needs.
- Your agents' normal work uses high-impact tools. On AgentHarm, benign tasks with shell commands, downloads and public posting drew 16% false alarms, against 2% to 4% on office-style work.
- You're not on Google's platform, or you need a published price. The study covered one model and one framework, and preview terms and pricing weren't something we could confirm.
Before and after
Before, for the accounts-payable agent:
- The agent reads email and invoices, then calls the payment tool.
- The model is the only guard. Per Google's numbers, gemini-2.5-flash ignored or failed at about 30% of instructions hidden in tool output, so, by our arithmetic, most of the rest still got through.
- Logs pile up and nobody reads them unless something breaks.
- When the bank calls, an engineer reconstructs the session from raw logs with no hint of where it went wrong.
After, with defense in depth as Google recommends:
- Before the agent opens untrusted data, it gets the smallest tool set for the task. Payments are restricted by argument, not just by tool name. Deedglass's example rule is "send email only to our domain"; the payment version is "pay only approved vendors."
- Per Tech Bytes, high-impact operations such as financial transactions require a human sign-off.
- Full traces and logs flow to Agent Anomaly Detection, which reads them asynchronously.
- Sessions that stray come back as findings with a threat category and severity, and a reviewer triages them.
- The reviewer starts from a flagged session rather than a haystack. AI郵報 points out they still need the original task, tool arguments and final state to decide whether to revoke credentials or roll back data.
Step 3 alone doesn't save the money. It shortens the time to finding out.
Try it
Access. Google says Agent Anomaly Detection is in Private Preview and that you request access through its Agent Anomaly Detection overview. The post links no pricing, and we couldn't confirm preview terms. Per AI郵報's reading of the overview, setup means exporting agent telemetry and configuring the service. Tech Bytes adds that you should send full telemetry through ADK, including complete prompt context and model responses.
A worked evaluation. Don't copy the 87% into a risk register. Measure your own agent the way Google measured theirs.
- Warm up honestly. Build up about 360 normal sessions per agent before judging anything. That is the longer history in Google's separate AgentDyn warm-up comparison: 33% of carried-out harmful instructions were flagged with about 220 benign sessions, and 99% with 360. Google reports only those two points, so treat 360 as a tested number, not a proven minimum. AI郵報 adds that if your history covers only one team or a few tools, new legitimate work may look anomalous.
- Replay known work. AI郵報 suggests teams with existing logs and an incident process replay a few known sessions first, to measure alert quality and how much manual triage they create.
- Plant attacks where your agent reads. Put instructions in an email, a tool result and, critically, something the agent saves to memory and reads back in a later session. That last case is the one ASB covered and the detector mostly missed.
- Grade by final state, not by transcript. Following Deedglass's AgentDojo advice: check the outbox and the ledger, not what the agent said.
- Score in separate buckets. Google split harmful sessions into never read, resisted and carried out, and those rates differ a lot (1 flag in 141 never-read sessions, 11% to 25% of resisted hidden instructions, 87% of carried-out ones). Keep "no result" as its own bucket too. Google got no result on about 6% of sessions, and AI郵報 warns that silence from a failed analysis looks the same as silence from a clean session.
Our example of a scoring sheet, kept to the practice the sources describe:
# Our example — evaluation log per test session
session_id | attack_location (email/tool/memory/user) | read? | carried_out? (state check) | flagged? | category | severity | analysis_returned?
# Report separately: carried-out flag rate, resisted flag rate, benign false-alarm rate, no-result rate
If you want longer, messier tests. The public benchmarks Google used are short. The OpenART repo measures median tool calls of 1 for InjecAgent, 2 for AgentDojo and ASB, and 3.5 for AgentHarm, against 97 for its own tasks. OpenART targets coding-agent runtimes such as OpenCode, Claude Code and Codex, and its repo doesn't document ADK support, so treat it as a model for multi-step testing rather than a drop-in harness. Its local smoke task needs Docker but no model credentials, per the repo:
cd OpenART
python3 -m venv .venv
source .venv/bin/activate
python -m pip install -r requirements.txt
export PYTHONPATH="$PWD"
# build the base task image
docker build -t openart/task-base:latest -f images/Dockerfile.task-base .
# run the smoke task with the deterministic evaluator, no attacker
python -m framework.cli run \
--task examples/tasks/local-smoke \
--target-config configs/target-configs/target.local-smoke.yaml \
--eval-strategy deterministic \
--skip-attacker \
--run-id local-smoke \
--output-dir outputs/local-smoke
The repo also suggests telling your coding agent: "Read and follow OpenART/skills/openart/SKILL.md. Help me run the local smoke task, explain each required setting, and stop before any external or destructive action."
Where it breaks
It acts after the fact. Google states detection runs asynchronously and flags a session after the agent has acted. For irreversible actions like payments or outbound email, it tells you what happened, not that it was stopped.
Poisoned memory. Google caught 4 of 18 sessions where instructions planted in long-term memory made the agent act. OpenART's authors report that unsafe behavior tends to appear well after changed state is first consumed. That is the same shape of problem, and it suggests session-by-session anomaly scoring will struggle wherever the cause and the harmful action sit far apart. That last point is our inference.
Warm-up and small actions. New agents get weaker coverage until they build history, per the AgentDyn numbers. Google says single small actions, like one page visit, look like normal work. It notes that many of the instructions in AgentDojo's Slack app, its lowest app at 63%, ask for one such action.
False alarms scale with tool power. The 16% false-alarm rate on AgentHarm came from benign tasks that run terminal commands, download files and post publicly. Google says to expect more findings at first for such agents and to triage by severity and threat category.
Narrow test conditions. Tech Bytes notes only one model and framework were tested: ADK with gemini-2.5-flash. Google adds that it used simulated apps and that benchmark benign tasks are likely simpler than production traffic, so your false-alarm rate can differ. Including the roughly 6% of sessions with no result as misses lowers the overall rates by 1 to 2 points.
Static attacks. Google ran the five benchmarks' cases unchanged, which in our reading means a fixed attack set. DeepInspect, itself a vendor of a competing enforcement layer, reports that adaptive attacks broke eight published defenses in one study and twelve in another. It also reports Google DeepMind finding that defenses tested only on static attacks offer "a false sense of security." Deedglass notes a reinforcing "hacking prompt" nearly doubled InjecAgent's success rate against ReAct-prompted GPT-4. Google's study doesn't address adaptive attackers, so we read its 87% as a static-set number.
Unmeasured categories. Google found no public benchmarks with labeled traces for cascading failures or identity and privilege abuse, so it has no evidence there.
Data you now hold. AI郵報 points out that full traces can contain email, company documents and customer data. Decide which fields go out, who can read them and how long they're kept.
Open questions.
- We found no independent replication of the 87%. Both coverage pieces restate Google's numbers, and AI郵報 says plainly it did not rerun them.
- Preview terms and pricing are unconfirmed.
- We didn't check OWASP's own guidance on complementary controls.
- We couldn't confirm who maintains AgentDyn.
- Whether scores on simulated apps hold up against live attacks is an open question we couldn't settle.
- Tech Bytes lists planned work on resisted attempts, high-impact tools, faster calibration and memory poisoning. Treat that as roadmap, not shipped.
Sources
- How Agent Anomaly Detection scores on benchmarks we didn't write · developers.googleblog.com
- Google Agent Anomaly Detection 評測:87% 找到的是什麼? · AI郵報
- How Agent Anomaly Detection scores on benchmarks we didn't write · Tech Bytes
- Prompt Injection Benchmarks: AgentDojo, BIPIA, CyberSecEval · DeepInspect
- AgentDojo and InjecAgent: prompt injection benchmarks · Deedglass
- GitHub - AI45Lab/OpenART: OpenART is an open-source framework designed to evaluate the safety and robustness of autonomous AI agents in dynamic, long-horizon, and stateful environments. It stress-tests agent runtimes against multi-step state poisoning, privilege escalation, and tool-use vulnerabilities across 10,000+ benchmark scenarios. · GitHub