codeburn/src
Resham Joshi 887374de2c
feat(sharing): securely combine usage across your own devices (#532)
* feat(sharing): pairing, token, and device-identity core

First piece of local device sharing: self-cert fingerprint identity
(trust-on-first-use), a one-time expiring pairing PIN, fingerprint-bound
tokens, and a peer store that authorizes a pull only when both the token
and the TLS peer fingerprint match the same paired device. Pure logic,
fully unit-tested; the TLS share server and host pull build on this.

* feat(sharing): secure mutual-TLS transport + pairing handshake

Add device identity (self-signed cert, persisted; fingerprint = sha256 of
the cert DER), an HTTPS share server (mutual TLS: presents its cert, reads
the client's, and serves /api/usage only when the bearer token AND the
client fingerprint match the same paired peer), a one-time-PIN pairing
endpoint, and a fingerprint-pinning client. Verified end to end on
loopback: PIN pairing, pinned authed pull, and rejection of a wrong PIN,
a token replayed from another device, and a mismatched server
fingerprint. Adds the selfsigned dep (Node cannot generate certs natively).

* feat(sharing): share + devices CLI (pair, pull, combine)

Phase 3 terminal flow: codeburn share runs the secure server on-demand
(stops after 10 min idle; --always to persist, --pair to add a device),
and codeburn devices add <host> --pin <pin> pairs and pins a remote.
codeburn devices pulls this machine plus every paired device, keeps each
separate, and prints a per-device table with a simple summed Combined
row (no server-side merge). Persists identity and peers under the config
dir. Host pair-and-pull flow covered by a loopback integration test.

* feat(sharing): mDNS discovery + approve-style (no-PIN) pairing

Add bonjour-service discovery (advertise/browse over the LAN), a short
confirmation code derived from both cert fingerprints (Bluetooth-style
'do these match?' check), and an approve-style pairing endpoint that
prompts the owner instead of requiring a typed PIN. Loopback-tested:
approved device gets a working token with a matching code on both sides,
declined device is rejected.

* feat(sharing): AirDrop-style discover + approve UX

codeburn share now advertises on the LAN and approves incoming devices
interactively (confirm the matching code, no typed PIN). codeburn devices
add (no args) discovers nearby devices, lets you pick one, shows the
confirmation code, and waits for the owner to approve. Manual
add <host> --pin stays as a fallback for networks that block mDNS.

* feat(sharing): share only aggregates, never project names or paths

Sanitize each device's payload before it leaves the machine: drop
topProjects and topSessions (project names + session detail) and send
only aggregate numbers (cost, tokens, models, tools, activities, daily).
What you are working on stays local; only the totals travel.
2026-06-20 16:24:53 +02:00
..
data fix(pricing): restore Mythos 5 pricing dropped by gap-fill cleanup 2026-06-10 00:09:31 +02:00
mcp Merge PR #423 (local-model savings) onto main, re-homing payload savings into usage-aggregator 2026-06-06 22:14:13 +02:00
providers feat(opencode): read file-based JSON sessions (OpenCode 1.1+) (#523) 2026-06-19 19:04:51 +02:00
sharing feat(sharing): securely combine usage across your own devices (#532) 2026-06-20 16:24:53 +02:00
antigravity-statusline.ts refactor(cli): share persistent-codeburn resolver; tighten Antigravity hook ownership 2026-05-31 20:07:57 -07:00
bash-utils.ts Strip ANSI escapes from bash commands across all providers 2026-05-02 20:59:24 -07:00
classifier.ts File-aware retry detection with typed ToolCall (#379) 2026-05-22 01:21:42 -07:00
cli-date.ts Add multi-day calendar selection with custom popover UI (#393) 2026-05-24 09:49:59 -07:00
cli.ts Merge main into feat/multi-provider-plans, remove dead tautology 2026-05-16 10:42:03 -07:00
codex-cache.ts fix(codex): attribute MCP calls emitted as event_msg/mcp_tool_call_end (#513) 2026-06-18 22:32:40 +02:00
codex-credits.ts feat(codex): compute Codex credit usage (#408, #495) (#510) 2026-06-18 17:03:46 +02:00
compare-stats.ts feat(compare): model comparison with planning rate fix 2026-04-19 08:34:49 -07:00
compare.tsx Quiet routine pricing warnings + menubar recovery from stuck-loading (#266) 2026-05-08 20:33:48 -07:00
config.ts feat(providers): add Grok Build provider (#521) 2026-06-19 17:21:41 +02:00
content-utils.ts fix(parser): tolerate string message content; isolate per-file parse failures (#441) (#450) 2026-06-06 04:01:12 +02:00
context-budget.ts fix(context-budget): use bounded readSessionFile helper 2026-04-17 08:32:19 +02:00
currency.ts fix(network): add timeouts to critical-path fetches (#445) (#448) 2026-06-06 03:25:36 +02:00
cursor-cache.ts fix(cursor): period-aligned lookback; add Vercel AI Gateway provider (#432) 2026-06-09 23:01:43 +02:00
daily-cache.ts fix(daily-cache): purge cached today/future entries on hydration 2026-06-18 12:07:35 +02:00
dashboard.tsx fix(dashboard): scope the plan banner to its own provider tab (#524) 2026-06-19 19:04:54 +02:00
day-aggregator.ts feat(cli): track local-model cost savings against a paid baseline (#421) 2026-06-01 11:06:39 +03:00
export.ts feat(export): surface MCP server usage in JSON and CSV exports (#514) 2026-06-18 23:13:48 +02:00
fetch-utils.ts fix(network): add timeouts to critical-path fetches (#445) (#448) 2026-06-06 03:25:36 +02:00
format.ts Validator hardenings on the bug-hunt batch (#254) 2026-05-06 19:50:40 -07:00
fs-utils.ts Merge main into feat/multi-provider-plans, remove dead tautology 2026-05-16 10:42:03 -07:00
ink-win.ts Fix dashboard hang and ExperimentalWarning on Windows 2026-05-02 11:54:58 -07:00
main.ts feat(sharing): securely combine usage across your own devices (#532) 2026-06-20 16:24:53 +02:00
menubar-installer.ts fix(menubar): support installer HTTP proxies (#475) 2026-06-11 14:13:10 +02:00
menubar-json.ts feat(codex): compute Codex credit usage (#408, #495) (#510) 2026-06-18 17:03:46 +02:00
model-efficiency.ts feat(report): add per-model efficiency metrics 2026-05-05 23:36:59 -07:00
models-report.ts feat(codex): compute Codex credit usage (#408, #495) (#510) 2026-06-18 17:03:46 +02:00
models.ts feat(providers): add Grok Build provider (#521) 2026-06-19 17:21:41 +02:00
optimize.ts Add JSON output for optimize and yield 2026-06-18 12:13:17 +02:00
overview.ts feat(overview): plain-text monthly usage overview command (#528) 2026-06-20 11:46:45 +02:00
parser.ts feat(providers): add Grok Build provider (#521) 2026-06-19 17:21:41 +02:00
persistent-codeburn.ts refactor(cli): share persistent-codeburn resolver; tighten Antigravity hook ownership 2026-05-31 20:07:57 -07:00
plan-usage.ts Merge main into feat/multi-provider-plans, remove dead tautology 2026-05-16 10:42:03 -07:00
plans.ts feat(providers): add Grok Build provider (#521) 2026-06-19 17:21:41 +02:00
session-cache.ts fix(copilot): Implement durable sources for OTel DB parsing. 2026-06-17 21:42:40 +02:00
sqlite.ts Merge main into feat/multi-provider-plans, remove dead tautology 2026-05-16 10:42:03 -07:00
types.ts feat(report): Claude-scoped agent-type breakdown 2026-06-10 11:45:28 +02:00
usage-aggregator.ts feat(codex): compute Codex credit usage (#408, #495) (#510) 2026-06-18 17:03:46 +02:00
web-dashboard.ts feat(web): local React dashboard served by codeburn web (#531) 2026-06-20 16:21:25 +02:00
yield.ts Add JSON output for optimize and yield 2026-06-18 12:13:17 +02:00