Skip to content

feat(share): member adopt, min_cli enforcement and live member shares - #77

Merged
tieubao merged 4 commits into
mainfrom
feat/members-adopt-mincli
Nov 15, 2026
Merged

tieubao merged 4 commits into
mainfrom
feat/members-adopt-mincli

Conversation

@tieubao

@tieubao tieubao commented Nov 15, 2026

Copy link
Copy Markdown
Member

What

Spec tasks done: member adopt (3e), WebSocket through the binding (3f, pass branch) and min_cli enforcement (4a).

  • share member adopt <name> --token-id <id> [--by <label>] registers an R5 publisher's own bucket-scoped token as an active cloud member. The token must be in the minter's list and scoped to this bucket plus Zone Read; it is renamed in place so member rm, renew and invite find it. New code adopt_token_scope.
  • Every bucket write (PUT, DELETE) below the marker's min_cli dies cli_below_min; reads stay open. share.json stays writable; member rm, purge and leave are never held back by a forged marker; setup --members --yes resets a marker above this share.
  • A live probe on Console Labs showed a Worker VPC binding carries a WebSocket upgrade and a streamed body, so a member's add <port> publishes a live row (v:3 opts live). Worker 6 forwards the upgrade and answers a fresh 101; a live row keeps its app's own type under the sandbox.

Proof

docs/verification/members-adopt-mincli.md: the runs, the negative controls (red and green) and the live probe record (four runs, cleaned up by name).

Review

kit:advisor and kit:security-reviewer on the diff. One high (a comma list of types skipped the sandbox), three major (the 101 carried the machine's headers, a whole-run guard bypass in setup --members, adopt of a token another member holds) and the minors are fixed; notes P62.

Not attempted

  • A live run of the share Worker on a tenant with a bucket (R2 is off on Console Labs); the live tenant acceptance is a later sub-goal.
  • POST and other methods through a live member row (GET, HEAD and the upgrade only).
  • README, how-it-works, setup, SYSTEM-DESIGN and CONTEXT (owned by later sub-goals; listed in the notes).
  • tests/worker.mjs is outside this sub-goal's Touches; the Worker source changed there, so its rows and a --ws harness option are in this PR.

member adopt registers an R5 publisher's own bucket-scoped token as an
active cloud member (renamed in place so rm and renew find it). Every
bucket write below the tenant marker's min_cli dies cli_below_min; reads
stay open, share.json stays writable, member rm, purge and leave are never
held back, and setup --members resets a forged marker after a yes.
A member's add <port> now publishes a live row: a live probe on Console
Labs showed a Worker VPC binding carries a WebSocket upgrade and a
streamed body, so the v:3 pointer takes the live opt and Worker 6 returns
a fresh 101 for it.
@tieubao
tieubao merged commit 66903f9 into main Nov 15, 2026
15 of 16 checks passed
@tieubao
tieubao deleted the feat/members-adopt-mincli branch November 15, 2026 16:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant