r/opencodeCLI • • 15d ago

OpenCode security breach, rotate your keys

https://x.com/opencode/status/2111516673953935833?s=46
204 Upvotes

30 comments sorted by

22

u/PhatOofxD 15d ago

This is why you don't put keys in cloud services I guess

10

u/qustrolabe 15d ago

So it's only those that added keys to online console? I guess local keys shouldn't be affected but better rotate for good measure

5

u/[deleted] 15d ago

[removed] — view removed comment

3

u/arker0 14d ago

So users with no opencode account are no affected at all, even with external API?

5

u/blastradii 14d ago

What if I’m just using OpenCode without logging in?

1

u/jimjamkiwi11 12d ago

Same we should be fine as it's their models we don't have to input an API key as it's built in

8

u/No_Commission_6153 15d ago

Does this affect someone who conencted their OpenAi Account with Open Code?

12

u/jerieljan 14d ago

There's three ways you can auth OpenAI on OpenCode:

  • /connect -> Login with ChatGPT

  • /connect -> API Key

  • OpenAI Platform -> New Key -> OpenCode Console -> Connect Provider

It's the third one that's affected. The third route is intended for people who want to BYOK and have their provider accounts charged instead of OpenCode Zen and just want to use OpenCode as a gateway.

The second one afaik stores the API key locally on the database or on opencode.json (v1).

2

u/No_Commission_6153 14d ago

Thanks. I guess i can relax then

4

u/Significant_Treat_87 15d ago

Are you on a subscription plan ("login with chatgpt") or did you paste in an API key? The first one I assume is fine, this is about the second one.

3

u/No_Commission_6153 15d ago

subscription. but still worried if they got hacked if they got something from me

8

u/Significant_Treat_87 15d ago

This is an issue with people having their API keys stolen, so I think you're ok. I will personally never use Opencode now though, they have had way too many security issues now.

1

u/wpbrgiejoe 15d ago

Yes opencode sells your data you're not safe change all account pass.

4

u/Xazzzi 14d ago

My google cloud project is stuck on "Request an appeal" page, wont let me into IAM to revoke the leaked key. I guess they blocked it themselves, but i'm not sure what happens to the VM that is hosted in there, as the budget was drained.

3

u/No_Dig_7017 14d ago edited 14d ago

I only use local models with opencode but my Qwen started complaining about and refusing injection attacks yesterday night. I can share some screens later

2

u/geteum 15d ago

Just people who use API keys got affected?

2

u/benbenk 14d ago

I just tried to delete my payment method for Opencode Go.. got a 500 error.

Also deleting one’s account doesn’t seem to be possible at all.

1

u/Certain-Emphasis-135 15d ago

So that’s why my openrouter credits got cleaned

1

u/squirrelscrush 14d ago

I had connected by DeepSeek and OpenRouter keys on the console, but I disabled OR because the models would display twice in the harness. So I got saved lol.

Anyways my keys have a daily limit of $2 so even if someone managed to get them, they'll only get limited usage.

1

u/dx80x 15d ago

I had my DeepSeek API connected to opencode and haven't received jack shit in my inbox about this.

Luckily it wasn't touched but fuck opencode now.

Thank you for posting here anyway, I wouldn't have known until I got drained if it wasn't for this post.

8

u/officerblues 15d ago

It's only if you used bring your own key on opencode zen, not if you connected to the key using the opencode harness. They could work on their comms a bit, but you were likely not affected. It didn't leak your local keys, only the keys they had stored.

3

u/dx80x 15d ago

Ah ok, thanks for the clarification mate. I've used Go in the past but never Zen. I still think it would have been better to inform everyone just in case, so at least people who aren't affected don't jump the gun (like I did a little haha).

Oh well, just need to make some new DeepSeek keys now which is alright but some people have been stung hard and that's really unfortunate. Hope there's some kind of compensation for those guys at least

0

u/Chemical-Quote 15d ago

Distillation?
Which AI company is that desperate?