codeburn
codeburn copied to clipboard
Desktop: Grok Bot quota sends the wrapped Cursor safe-storage token
Follow-up to #1924, which fixed the CLI and the macOS menu bar.
The desktop app has its own Grok Bot quota reader in app/electron/quota/grokbot.ts. It reads cursorAuth/accessToken from Cursor's state database and sends it as the Bearer token unchanged. On Cursor 3.27 and newer that value is wrapped as cursor-safe-storage:v1:<base64>, so Cursor answers 401 and the Grok Bot card shows "sign in again" for every signed-in user.
The desktop has no Cursor Safe Storage decrypt path at all (no live Cursor quota either; Cursor sync decryption happens in the CLI), so the fix needs a decision:
- route the desktop's Grok Bot quota through
codeburn quota --format json, which drops the card's connection state, or - add a decrypt path to Electron that follows the Keychain consent policy from #1802 (unlock only on a user action, background after one consent, stop at Deny), sharing one read with any future desktop Cursor quota.
Affected: Grok Bot quota card in the desktop app, Cursor 3.27+, macOS.