What you will be able to do
- Sort the findings for a proposed Claude deployment into attack surface, failure modes, token and quota exhaustion, and dependency or supply-chain risk
- Rank findings by exposure: what a failure can reach, whether it can be undone, and whether untrusted input can trigger it
- Choose harness-level caps over prompt instructions to bound token and spend exhaustion
- Identify the plugin and package findings that carry the highest supply-chain exposure
Key concept
Exposure — Exposure is how much damage a finding allows if things go wrong. It depends on what the agent's tools, credentials and network can reach, whether the result can be undone, and whether untrusted content can set it off. A finding is ranked by these deployment facts, because you cannot count on the model to behave well.
1.Ranking findings by exposure
A risk review of a proposed deployment always turns up more findings than anyone can fix at once, so the ranking matters more than the list. Each finding belongs to one of four categories. Attack surface is where hostile content can enter and steer the agent. Failure modes are ways the agent or its sandbox fails without anyone attacking it. Token and quota exhaustion is a loop or a spike that burns through budget or rate limits. Dependency and supply-chain risk comes from code you did not write that runs inside your deployment.
Three questions set a finding's rank. The first is reach: what the tools, credentials and network let the agent touch, and whether that includes anything outside your systems. The second is reversibility. Managed Agents guidance treats a tool whose changes you cannot undo outside the sandbox as one that needs human approval, which makes irreversible effects the sharpest dividing line. The third is the trigger: can text from an outside party start the harmful action? A finding that scores high on all three goes to the top. A finding that only makes something visible, or causes a reviewable mistake with a limited cost, ranks below it.
| Category | Example finding | What raises its exposure |
|---|---|---|
| Attack surface | A ticket tells the agent to cancel every open order | Untrusted input reaches a tool on always_allow that changes records |
| Failure mode | To get past an obstacle, Claude uses a tool or credential it can reach | Broad credentials, and a key whose permissions were not limited at the service that issued it |
| Token and quota exhaustion | An agent loop with no turn or spend cap | Organization-level spend caps, so one runaway job pauses every application |
| Supply chain | A plugin whose hooks and MCP server run on every engineer's machine | Code that runs with full user permissions, outside the sandbox, and updates after review |
Checkpoint 1 of 9· Check yourself
A risk review of a support agent that reads customer tickets turns up four findings. Which one should rank highest by exposure?
Order cancellation reaches records outside the sandbox, cannot be undone there, and ticket text from an outside party can trigger it. It scores high on reach, reversibility and trigger. The other findings only expose something, cause a mistake a person reviews, or stay inside the sandbox.
“always_ask instead on a tool if you cannot undo its changes outside the sandbox, or if relayed end-user text alone should not make it run”Source: platform.claude.com
2.Attack surface: where untrusted input meets powerful tools
A large attack surface is not a long list of inputs. It is a path from content an outsider controls to a tool that can do damage. Take a proposed support assistant that reads inbound customer email, searches a knowledge base that contains customer records, and sends replies through an email tool. Any outside sender can put text into an email body that the model then reads. That text can carry instructions, and Claude's resistance to them is not a control you can rely on. The full mechanics of indirect prompt injection live in their own lesson. What matters for ranking is what a successful injection could reach.
Two of the findings combine into one exfiltration path. Outside senders can steer the agent, and the agent can read private records and send mail to external recipients. Limiting the agent's tools does not close this path on its own: even an agent with few tools can put data it is allowed to read into its own reply. When untrusted input, private data and an outbound channel all exist in one agent, that agent holds the highest-exposure findings in the review. The other three findings are real but smaller. Engineers reading logs they do not need is a data-handling obligation that involves insiders, not outside attackers. An extracted system prompt reveals routing and tone rules but no data and no actions. An invented refund policy is a correctness error that review can catch, with a bounded cost.
Exposure falls when the path is cut. The Managed Agents guidance states it as a rule: no agent that reads untrusted input should hold a tool on always_allow that writes files, runs commands, or changes records. The example in the table, a ticket telling the agent to cancel every open order, is controlled the same way: give the agent the smallest tool set, keep untrusted input away from powerful tools, and require approval for risky actions.
Checkpoint 2 of 9· Check yourself
The team wants to close the exfiltration path in the proposed support assistant. Outside senders' emails steer the agent, it reads customer records, and it sends mail to external recipients. Which change actually reduces that exposure?
The path runs from untrusted input to an outbound channel. Requiring a person to approve each send cuts that path at the action itself. A system-prompt rule depends on the model resisting injection, and that is not a control. The log and system-prompt changes deal with smaller findings that are not on the path.
“Smallest tool set, untrusted input kept away from powerful tools, approvals for risky actions”Source: platform.claude.com
Checkpoint 3 of 9· Exam question
A proposed support assistant built on the Messages API will read inbound customer emails, search an internal knowledge base that includes customer records, and send replies through an email tool. When assessing its attack surface, which TWO findings should be ranked as the highest exposure? Choose two.(Select 2)
Correct answers: A, E — The email tool can send to external recipients and the model can read customer records, so a reply could leak private data.; Inbound email bodies come from outside senders and reach the model, so a sender can embed instructions that steer later tool calls.
- A. Correct. The model can read private customer records and the email tool can deliver content to outside recipients. Together these form the exfiltration path of the lethal trifecta, so one manipulated reply could carry customer data out of the company.
- B. Incorrect. Log retention is a real privacy and access-control issue, but it only affects staff who already work inside the company's boundary. No outside party can trigger it, and it gives an attacker no route to take customer data out through the assistant.
- C. Incorrect. A user can often coax a model into repeating its system prompt, but the leak is limited to routing and tone rules. It exposes no customer records and does not let anyone trigger the email tool, so it ranks well below the paths that lead to data loss.
- D. Incorrect. Invented policy statements are a reliability and business-risk problem that grounding and review can reduce. They need no attacker, give no access to customer records, and do not open a route for sending data outside the company.
- E. Correct. Inbound emails are written by outside parties and go straight into the model's context. Instructions hidden in a message (indirect prompt injection) can therefore steer the model's later actions, including its calls to the email tool, which makes this the entry point of the attack surface.
3.Failure modes that need no attacker
Some failures need no attacker. Claude can take a step you did not expect while it keeps working toward the task you gave it. A typical case is reaching for a tool or credential it happens to have in order to get past an obstacle. This turns every credential in reach into a failure mode, whether or not anyone is attacking. A key's own permissions have to be limited at the service that issued it, because sandbox settings do not limit them. An offline reviewer reading transcripts can flag such a step afterward. It cannot prevent the step.
Sandbox controls also have limits of their own, and a review should name them rather than treat "sandboxed" as a finished answer. Sandboxed processes share the host kernel with everything else on the machine, so a kernel vulnerability could in principle allow an escape. Where that matters, gVisor or a separate VM provides kernel-level isolation. The sandbox proxy checks the hostname the client supplies and does not inspect encrypted traffic, so code inside the sandbox can potentially use domain fronting to reach hosts outside the allowlist. Controls also do not substitute for each other. Restricting the hosts an environment can reach does not stop the agent from using a credential on a host you did allow.
| Technology | Isolation strength | Performance overhead |
|---|---|---|
| Sandbox runtime | Good (secure defaults) | Very low |
| Containers (Docker) | Setup dependent | Low |
| gVisor | Excellent (with correct setup) | Medium/High |
| VMs (Firecracker, QEMU) | Excellent (with correct setup) | High |
Checkpoint 4 of 9· Match them up
A design doc says the agent is "sandboxed, so the risk is handled." Match each gap a reviewer should name to its consequence or its remedy.
Tap a term, then the definition that fits it.
Each control covers its own gap, and none replaces another. Isolation strength, hostname-based proxying, credential scope and after-the-fact review each leave a different risk open. A host allowlist in particular does nothing to stop the agent from using a broad key on a host you allowed.
“limiting the environment’s hosts does not stop the agent from using a credential on a host you allowed.”Source: platform.claude.com
4.Token and quota exhaustion
An agent loop has no built-in end. In the Agent SDK, both max_turns / maxTurns and max_budget_usd / maxBudgetUsd default to no limit. An ambiguous task can therefore keep calling tools for hours, and nothing stops it until the model decides it is finished. The control that bounds this risk sits in the harness: cap turns and estimated spend for each run, and when the loop hits the cap, stop it and hand off to a person. Managed Agents has the same control as a budget on each session and deployment, which should be sized to what you expect a run to cost.
Controls that look similar do not bound the loop. A stopping rule in the system prompt still depends on the model's judgement, and the model's judgement is what failed when the loop ran on. Lowering max_tokens shrinks each response but not the number of turns, so the agent just resumes more often. A cheaper model tier lowers the cost of each call while leaving the run unbounded. max_tokens also does not count toward the output-tokens-per-minute (OTPM) rate limit, so lowering it gains nothing on quota either.
Quota exhaustion reaches beyond the run that caused it, which is why it ranks higher than its per-call cost suggests. Spend caps are set at the organization level. Once a tier's monthly cap is reached, API usage pauses until 00:00 UTC on the first day of the next month, unless you request a higher limit sooner. One runaway agent can therefore halt every other application in the organization. A spend limit that you set yourself below the tier cap returns HTTP 400 invalid_request_error instead. You can set such a limit per workspace to contain the damage to a single workspace.
This error is easy to misread in a log. It has the same rate_limit_error type as an ordinary rate limit, so retry logic that treats every 429 the same way will keep retrying for the rest of the month. The field that tells the two apart is error.details.error_code.
{
"type": "error",
"error": {
"type": "rate_limit_error",
"message": "You have reached your API usage limits: your organization has crossed its monthly API usage threshold, set based on your organization's API tier. You will regain access on 2026-09-01 at 00:00 UTC.",
"details": { "error_code": "enforced_spend_limit_reached" }
},
"request_id": "req_018EeWyXxfu5pfWkrYcMdjWG"
}Checkpoint 5 of 9· Fill the gap
Your retry logic has to recognize the response the API sends once the organization reaches its tier's monthly spend cap. Which error type completes this response body?
{
"type": "error",
"error": {
"type": " ? ",
"message": "You have reached your API usage limits: your organization has crossed its monthly API usage threshold, set based on your organization's API tier. You will regain access on 2026-09-01 at 00:00 UTC.",
"details": { "error_code": "enforced_spend_limit_reached" }
},
"request_id": "req_018EeWyXxfu5pfWkrYcMdjWG"
}A spend-cap 429 uses the same rate_limit_error type as an ordinary rate limit, but it has no retry-after header. The error_code is the only field that tells them apart. invalid_request_error with HTTP 400 is what you get from a spend limit you set yourself below the tier cap.
Source: platform.claude.comCheckpoint 6 of 9· Check yourself
On Managed Agents, an agent given an ambiguous task sometimes keeps calling tools for hours. Which control actually puts a limit on how far one run can go?
Only a cap enforced by the harness stops the loop no matter what the model decides. A system-prompt rule relies on the same judgement that let the loop run on. A smaller max_tokens or a cheaper model lowers the cost of each turn but leaves the number of turns unlimited.
“budget on each session and deployment | A cap sized to what you expect a run to cost”Source: platform.claude.com
Checkpoint 7 of 9· Exam question
An autonomous research agent built on the Agent SDK loops over tool calls until it decides it is finished. In testing, a single ambiguous task ran for hours and consumed a large share of the monthly token budget. Which control best addresses this token-exhaustion risk at the architecture level?
Correct answer: B — Set a cap on turns and cumulative spend per run in the harness, and stop the loop with a handoff to a human at the cap.
- A. Incorrect. A stopping rule in the prompt is only a request to the model, and an ambiguous task is the situation where the agent is least likely to judge that it has enough. Nothing outside the model enforces the limit, so a run can still go on for hours.
- B. Correct. A limit on turns and spend enforced by the harness does not depend on the model's judgment, so worst-case consumption per run is bounded however the agent behaves. Handing off to a human at the cap also makes a runaway run visible.
- C. Incorrect.
max_tokenslimits the length of one response and says nothing about how many turns the loop runs. Lowering it leaves the loop unbounded, and the agent can simply take more turns for the same ambiguous task. - D. Incorrect. A smaller tier reduces the price of each iteration, but the agent still decides when to stop, so the loop remains unbounded. An ambiguous task can still run for hours and spend a large part of the budget, and weaker reasoning may even lengthen it.
5.Dependency and supply-chain risk
A Claude Code plugin is code that runs on the machine, not just configuration. Its command hooks and monitors are shell commands that run with the user's full permissions. Claude Code starts hooks, monitors, MCP servers and LSP servers outside the sandbox. Anthropic does not control what a plugin ships and cannot verify that it won't change. If a platform team pushes one plugin to every engineer, one malicious release runs with each engineer's local permissions across the whole company. That reach puts the finding at the top of a supply-chain review.
The second high-exposure finding is content that changes after it was reviewed. When auto-update is on for a marketplace, Claude Code updates the plugin in the background, so the files someone reviewed can be replaced on disk with no restart and no new review. A marketplace entry that follows a moving branch has the same problem. A pinned branch, tag or commit SHA, or an archive pinned to a sha256 digest, ties the plugin to what was reviewed. Claude Code refuses an archive install whose digest does not match the pin. Findings such as a few tokens of skill description loaded into each session, or command names that break an internal style guide, are about cost and convention. Neither lets anyone run code.
Package registries create the same risk inside a sandbox. In a limited Managed Agents environment, allow_package_managers opens every repository and path on github.com, gitlab.com and bitbucket.org. Anyone can publish content to those hosts, and code in the sandbox can also upload files to them. If the agent installs packages while it runs, list only the registry hosts it needs in allowed_hosts instead. Sandbox settings also do not secure your custom tools, your MCP servers or your self-hosted infrastructure. Each of those dependencies needs its own review.
Checkpoint 8 of 9· Check yourself
Security approved version 1.4 of an internal Claude Code plugin last week. Auto-update is on for its marketplace, and the marketplace entry follows the main branch. What should the supply-chain review conclude?
When auto-update is on, Claude Code updates the plugin in the background with no restart, and a moving branch lets the content change after review. Pinning to a commit or a digest ties the plugin to what was reviewed. Hooks run outside the sandbox, and Anthropic cannot verify that a plugin won't change.
“Claude Code updates that plugin in the background, so the files you reviewed can change on disk”Source: code.claude.com
Checkpoint 9 of 9· Exam question
A platform team plans to distribute a Claude Code plugin bundle containing skills, hooks, and an MCP server from a third-party marketplace to all engineers in the company. Which TWO findings should be ranked as the highest supply-chain exposure? Choose two.(Select 2)
Correct answers: A, C — The marketplace entry tracks a moving branch rather than a pinned commit, so content can change after it was reviewed.; Hooks and the MCP server execute code with each engineer's local permissions, so one malicious release runs company-wide.
- A. Correct. A moving reference means the reviewed artifact is not the one that gets installed, so a later malicious change bypasses the approval. Pinning to a reviewed commit closes that gap.
- B. Incorrect. Loading skill descriptions costs a small amount of context. It is an efficiency consideration rather than a supply-chain threat.
- C. Correct. Hooks and MCP servers are executable code that runs with the engineer's own access, so one compromised release reaches every machine that installs it. Large blast radius and high impact put it at the top of the ranking.
- D. Incorrect. A naming mismatch with a style guide is a consistency matter and cannot be used to compromise machines or data.
- E. Incorrect. Requiring a restart to load updates is an inconvenience with no security consequence. It may even slow the spread of a bad release slightly.
Sources
(8)
Every claim above is drawn from one of these pages, quoted as it was written on the date shown.
- 1.
“always_ask instead on a tool if you cannot undo its changes outside the sandbox”
↩︎ Ranking findings by exposure“No agent that reads untrusted input has a tool on always_allow that writes files, runs commands, or changes records”
↩︎ Attack surface: where untrusted input meets powerful tools“A cap sized to what you expect a run to cost”
↩︎ Token and quota exhaustion“They include every repository and path on github.com, gitlab.com, and bitbucket.org, where anyone can publish content”
↩︎ Dependency and supply-chain risk“always_ask instead on a tool if you cannot undo its changes outside the sandbox, or if relayed end-user text alone should not make it run”
↩︎ Checkpoint“budget on each session and deployment | A cap sized to what you expect a run to cost”
↩︎ Checkpoint - 2.
“Untrusted input steers the agent”
↩︎ Ranking findings by exposure“An agent can still put data it is allowed to read into its own reply or tool output.”
↩︎ Attack surface: where untrusted input meets powerful tools“Claude can also take a step you did not expect while it keeps working to complete the task you gave it.”
↩︎ Failure modes that need no attacker“but model behavior is not a security control”
↩︎ Key concept“limiting the environment’s hosts does not stop the agent from using a credential on a host you allowed”
↩︎ Exam trap 3“Smallest tool set, untrusted input kept away from powerful tools, approvals for risky actions”
↩︎ Checkpoint“limiting the environment’s hosts does not stop the agent from using a credential on a host you allowed.”
↩︎ Checkpoint - 3.https://platform.claude.com/docs/en/test-and-evaluate/strengthen-guardrails/mitigate-jailbreaksOfficial docs
“Indirect prompt injection, where the user is trusted but Claude processes third-party content”
↩︎ Attack surface: where untrusted input meets powerful tools - 4.
“Unlike VMs, sandboxed processes share the host kernel.”
↩︎ Failure modes that need no attacker“doesn’t terminate or inspect encrypted traffic”
↩︎ Failure modes that need no attacker - 5.https://code.claude.com/docs/en/agent-sdk/agent-loopOfficial docs
“Estimated spend at which the loop stops”
↩︎ Token and quota exhaustion“Estimated spend at which the loop stops”
↩︎ Exam trap 1 - 6.https://platform.claude.com/docs/en/api/rate-limitsOfficial docs
“The max_tokens parameter does not factor into OTPM rate limit calculations”
↩︎ Token and quota exhaustion“Limits are set at the organization level.”
↩︎ Token and quota exhaustion“API usage pauses until 00:00 UTC on the first day of the next month”
↩︎ Token and quota exhaustion“The error type is rate_limit_error, the same as for a rate limit, but the response has no retry-after header.”
↩︎ Exam trap 2“Retrying, including the SDK’s automatic retries, fails until access resumes.”
↩︎ Prediction - 7.https://code.claude.com/docs/en/plugins/securityOfficial docs
“command hooks and monitors are shell commands that run with your full user permissions.”
↩︎ Dependency and supply-chain risk“Anthropic does not control what MCP servers, files, or other software are included in plugins”
↩︎ Dependency and supply-chain risk“so the files you reviewed can change on disk”
↩︎ Dependency and supply-chain risk“so the files you reviewed can change on disk”
↩︎ Exam trap 4“Claude Code updates that plugin in the background, so the files you reviewed can change on disk”
↩︎ Checkpoint - 8.
“The pinned branch, tag, or commit SHA.”
↩︎ Dependency and supply-chain risk