Topic: Agent security
The revoke button is fast. Finding out what else it kills is slow
Cutting off one misbehaving agent takes seconds on most platforms. Knowing what else shares its credential takes longer. A one-hour game day.
In this post 6 sections
It’s late, and one agent is doing something it shouldn’t. You’re on call. Every platform it touches has a revoke button, and most of them work in seconds or minutes. So why does cutting off one agent so often take an hour, or never happen at all?
Because the button cuts a credential, and a credential is rarely held by one agent. Before you press it you need to know what else goes dark with it: the other agents, the CI job, the finance team’s bot, possibly the engineer whose token the agent was borrowing. If you’ve never worked that out in daylight, you’ll be working it out at 2 am.
The levers are fast. They just aren’t aimed at one agent
I went through the revocation docs for the platforms agents most often touch. Every one has a quick lever. Every lever is scoped to something bigger than an agent.
| Platform | The fast lever | How fast, in the vendor’s words | What it actually cuts |
|---|---|---|---|
| GitHub App | Suspend the installation | Tokens last at most an hour anyway | Every agent sharing that installation |
| GitHub classic PAT | Only the owner can delete it | Works “until the token expires” | A person’s token the agent borrowed |
| Google OAuth | Revoke the grant | “might take some time” | That user’s grant to every client in the project |
| Google domain-wide delegation | Delete the client ID | Apps “immediately stop working” | Everything using that client, across “all of your users” |
| Microsoft Entra, delegated | Revoke sign-in sessions | “a few minutes”; issued tokens live 60 to 90 minutes | The person, signed out of every app |
| Slack | auth.revoke |
Not stated | The bot, removed from every channel |
| AWS role | Revoke active sessions | About 30 seconds, then re-assumable | “all users of the specified role” |
Two lines in that table are worth reading twice. Revoking a Slack bot token does “deactivate the bot user and remove its channel memberships”, so if three automations share the bot, all three leave every channel, and someone re-invites them one by one. AWS’s console revoke applies to “all users of the specified role”, and the same workload can assume the role again about 30 seconds later unless you also change what the role allows.
AWS does have a single-agent lever: deny one session by its source identity or session name. It only works if you set the agent up that way before the incident.
The slow numbers you’ve seen quoted belong to a different problem. Verizon’s 2025 report put the median time to fix a leaked secret in a GitHub repository at 94 days. GitGuardian found more than 64 per cent of secrets that were valid in 2022 still valid in January 2026. Those are about leaks nobody acted on. GitGuardian explains why in one line: rotation is “almost never a single button click”, so teams pick “the one that means not breaking anything”, which is doing nothing.
That’s the same fear at incident speed. The button is fast. Being sure it’s safe to press is slow.
Shared credentials are the real delay
In a Cloud Security Alliance survey commissioned by Aembit, 43 per cent of organisations relied on shared service accounts for agents, and 31 per cent let agents run under a person’s identity. For those teams, the fast lever doesn’t exist for a single agent. Cutting the credential is the outage.
The failure shows up even without an incident. In a public GitHub issue from June, an operator had copied one OAuth credential into several agent containers. The provider rotates the refresh token on every use, so the first agent to refresh killed the others: “Every claude-flavor agent (incl. the team lead) dies ~1hr after spawn”. In an incident the coupling runs the other way. Revoke the original, and every copy dies with it.
The April breach that reached Vercel shows the better case. Context.ai, which made an AI office suite, contained an intrusion into its own cloud environment in March. OAuth tokens it held for some consumer users had been taken too, and nobody knew. About a month later an attacker used one, granted by a Vercel employee with “Allow All” permissions, to get into that employee’s Google Workspace account and then Vercel’s internal systems. Vercel published the agent’s OAuth client ID on 19 April and told Workspace admins to check for it “immediately”.
The access outlived the vendor’s own containment by about a month. But because the agent had its own client ID, every admin could cut exactly that agent and nothing else. That’s what a dedicated credential buys you.
What survives the cut
Pulling the credential doesn’t always end the agent’s reach. From the same vendor docs and incidents:
- Tokens already issued. Entra access tokens live 60 to 90 minutes unless the client and resource both support continuous access evaluation. AWS role sessions stay valid until they expire, 12 hours by default, unless a policy denies them.
- Caches. “The AWS CLI caches credentials until they expire.”
- Sibling credentials. Suspending a GitHub App leaves alone any personal token or deploy key the same agent holds.
- Sub-agents and scheduled work. One public kill-switch spec puts it well: “a kill-switch that only stops the coordinator but leaves sub-agents running does not satisfy the requirement.”
- What’s already done. Revocation doesn’t unshare a file or unsend a message.
The joint guidance on agentic AI that ASD co-sealed in May asks you to “develop and test incident response procedures to detect, contain and recover from agent compromise”, and warns about keys that get stolen when organisations “share them across multiple agents”. NIST’s general incident response guide, revised in 2025, names “disabling breached user accounts”; I found nothing in it on tokens or agents. Nobody gives you a time to beat, so you’ll have to set one.
A game day you can run in an hour
Pick one agent that matters, one that runs against production. Do this in daylight, with its owner in the room.
Before, ten minutes. Write down who is allowed to pull it. List every credential it uses, platform by platform, and for each one answer a single question: what else uses this exact credential? Check the GitHub org’s app installations and tokens, the Google admin console’s third-party app access, Entra sign-in logs for the service principal, CloudTrail by role session name, and Slack’s app management. Any answer other than “nothing” is your first finding, before you cut anything. Tell the owners of anything that shares a credential, and note how to restore each piece. Slack’s auth.revoke has a test mode that doesn’t actually revoke; use it for a dry run.
The cut, twenty minutes. Start the clock when someone says “cut it”. Pull each lever and note the time. Every 30 seconds, try one harmless read with the agent’s credentials on each platform, and note when each starts failing. The last platform to fail is your real time to cut off. Then check the list above: cached tokens, sibling credentials, scheduled jobs, sub-agents, webhooks still waking it up.
Count the damage, fifteen minutes. List everything else that broke: other agents, CI jobs, people signed out, bots gone from channels. Each one is a shared credential you either didn’t know about or had accepted. Restore everything, and time that too.
Write it down, fifteen minutes. Three numbers: time to decide, time to cut off, and how many things broke that weren’t the agent. Then fix them in order. Split the shared credentials first, shorten lifetimes second, automate the cut third. Run it again next quarter.
A target worth aiming for, and this is my suggestion rather than any standard: a few minutes to cut off, nothing else broken, and every surviving item on a written list with an expiry.
The Hugging Face breach post reads one real incident as a containment problem, and why your agent shouldn’t have your API keys covers the borrowed-credential half.
Cutting at a single checkpoint
Vendor revocation alone can’t promise seconds everywhere: Entra tokens outlive the cut, AWS policy takes minutes and Google says “some time”. It gets close where every call from the agent passes through one checkpoint that holds the real credentials and checks that agent’s own grant each time. Then cutting one agent means turning off one grant. Nobody else’s credential changes.
That’s the shape AgentValet takes: an identity per agent, scoped short-lived credentials, and an audit record of every call, including any call refused after the cut and the reason it was refused. The stops page shows how that plays out.
Sources
- GitHub Docs: installation access tokens, token expiration and revocation, reviewing personal access tokens, suspending an app installation: docs.github.com
- Google, Using OAuth 2.0 for web server applications: developers.google.com; domain-wide delegation: knowledge.workspace.google.com
- Microsoft Learn, configurable token lifetimes: learn.microsoft.com; revokeSignInSessions: learn.microsoft.com; continuous access evaluation: learn.microsoft.com
- Slack, auth.revoke: docs.slack.dev
- AWS IAM, revoke role temporary credentials: docs.aws.amazon.com; disabling permissions for temporary credentials: docs.aws.amazon.com
- Verizon, 2025 Data Breach Investigations Report: verizon.com
- GitGuardian, State of Secrets Sprawl 2026: gitguardian.com
- Cloud Security Alliance survey commissioned by Aembit (24 March 2026): cloudsecurityalliance.org
- agenity issue #744: github.com; Altinn kihub issue #117: github.com
- Vercel, April 2026 security incident: vercel.com; The Register (20 April 2026): theregister.com
- CISA, NSA, ASD’s ACSC and others, Careful adoption of agentic AI services (1 May 2026): cyber.gov.au
- NIST SP 800-61 Rev. 3 (April 2025): csrc.nist.gov