OpenCode Hacked: User credentials leaked
Posted by pranshuchittora 4 days ago
Comments
Comment by redsymbol 4 days ago
The leak was for something called 'OpenCode Console', which is distinct and separate from the OpenCode coding agent. If you're just using the coding agent, you're not affected. 'OpenCode Console' is a service that is similar to OpenRouter, but is much less widely used.
The name 'OpenCode Console' is super confusing, because one might think it means the CLI coding agent. It does not. 'OpenCode Console' has nothing to do with the CLI/TUI coding agent, nor the desktop app version.
The situation is made worse by the fact that 'OpenCode Console' barely has any documentation online, and the official leak announcement does not make the distinction clear at all. The OpenCode team did a terrible job of communicating this, and that's on them.
Today is a bad day for people using 'OpenCode Console'. But most people, probably the vast majority of OpenCode users who are reading this, are not using 'OpenCode Console'.
Comment by wren6991 4 days ago
Comment by jerieljan 4 days ago
So far, "OpenCode" has gone through several possible definitions:
- OpenCode Terminal / CLI - This is what you get normally. Runs a service in the background and the CLI is your interface.
- OpenCode Desktop - Instead of a CLI, you get a desktop interface.
Most users usually stop here. You just install the app and you connect wherever.
So there's the services where they both make money and make things easier for users:
- OpenCode Console - Basically the serving platform for both Zen and Go, and has expanded to a hosted inference gateway and somewhat similar to OpenRouter or a managed LiteLLM. Has the option to BYOK if you have existing AI platform accounts so it charges those instead of Zen, and that's what got compromised.
- OpenCode Zen - the API service they host if you want to get access to providers but don't want to pay individually per API platform. Similar to OpenRouter. I noticed they're kinda slowly dropping the Zen moniker.
- OpenCode Go - the subscription service that they host that features open weight models and select low-cost models from frontier labs. Has different policies when it comes to privacy and retention compared to Zen.
- OpenCode Black - a limited-time, limited access subscription service that grants access to frontier models. Not sure if this is still alive or not.
Comment by john01dav 4 days ago
Comment by redsymbol 4 days ago
Comment by PalmPilotProMax 4 days ago
Or Open Code Rust?
Comment by pranshuchittora 4 days ago
Comment by pranshuchittora 4 days ago
Comment by an0malous 4 days ago
Comment by esalman 4 days ago
Comment by latexr 3 days ago
Comment by ShowalkKama 4 days ago
Comment by canadiantim 4 days ago
Comment by yorwba 4 days ago
Comment by Barbing 4 days ago
Comment by pranshuchittora 4 days ago
Comment by qsod 3 days ago
Comment by pranshuchittora 4 days ago
Comment by senordevnyc 4 days ago
Comment by pranshuchittora 4 days ago
Comment by senordevnyc 4 days ago
Comment by xendo 4 days ago
Comment by throwoutway 4 days ago
Comment by an0malous 4 days ago
Comment by _fw 4 days ago
Comment by xendo 4 days ago
Comment by pranshuchittora 4 days ago
Comment by OuterVale 4 days ago
Comment by alfiedotwtf 4 days ago
Comment by ryandrake 4 days ago
Comment by trollbridge 4 days ago
Comment by tekacs 4 days ago
Comment by cassianoleal 4 days ago
If they took payment, they are liable and they must have the ability to refund.
Comment by pranshuchittora 4 days ago
Comment by tekacs 4 days ago
Comment by pranshuchittora 4 days ago
Comment by cassianoleal 3 days ago
Comment by Ciantic 4 days ago
Comment by Tiberium 4 days ago
https://docs.github.com/en/code-security/reference/secret-se... has a table with the active partners
Comment by Ciantic 4 days ago
Comment by ameliaquining 4 days ago
Comment by weknowbetter 4 days ago
Comment by orf 4 days ago
Comment by shepherdjerred 4 days ago
Comment by orf 4 days ago
If they are acting maliciously, they will take the choice that most hurts you and/or benefits them.
If the key is useless to them and revoking it hurts you, then they would do that.
If the key wasn’t useless to them, then… they would just use it and not revoke it?
Comment by asdfaoeu 4 days ago
Comment by orf 4 days ago
Unilaterally decide they should be revoked, without contacting the owner?
And that’s not malicious?
Comment by drawfloat 4 days ago
Comment by orf 4 days ago
Be serious.
Comment by drawfloat 4 days ago
If it’s that sensitive and there’s access keys accessible to anyone, it could end up much worse. Nobody said it was without inconvenience.
Comment by orf 4 days ago
Non-malicious actors using it to bring down a system via revocation are therefore indistinguishable from malicious actors. It’s by definition a malicious act.
That’s why it’s a stupid idea. Non-malicious actors should just contact the company and let them take action. It’s not for an outsider to decide the impact of a leak.
Comment by drawfloat 1 day ago
Comment by orf 1 day ago
Comment by drawfloat 1 day ago
Comment by orf 1 day ago
Also GitHub doesn’t revoke the keys. The providers of the key take provider-specific actions, which may or may not be revocation.
So… yeah.
Comment by drawfloat 1 day ago
Comment by orf 21 hours ago
Comment by GoblinSlayer 4 days ago
Comment by orf 4 days ago
For example AWS applies a “quarantine” policy that prevents some specific actions[1].
Allowing anyone to report a potentially compromised key is one thing, but allowing anyone to unilaterally revoke a token is another.
1. https://docs.aws.amazon.com/aws-managed-policy/latest/refere...
Comment by GoblinSlayer 3 days ago
Comment by shepherdjerred 4 days ago
Comment by orf 4 days ago
> I think every API key system should have endpoint "invalidate_api_key"
Not this.
Comment by shepherdjerred 3 days ago
What is your alternative idea?
No idea why you’re being so hostile here.
Comment by orf 3 days ago
The status quo is clearly the local minima, given the myriad of trade offs and different parties involved.
Comment by flaunf221 4 days ago
Comment by computerex 4 days ago
Comment by ameliaquining 4 days ago
Comment by InsideOutSanta 4 days ago
Comment by NewsaHackO 4 days ago
Comment by InsideOutSanta 4 days ago
It's in their announcement; it's just not written in a way that people immediately understand.
Comment by verdverm 4 days ago
Run a gateway like GoModel instead of uploading your keys to a vendor to prevent this class of attack in the future.
https://gomodel.enterpilot.io/ (my preferred gateway)
Comment by pranshuchittora 4 days ago
Comment by djchen 4 days ago
In essence they used OpenCode Zen similar to OpenRouter, where you can BYOK or use theirs and be charged token rates.
Comment by nightpool 4 days ago
Comment by jchw 4 days ago
Comment by hahajk 4 days ago
https://dev.opencode.ai/console/
It's actually kinda hard to figure out what it is. But it does appear to be different that the CLI
From https://opencode.ai/v2/docs#connect :
> If you’d like easy access to all the best coding models you can try out OpenCode Console.
Comment by neya 4 days ago
Comment by santiago-pl 2 days ago
1. Last Friday I noticed that one of my OPENAI keys had used up my spending limit in the OpenAI Console.
2. Today I got the e-mail from OpenAI quoted below.
3. I haven't got any e-mail from OpenCode about it.
I can’t remember using this OpenCode Console. Can anyone explain to me what happened?Mail from OpenAI:
Subject: OpenCode incident: update on your API keys and reimbursement
Body:
Hello,
We're writing about a security incident reported by OpenCode, a third-party AI coding tool. OpenCode reported unauthorized access to a system that stored customer API keys.
An OpenAI API key associated with your organization, [masked], was identified as affected. The affected OpenAI API keys are no longer active and cannot be used to make new API requests.
API usage is billed to the organization associated with the key, including when an exposed key is used without authorization. As part of our review, we have applied a one-time courtesy adjustment to address the charges associated with the unauthorized usage we identified. (...)
Comment by rozenmd 4 days ago
The opencode CLI has no impact.
Comment by Rapzid 4 days ago
Comment by qlte 4 days ago
Comment by Rapzid 4 days ago
Headlines are designed to capture attention and readers, how much detail does it need to go into? It's not dishonest or misleading but yes it's attention grabbing.
Comment by NewsaHackO 4 days ago
Comment by verdverm 4 days ago
Comment by fleshers 4 days ago
Comment by pranshuchittora 4 days ago
Comment by ipsum2 4 days ago
Comment by verdverm 4 days ago
OpenCode, and the lot, will need to release an open, public, dataset containing the original queries (and other relevant details) that the hacked keys were used for. I'm unwilling to trust those industry players at their word. We need to do our own community analyses.
Comment by verdverm 4 days ago
Comment by vdfs 4 days ago
Comment by NewsaHackO 4 days ago
Comment by odo1242 4 days ago
Comment by pranshuchittora 4 days ago
Comment by monster_truck 4 days ago
The way some of this place's employees post and act online, can't say I feel all that bad.
Comment by oldfuture 4 days ago
that's why virustotal was flagging it then
Comment by ameliaquining 4 days ago
Comment by verdverm 4 days ago
run a gateway like LiteLLM or GoModel, don't upload keys to a vendor
- https://gomodel.enterpilot.io/ (my preference)
Comment by tonymet 4 days ago
Hackers breached an Open Code legacy system containing customer keys for openai etc, and ran up large bills against the customer's openai accounts . The tokens were used to train the hacker's ai models (the distillation).
My guess is a more primitive arbitrage / resale attack . Like reselling EBT cards or "free" vpn traffic.
Comment by latchkey 4 days ago
you login to their website, and you are presented with a list of providers where you can click and add your provider api key.
how the key is stored on the backend isn't clear, but it is akin to handing your password or if you know crypto, your private key, to someone and letting them store it for you.
from what i can tell, there are no links within the console to a ToS, Privacy policy or anything else. there are no warnings or documentation about how they store your keys.
someone else in this thread linked to this issue, but this comment is especially insane given that i can't find any privacy policy or tos for the console.
https://github.com/anomalyco/opencode/issues/10416#issuecomm...
Comment by verdverm 4 days ago
Comment by latchkey 3 days ago
Comment by verdverm 2 days ago
I've heard Dax has a number of "social media stunt" kinds of posts and others showing them being rather unprofessional (eg. something that appears to be excessive drinking at a company event)
Comment by latchkey 1 day ago
Comment by InsideOutSanta 4 days ago
Comment by latchkey 4 days ago
Comment by verbo_villain 4 days ago
Comment by jprokay13 4 days ago
Comment by NewsaHackO 4 days ago
Comment by AmazingEveryDay 4 days ago
Comment by verdverm 4 days ago
I would like to see the companies release an open dataset of the attackers queries, such that we can do our own analyses as a community. Public trust is in the xitter with these folks.
Comment by pranshuchittora 4 days ago
Comment by TZubiri 4 days ago
https://news.ycombinator.com/item?id=50075319
https://news.ycombinator.com/item?id=50060694
what’s interesting is that all those efforts that go into sandboxing through virtualization wouldn’t have helped here. But the solutions that proxy the api keys and hide them from agents might have worked as a defense in depth.
of course any sensible engineer that uninstalled this 6 months ago and used codex and claude code directly also avoided this, gg
Comment by nrmitchi 4 days ago
Exterior-compliance proxies, yes, are a good thing; but are also completely unrelated to the fact that OpenCode's hosted solution, that requires having credentials in some fashion, was popped.
Shitting on anyone who uses OpenCode (rather than your preferred vendor-specific product) as not being "sensible" is also completely out of hand and unnecessary.
Comment by verdverm 4 days ago
Our read on the situation is too much eyes and brain free coding, that they assumed the ai redesign of the configuration system was sound. It took a couple of PRs and explanations for them to bring the system to a better place, such that MDM config was respected at the highest priority.
I do give the OpenCode team a lot of credit, at least Aiden, for the handling of this case.
https://github.com/anomalyco/opencode/pull/51337#issuecommen...
I'm now trying to get the Pi harness to support MDM, but it is not going well... see this and please consider sharing your perspectives or support there
Comment by searealist 4 days ago
> related to a large scale distillation attack
I'm not sure how this adds up. I could understand if this impacted their uptime, but not security.
Are they actually saying a bunch of credentials were stolen and are being used for distillation?
Comment by pranshuchittora 4 days ago
Comment by thway15269037 4 days ago
Comment by verdverm 4 days ago
you can learn more from here, they did handle that one much better, all-in-all
Comment by bakugo 4 days ago
Comment by glub 3 days ago
Account farming is one thing, and nobody apart from who's being distilled cares about that, but draining wallets of other people is a whole other thing.
Comment by pranshuchittora 4 days ago
Comment by Flere-Imsaho 4 days ago
Comment by verdverm 4 days ago
I would recommend running your own gateway instead of uploading keys to a vendor. My gateway of choice is GoModel
Comment by GoblinSlayer 3 days ago
Comment by zephiel7 4 days ago
Comment by rvz 4 days ago
Comment by verdverm 4 days ago
Comment by pranshuchittora 4 days ago
Comment by mikalauskas 4 days ago
Comment by 9021007 4 days ago
Comment by MisterMunchkin 4 days ago
Comment by nacs 4 days ago
Comment by qlte 4 days ago
Comment by malisper 4 days ago
Comment by pranshuchittora 4 days ago
Comment by verdverm 4 days ago
Comment by Xavier_da1 4 days ago
Comment by vinni2 4 days ago
Comment by progval 4 days ago
Comment by himata4113 4 days ago
Comment by trollbridge 4 days ago
Comment by dist-epoch 4 days ago
Comment by kelvinjps10 4 days ago
Comment by verdverm 4 days ago
Use a gateway like LiteLLM or GoModel, don't upload keys to a vendor, they are doing too much eyes and brain free coding this year
- https://gomodel.enterpilot.io/ (my preference)
Comment by drewfax 4 days ago
Comment by verdverm 4 days ago
We do not know if that is what the hacked API keys were used for. Could be distillation, could be API reselling. We will need more transparency into the nature of the requests made by the attacker. I would like to see an open dataset of the queries made with the compromised keys. All of them as originally made, not aggregate stats or another METR report.
The keys could have also been used to resell API access on the black market, again, we need good transparency to know. Considering the upstream parties involved, getting the distillation narrative out there early, without evidence, does fit a larger pattern we have seen from them this year.
Comment by yipinwong 4 days ago
Comment by lifeisloving 4 days ago
They're skipping past the fact thay keys were even accessible by an intruder... Like huh?? They say its only third party keys, but all my opencode keys were deactivated in tbe process... Why is that, were they storing keys in virtually plain text...
Opencode CEO, Dax, brags all day on twitter (in the most narcissistic fashion) about how much they vibecode and how fast they move. Well, it really shows.
Not to mention, Ive tried to cancel my subscriptions and was double charged, they reverted one of them, then I cancelled again and was charged again....
Comment by segfault99 4 days ago
Similarly woke up this morning to find my OpenCode Go API key had been revoked (remaining monthly usage allowance fortunately not touched).
Whether that was precautionary or is evidence of wider data leak, who knows?
Concur that OC's X messaging is mostly 'Marketing by Sounding off like a Dick' and they're certainly not known for having the best documentation either.
Comment by lifeisloving 4 days ago
Comment by hypfer 4 days ago
It's not like there wouldn't be any other harnesses either. Just switch to literally anything else please.
Comment by john01dav 4 days ago
The other issue: https://news.ycombinator.com/item?id=49655991
Comment by segfault99 4 days ago
Comment by ssernikk 4 days ago
Comment by mamaluigie 3 days ago
Comment by preommr 4 days ago
I looked at the linked comments, and they seem valid. I mean I dont want to go full tinfoil hat here, but what's the deal? Some people just really like opencode or something?
Comment by c-hendricks 4 days ago
Comment by verdverm 4 days ago
Comment by jchw 4 days ago
Comment by himata4113 4 days ago
Comment by dylan604 4 days ago
Comment by himata4113 4 days ago
Comment by InsideOutSanta 4 days ago
Comment by verdverm 4 days ago
My read is too much vibemaxxing, not enough critical analyses of the Ai output and (re)designs of various systems in their code base.
Breaking Rule #2 - never blindly trust the output from Ai
Comment by sharts 4 days ago
Comment by kingds 4 days ago
Comment by SifatAhmed 5 hours ago
Comment by pranshuchittora 4 days ago
---
Hi, We identified unauthorized access to a legacy system that we were in the process of decommissioning. Third party provider keys (eg OpenAI, Anthropic) saved in your workspace may have been exposed. Please revoke and replace those keys through the relevant provider’s dashboard, update any applications using them, and review recent usage for unexpected activity.
We’re sorry this happened and will follow up with any updates.
Comment by sebastiansm7 4 days ago
Comment by TZubiri 4 days ago
Comment by qlte 4 days ago
This was a leak of keys added in a web UI
Comment by ocsec_1054 11 hours ago
Comment by karolkk 2 days ago
Comment by --__-- 4 days ago
Comment by IVski 4 days ago
Comment by shuttlewright 3 days ago
Comment by vc14 4 days ago
Comment by yuhond 4 days ago
Comment by pang_claw 4 days ago
Comment by bewareofscams 4 days ago
Me, 68 days ago:
> Beware of the author of tweet, who happens to be author of OpenCode - OpenCode will leak all your data to themselves and to shady 3rd parties. Author feigned ignorance and never fixed the issue. OpenCode among other harnesses is the shadiest of all.
Comment by lukewarm707 4 days ago
I did have an account but moved off for security reasons.
Comment by neya 4 days ago
Comment by tadasv 4 days ago
Comment by verdverm 4 days ago
Comment by lousken 4 days ago
Comment by Reyonlds96 4 days ago
That is it. It is still private by default
Comment by anonymous908213 4 days ago
All it "ever did" was send your entire prompt/context to a "free" model for harvesting. The astroturfing in this thread is absurd.
Comment by Reyonlds96 4 days ago
Maybe try a sensible approach first, cause so far this is assumed, for no reason, to be done maliciously. "to steal data" and the like.
Opencode's source code is public, so you can verify any claim against it directly.
Comment by NavinF 4 days ago
Comment by Reyonlds96 4 days ago
During this short period - yes. Unless it finds a valid small model, or you set one yourself - it would use the one provided by zen. or you could disable it with an invalid model altogether. Good gesture for most users and something else to others.
It's *could by the way, as this was only a short window when this was a thing. It went back to not having this fallback pretty fast, i don't think it even lasted a month.
Comment by NavinF 1 day ago
Comment by whisper49 4 days ago
Comment by luochen1990 4 days ago
Comment by DavCreator 4 days ago
Comment by bewareofscams 4 days ago