Takeaways
- Infostealers do take credentials from artificial intelligence (AI) agents and coding assistants, either from signed-in browser and desktop sessions or from token and configuration files stored on disk.
- SpyCloud has recaptured logs from WardenStealer and Aoki, two families that collect local AI tool files, and Anthropic has named Vidar, Lumma, and other families for session theft.
- Stolen session tokens and keys replay a session that already passed authentication, so multi-factor authentication (MFA) never prompts.
- After an infection, clean the device first, then revoke sessions, tokens, and keys at each platform and connected service.
Infostealer malware copies saved credentials, cookies, and files from an infected device and sends them to an operator, who sells them as logs. Until recently, those logs held browser passwords and cookies. Developers now also run AI coding tools, and the tokens and keys those tools store connect to source control, cloud services, and pipelines. Stealers collect what buyers pay for, and underground shops now sell AI subscriptions and application programming interface (API) credit at steep discounts.
This post covers what infostealers take from AI agents and coding assistants, why the stolen tokens get past MFA, and what to revoke after an infection.
The blind spot IAM and ITDR share, when compared to identity threat protection, isn’t simply a technical distinction. Criminals actively exploit that blind spot, correlating stolen identity data across an employee’s past and present, personal and professional accounts to find entry points that none of your internal tools were ever positioned to see. And they increasingly don’t need much skill to do it, either.
What infostealers take from AI agents and coding assistants
Infostealers reach AI credentials by two routes, and the malware involved differs by route.
The first is the signed-in session. In late August, Anthropic warned Claude users that infostealer infections on their computers had let attackers hijack login sessions and run up usage, and the families it named include Vidar, Lumma, StealC, RedLine, Acreed, and Atomic Stealer.
Okta found the same pattern in a leaked log dump from 5,871 infected machines. Of its 44,791 unique JSON Web Tokens (JWTs), a common format for proving user login, 555 likely belonged to AI services, and the dump also held 24 still-valid API keys.
The second route is local files. Coding agents and AI desktop apps write tokens, keys, and configuration to a disk, and a stealer that already sweeps predictable folders for browser data can add those folders to its list.
SpyCloud has recaptured logs from two families that do this, WardenStealer and Aoki, and Gen Digital has documented AI agent collection in Remus and Amatera as well. Okta noted that newer variants have added explicit rules for AI provider API keys and known AI tool configuration paths. These are the same commodity malware-as-a-service stealers that have circulated for years, pointed at a new set of files.
Session cookies and tokens
A session cookie or token tells a service that someone already signed in. Whoever presents one is treated as that person, so a copied token carries the victim’s access with it. The logs SpyCloud analyzed contained:
- Session cookies: Aoki logs held cookie files for the Microsoft Store build of Claude Desktop and the ChatGPT desktop app, which sign in through an embedded web view that stores cookies the same way a browser does.
- Open Authorization (OAuth) tokens: These delegate account access. In WardenStealer logs, the Claude Code credentials file held access and refresh tokens for the account, and the Codex authentication file held them next to an OpenAI API key.
- API keys: A standing key works for whoever holds it, with no sign-in required at all. Okta found keys for Google Gemini, OpenAI, Groq, and OpenRouter in a single dump.
Config files and MCP credentials
The Model Context Protocol (MCP) is the standard that lets AI assistants connect to outside tools, databases, and services. Each connection needs a credential, and those credentials sit in local files. In WardenStealer logs, the Claude Code credentials file held tokens for connected MCP servers alongside the account’s own tokens, and the account configuration and the CLAUDE.md instruction file were collected too. A stolen instruction file or MCP configuration also describes the environment those tokens reach into, which tells an attacker where to go next.
Credentials like these belong to non-human identities (NHIs): API keys, tokens, and service accounts that act for software instead of a person. Critically, they don’t change when the person changes a password.
| AI tool | What the recaptured logs contained | Seen in |
|---|---|---|
| Claude Code | OAuth credentials file with access and refresh tokens, including tokens for connected MCP servers, plus account configuration and the CLAUDE.md instruction file | WardenStealer; Aoki collected the credentials and account configuration |
| Codex | Authentication file with an OpenAI API key and access and refresh tokens, plus its configuration | WardenStealer and Aoki |
| Claude Desktop | Configuration and plan-usage history; session cookies from the Microsoft Store build | WardenStealer (configuration); Aoki (cookies) |
| ChatGPT Desktop App | Session cookies from the embedded web session | Aoki |
| GitHub Copilot and Cursor | Token files | Aoki |
Why stolen AI tokens get past MFA
MFA verifies a person at the moment of sign-in. The service then issues a session cookie or token that stands for that sign-in, and subsequent requests present it instead of a password. A stealer copies the token from the device, and the attacker replays it from their own machine, often in an anti-detect browser, a tool designed to use stolen authentication data while avoiding security controls. The service sees a request that matches an existing, already verified session, so no password check or MFA prompt happens. API keys skip sign-in entirely, because the key is the credential.
Passkeys don’t change this. Okta’s research makes the point that phishing-resistant methods make password takeover harder, but do not stop a stolen session token or API key. The same replay follows phishing kits that relay a real login, and it is a routine technique: stolen session cookies and tokens now make up nearly half of the identity assets SpyCloud has recaptured.
One control targets replay directly. Google’s Device Bound Session Credentials tie a Chrome session to the device that created it, so a copied token fails on another machine. It covers browser sessions on supported setups, and it doesn’t reach API keys or the token files that coding agents write to disk.
What to revoke after an infostealer infection hits an AI tool
Order matters. Anthropic’s notice to affected users says signing out ends the stolen sessions but leaves the malware in place, so the infected device gets cleaned first. A stealer that is still running copies every new token the user creates.
Work through the steps below from a clean device, and treat AI tool credentials as in scope for any infostealer investigation on a developer’s machine. The post-infection remediation use case covers the wider process.
AI platform sessions and API keys
- Isolate the infected device and remove the malware before anything else.
- From a clean device, sign out of every active session at each AI platform the person used, across the browser, desktop app, and command-line tool.
- Change the account password.
- Revoke and regenerate API keys tied to the AI tool, then update the systems that use them.
- Review usage and audit logs for the exposure window. Look for unfamiliar sessions, new keys, and unexpected usage or billing spikes.
- If the tool signs in through single sign-on (SSO), revoke the user’s sessions and refresh tokens at the identity provider (IdP) as well.
MCP connections and service credentials
- Open the tool’s MCP configuration and list every connected server and the credential it uses.
- Revoke the OAuth grants and tokens at each connected service. Revoking at the AI tool alone leaves them valid at the service that issued them.
- Regenerate API keys and service account credentials stored in configuration files, and keep the replacements out of files on disk where a stealer would look.
- Rebuild the MCP connections with the new credentials and narrower scopes.
- Search source control and continuous integration and continuous delivery (CI/CD) logs for activity tied to the old tokens, since these tokens can reach repositories, cloud services, and build pipelines.
A password reset alone leaves much of this access in place, which is why each step above happens at the platform or service that issued the credential.
How SpyCloud helps security teams act on stolen AI credentials
Revocation starts with knowing a device was infected and what it lost, which most organizations learn only after misuse shows up. SpyCloud recaptures infostealer logs from criminal infrastructure, including logs from WardenStealer and Aoki, so it can see what these families took instead of inferring it from malware analysis. Endpoint Threat Protection flags infected devices and the cookies stolen from them, which tells a team which machines and accounts to start with.
For tools that sign in through the identity provider, Okta Workforce Guardian and Entra ID Guardian can revoke exposed sessions and refresh tokens automatically or after the team approves each action, and SpyCloud automates credential resets in as little as five minutes from discovery. Sessions and API keys held directly at an AI platform still need revocation through that platform, as the steps above describe.
See what stealers took from your workforce. Request a demo to see exposed identities, including infected devices and stolen sessions, matched to your people and resolved in the tools you already use.
Your organization's data may already be exposed.
Billions of assets from this year’s identity events are circulating right now.
FAQs
Most organizations can’t tell from the AI platform alone. Signs include sessions the user doesn’t recognize, new API keys, and usage or billing spikes, and some providers now notify affected users, as Anthropic did. Recaptured stealer logs give a direct answer, because they show whether a specific device’s tokens and keys were taken.
For local token and configuration files, SpyCloud has analyzed WardenStealer and Aoki, and Gen Digital has documented AI agent collection in Remus and Amatera. For browser and desktop sessions, Anthropic named Vidar, Lumma, StealC, RedLine, Acreed, and Atomic Stealer in its warning to Claude users.
It varies by service. A stolen token works until it expires or someone revokes it, and refresh tokens can keep generating new access for longer than the original token lasts. Okta found that many tokens in a leaked August 2026 dump were still unexpired on the day it was released, so waiting for natural expiry leaves the window open.
Generally no. Session tokens and API keys are separate credentials, and much of the access they carry survives a password reset. Anthropic’s notice asks affected users to change credentials and revoke sessions, which are two separate actions.