OpenCode's 'Distillation Attack': What the Evidence Shows

On October 17, 2026, OpenCode, the open-source AI coding agent built by Anomaly Innovations, disclosed that a breach of a legacy Console system had exposed OpenAI, Anthropic, and Google API keys for about 1.4% of its Console users. Affected users reported drained balances, including about $400 in unauthorized Anthropic charges and about 200 euros in Google usage with a project suspended for abuse, before the company's statement landed. OpenCode called it a "large scale distillation attack," said it was working with all three providers, and said it could not yet confirm the exposed keys were misused. The short version: on October 17, 2026, OpenCode disclosed a breach that exposed API keys for roughly 1.4% of Console users, users reported drained balances first, and the company attributed it to a "distillation attack" while admitting it could not confirm misuse. Here is the claim-vs-evidence record, and what a distillation attack actually is.

Dated timeline of the OpenCode breach on October 17, 2026: user reports of drained balances, notification emails, the researcher's confirmation on X, and OpenCode's statement on a large scale distillation attack. Graphic by ByteHerald.
How October 17 unfolded, from the first drained balances to the official statement. Graphic by ByteHerald.

What happened, dated

OpenCode is an open-source AI coding agent that runs in the terminal, as a desktop app, and inside IDEs. It is model-agnostic: developers plug in their own keys from Anthropic, OpenAI, Google, and other providers and switch between them. The Console is the hosted side, where teams share model access from a workspace, set budgets, and connect their own provider keys. That hosted side is where the breach landed.

On the morning of October 17, affected users received an email saying OpenCode had found "unauthorized access to a legacy system that we were in the process of decommissioning" and that "third party provider keys (e.g., OpenAI, Anthropic) saved in your workspace may have been exposed." Around 10:18 Lima time, security researcher Matt Johansen posted on X that people were DMing him about keys running up charges. Twelve minutes later he posted: "Confirmed. OpenCode hacked. Keys stolen." Hours later came OpenCode's own statement: a breach "related to a large scale distillation attack that impacted 1.4% of OpenCode Console users," with everyone affected notified individually by email. The Hacker News thread on the breach passed 269 points within two hours.

OpenCode co-founder Dax Raad added a personal note on X: "my personal accounts are being attacked now too," calling it a "whole new world with ai powered hacking." The company says the incident is ongoing and it cannot share more details, and it is working with Anthropic, OpenAI, and Google on remediation. Affected users were told to revoke and reissue keys through each provider's dashboard, update any applications using them, and review recent usage.

Claim vs evidence: the 5-row scorecard

OpenCode's claimStatusEvidence
A "large scale distillation attack" hit about 1.4% of Console usersCompany claim, unchallengedThe statement, posted October 17; no independent count available
Only users who linked external providers were affected; no email means not impactedCompany claim, being tested by usersThe affected-users email; users are comparing notes on Hacker News and Reddit
Unauthorized access was to a legacy system being decommissionedCompany claimFrom the notification email; no technical details shared while the incident is ongoing
Whether the exposed keys were misused cannot be confirmedContradicted by user reportsNotebookcheck compiled Reddit reports: about $400 in unauthorized Anthropic charges, about 200 euros in Google usage plus a project suspension, and usage alerts arriving before OpenCode's warning
Working with Anthropic, OpenAI, and Google on remediationCompany claimStated in the October 17 statement; no provider has publicly confirmed its side yet

The honest gap is in row four. "Cannot confirm misuse" and "users reported charges before the warning" are not the same claim, and both can be true: the company may genuinely lack telemetry proving which queries were malicious, while users' billing dashboards show charges they did not make. Watch whether OpenCode revises this line. That is the number to hold them to.

The evergreen piece: what is a "distillation attack"?

The phrase raised eyebrows immediately, and that is the durable part of this story. In AI, distillation normally means training a smaller model on the outputs of a larger one. When a company calls a key-theft incident a "distillation attack," the implied motive is that the attackers did not want the keys themselves. They wanted free inference: burn someone else's paid balance to run queries against frontier models, then use the outputs, likely as training data. The victim's invoice is the attacker's compute bill.

That is also why the damage pattern looks the way it does. Attackers target high-end models because their outputs are the most valuable to distill, and the charges land on the victim because the key belongs to the victim. The security lesson generalizes beyond OpenCode, and it is the same one behind our 2026 AI security report card: treat every stored API key as a credit card, not a password. A leaked password gets you into an account; a leaked key lets someone spend your money at machine speed.

The practical routine, drawn from what security teams recommended within hours of the breach: revoke and reissue every provider key that ever touched a third-party console, through each provider's own dashboard; review usage and billing logs back to October 17; set spend limits and usage alerts on every key, because OpenCode users with alerts learned about the breach from their providers before they learned it from OpenCode; and never reuse one key across tools, so a single exposure cannot drain every account at once. For how these agent systems fail in production more broadly, see our catalog of AI agent failure modes.

ByteHerald's reading: the terminology question

One aggregator questioned the term itself, noting that "distillation attack" usually describes model training, not key exposure. But the motive theory above suggests the label may be precise rather than sloppy: if the attackers were draining balances specifically to generate outputs for training, then "distillation attack" is exactly what it was, and it is a new line item in the threat model for anyone who stores keys in a vendor console. The more interesting question is what the legacy system was doing storing workspace keys at all, and why decommissioning lagged exposure. OpenCode says details must wait while the incident is ongoing. That is the reasonable part of the statement. The unreasonable part would be leaving "cannot confirm misuse" as the final word while user billing says otherwise.

By ByteHerald Staff. Breach facts from OpenCode's October 17 statement and notification email (quoted on X by @opencode and by co-founder Dax Raad), user charge reports compiled by Notebookcheck from Reddit, and security researcher Matt Johansen's X posts. "Distillation" definition per standard AI usage; motive reading is ByteHerald's analysis. Graphics are ByteHerald's original compilations.


 

BH
Written by