OpenCode Hacked: User credentials leaked

twitter.com

579 points by pranshuchittora 4 hours ago


pranshuchittora - 4 hours ago

I am the author of this post. Looks like OpenCode fans / team is not happy with this post coming on the first page of HN. It has already been flagged by many. I never ask for upvotes, but would be great if you can upvote it. Thanks!

Ciantic - 3 hours ago

I think every API key system should have endpoint "invalidate_api_key" this way whitehat hackers or the party who stored them could invalidate all keys in the case they leak. Now it is race against the time, and everybody got email, and everyone must act themselves.

computerex - 3 hours ago

Why are my API keys in the workspace exposed? Does OpenCode send my API keys to their backend servers??? Was this a supply chain attack that infected the opencode program itself? What is going on?

djchen - 3 hours ago

Is my understanding correct that this only affected some OpenCode Zen users who stored their (BYOK) API keys from Anthropic/Google/OpenAI?

In essence they used OpenCode Zen similar to OpenRouter, where you can BYOK or use theirs and be charged token rates.

jchw - 4 hours ago

I don't use OpenCode but I would like to know who this impacts. Surely people who are just using OpenCode locally with their own credentials wouldn't be impacted, right? This sounds like something where you have a hosted service and you put your keys into that. Not saying this isn't bad, but it isn't clear and they're not sharing any information.

rozenmd - an hour ago

@dang this title needs updating: "OpenCode Console hacked: User credentials leaked"

The opencode CLI has no impact.

oldfuture - 4 hours ago

https://news.ycombinator.com/item?id=50108261

that's why virustotal was flagging it then

monster_truck - 3 hours ago

Wait, is the openchode hack the cause of all the people complaining about their OAI usage getting drained/vanishing at alarming rates? That's pretty funny ngl.

The way some of this place's employees post and act online, can't say I feel all that bad.

fleshers - 4 hours ago

I’m a bit confused by the wording here, does it mean the credentials were hacked and then used to perform a mass distillation campaign?

verbo_villain - 4 hours ago

So are people going to wake up and see their Anthropic, openAI, etc accounts drained?

thway15269037 - 3 hours ago

Was it opencode who bragged about their vibecoding tokenmaxxing attitude or I'm mixing them with someone else?

hypfer - an hour ago

They have shown so so so many times that their culture is not aligned with trustworthy software. Yet people keep using it.

It's not like there wouldn't be any other harnesses either. Just switch to literally anything else please.

pranshuchittora - 2 hours ago

Awaiting for detailed breakdown of the incident. I am more interested in knowing , how can a distillation attack leak / expose credentials.

MisterMunchkin - 3 hours ago

It’s fascinating that tokens are so valuable that people are spending so much time and effort hacking to obtain API keys.

searealist - 3 hours ago

> security breach

> 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?

yipinwong - 2 hours ago

wtf was I getting many use OpenCode on OpenCode cloud emails last few days. Were they set up so that hackers can get more info?

9021007 - 2 hours ago

https://nitter.click/opencode/status/2111516673953935833

latchkey - 2 hours ago

the ux is kind of crazy.

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...

vinni2 - 4 hours ago

But isn’t OpenCode open source why does it need credentials.

rvz - 3 hours ago

Looking forward to the post-mortem of this incident.

preommr - 4 hours ago

Why are the comments pointing out there were warning signs early on being downvoted/flagged?

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?

TZubiri - 2 hours ago

4 days ago red flags were raised

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

pranshuchittora - 4 hours ago

From OpenCode Team

---

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.

vc14 - 3 hours ago

[flagged]

bewareofscams - 4 hours ago

I told you so: https://news.ycombinator.com/item?id=49243119

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.

> https://github.com/anomalyco/opencode/issues/10416

DavCreator - 4 hours ago

https://xxcancel.com/opencode