Repository navigation
Closed
Labels
app/idPackage/app: id (pkgs/ or apps/ in this repo)Package/app: id (pkgs/ or apps/ in this repo)effort/lLarge: multi-day or open-ended; expect staged check-insLarge: multi-day or open-ended; expect staged check-inskind/featureNew feature or capability requestNew feature or capability requestpriority/normalOrdinary priority (the default)Ordinary priority (the default)source/queue-workerFiled or worked by the queue/worker pilotFiled or worked by the queue/worker pilotstatus:done
Description
Split from #5119 (task 14074) — the one acceptance item explicitly re-scoped there by lane code-u (2026-11-11T02:03Z note) and confirmed by lane code-m on merge of PR #8413.
Verified state
seitan::Invite::admit(&mut self, proof, now_ms, window)already takes the freshness window as a parameter, andServerConfig::freshness()already returns the configured window ([policy] freshness_window_seconds, landed under id phase-8/platform-completion: freshness-window and pull-policy config are not wired into server/world settings or CLI defaults #798/id(serve): no production caller for ServerConfig — load it in id serve and consume [policy] (pull gate, freshness) + provisioning #5119 slice 1).Invite::admithas no production caller. No serving path (protocol, endpoint, or hub op) receives a seitan proof today, so there is nothing to wire the window into yet — this is a design-first slice, not a wiring change.- Everything else in id(serve): no production caller for ServerConfig — load it in id serve and consume [policy] (pull gate, freshness) + provisioning #5119's acceptance list is landed: config load + startup provisioning (PR feat(id): id serve loads ServerConfig + startup provisioning (#5119 slice 1) #5187), live pull policy incl. fail-closed members on the local store (PR feat(id): serve builds its event-sync pull gate from [policy] (#5119 slice 2) #8046), persisted provisioning (PR feat(id): persist server-config provisioning into live serving state (#5119 slice 3) #8356), and seeding configured accounts into the serving world directory (PR fix(id): seed configured accounts into the serving world directory (#5119) #8413).
Scope
Design and build the minimum serving admission path that id serve runs:
- Decide where seitan proofs arrive (protocol message / endpoint / hub op) and where invites are registered and held.
- Decide which world an admitted invite joins, and the failure behavior for unknown/expired invites.
- Call
Invite::admitfrom that path withServerConfig::freshness()as the window (no-config behavior unchanged). - Record the design decisions on this issue before/with the implementation.
Acceptance
- A non-default configured freshness window is exercised at the admission boundary: a proof inside the window admits, a proof outside it refuses, through the live serve path (not only config accessors).
- Integration tests cover admit/refuse at the boundary and the no-config default.
- On completion, check off the id phase-8/platform-completion: freshness-window and pull-policy config are not wired into server/world settings or CLI defaults #798 brief line-76 item and close id(serve): no production caller for ServerConfig — load it in id serve and consume [policy] (pull gate, freshness) + provisioning #5119 (its last open item) with the evidence.
Metadata
Metadata
Assignees
Labels
app/idPackage/app: id (pkgs/ or apps/ in this repo)Package/app: id (pkgs/ or apps/ in this repo)effort/lLarge: multi-day or open-ended; expect staged check-insLarge: multi-day or open-ended; expect staged check-inskind/featureNew feature or capability requestNew feature or capability requestpriority/normalOrdinary priority (the default)Ordinary priority (the default)source/queue-workerFiled or worked by the queue/worker pilotFiled or worked by the queue/worker pilotstatus:done
Activity
developing-today commentedon Nov 11, 2026
CODE-2537
dezren39 commentedon Nov 11, 2026
state: triaged
task: 14857
lane: code-u
outcome: design_recorded_implementation_split
Design: seitan admission path for
id serve(task 14857, lane code-u)Grounded in the current tree (origin/main 53cf63a):
seitan::Invite::admit(&mut self, proof, now_ms, window)inpkgs/id/src/seitan/admit.rs;ServerConfig::freshness()inpkgs/id/src/server_config/mod.rs; theStartedServerConfigload inpkgs/id/src/commands/serve.rswhose doc comment already names "the freshness window in seitan admission" as the remaining consumer; theserve_pull_policyaccessor pair (serve.rs:1155 + tests at :3733) as the established pattern for consuming config in serve; the axum web surface inpkgs/id/src/web/routes.rs(admin-secret-gatedPOST /api/world/invite,POST /api/identity/register); andDirectory::verify_account/DirectoryEntry::AccountVerifiedinpkgs/id/src/directory.rs, persisted in thedirectory.jsonlbeside the groups log that server-config provisioning already uses (server_config_directory_path, serve.rs:1075).Decisions
Where proofs arrive. Two new routes on the existing serve web surface (axum router in
web/routes.rs):POST /api/seitan/invite— registration, gated by the same admin-secret check that gatesPOST /api/world/invite(minting without the secret is refused, per the routes.rs:2031 test idiom). Body:{token, world, expires_ms}. The server buildsInvite::create(token, now_ms, expires_ms)and stores it; the response carries only the invite ID. The token is never stored (Invite::createkeeps only ID + public key + expiry, by construction) and never logged.POST /api/seitan/admit— unauthenticated; the signed proof is the credential. Body:{message, signature}(theseitan::Prooffields, base64 or hex per the router's existing body idioms).Where invites are registered/held. A registry in the serve process, next to
StartedServerConfig:Mutex<HashMap<InviteId, RegisteredInvite { world: String, invite: Invite }>>, owned by the same state the web router serves. v1 is in-memory only: a restart drops unredeemed invites, which then refuse as unknown (decision 4). That is acceptable for v1 because invites are short-lived (expiry + a minutes-scale freshness window) and re-registration is one admin call; persistence is a named follow-up if operations ever need it, not v1 scope.Which world an admitted invite joins. The world named at registration — exactly one, bound into the registry entry, never taken from the proof (the proof's fields carry no world, and letting the joiner choose would defeat the binding). The membership change an admission posts is directory-level, per
admit.rs's contract ("the caller then posts the membership change for it"): the admitteduidmust name an existing account in the server'sDirectory(created by provisioning or/api/identity/register), and admission appendsAccountVerifiedfor it viaDirectory::verify_accountinto the server-config directory journal. World-session membership is a separate existing mechanism (world_sessioninvites) and is out of scope here.Failure behavior (handler order matters — checks that do not consume run before
admit):malformed.unknown_invite. Nothing consumed.uidnaming no directory account → 403,unknown_account. Checked from the parsed fields before callingadmit, so the invite is not consumed and the joiner can retry once the account exists.Invite::admitrefuses → 403 with theRejectreason (revoked/expired/used/stale/from_future/bad_key/bad_signature). A refused accept uses nothing up (guaranteed byadmititself).AccountVerifiedfirst, then 200{uid, eldest_seqno, world}. If the directory append fails after a successfuladmit, respond 500 and log loudly: the invite stays consumed in memory (single-use safety wins over retry convenience, matching the seitan mod.rs threat notes).The freshness window. A
serve_freshness_window(started: Option<&StartedServerConfig>) -> Durationaccessor mirroringserve_pull_policy:started.config.freshness().window()when a config is loaded,seitan::DEFAULT_WINDOW(5 min) when none is — so no-config behavior is unchanged by construction, andFreshness::window()'s inviter/world/server precedence is preserved for the levelsServerConfig::freshness()sets. The admit handler passes this window to everyInvite::admitcall; there is no other window source.Implementation shape (follow-on task)
commands/serve.rs:serve_freshness_window+ registry state constructed besidestart_server_config_persisted, threaded into the web router state the same way the pull policy reaches its consumer (serve.rs:1312); unit tests mirroring serve.rs:3733/:3744 (no-config default, configured window).web/routes.rs: the two routes + handlers; the registry lives behind the router's shared state.AccountVerifiedlands in the directory; (b) a proof signed outside the configured window refusesstalethrough the live path; (c) no-config serve admits a fresh proof under the 5-minute default; (d) unknown invite → 404; (e) unknown account → 403 and the same proof succeeds after the account is registered (invite not consumed).Split
This task (task 14857) records the design (acceptance item 1 of the packet). The implementation is enqueued as a follow-on fix task carrying this design verbatim as its brief; it is effort/l-sized (router state plumbing in a 2,500+ line routes.rs, directory append ordering, five integration tests) and should not be rushed into the same claim as the design it depends on.
dezren39 commentedon Nov 11, 2026
state: done
task: 14857
lane: code-u
outcome: triaged_design_recorded
Task 14857 (design stage for issue #8487) is complete: the design is recorded in the comment above (6786323656). The implementation is queued as task 14862 ("Implement #8487: seitan admission path for id serve per the recorded design", same dedupe key, revived from task 14857) carrying the design as its brief, including the acceptance tail: check off the #798 brief line-76 item and close #5119 on merge.
18 remaining items
dezren39 commentedon Nov 11, 2026
agent-note:v1 — state: parked (CI wait) — lane any-b, task 14862.
Fresh revalidation 2026-11-11: PR #8529 OPEN at head 19f9912, no labels/hard-stops; both Codex findings carry disposition replies (4534012970 -> fixed, reply 4534118980; 4534012963 -> reply 4534119187 with follow-up issue #8538), even though the Codex summary flag still reads unresolved. Checks: 6 pending / 1 skipping, none failed. Parked on CI per the resume plan: merge on green, then the #798 line-76 checkoff, close #5119, and complete task 14862 as fixed_merged.
dezren39 commentedon Nov 11, 2026
🤖 Agent note · picked up
direct19f991214a(5 files, +656/−0), no hard-stop labels; issues id(serve): build the seitan admission path so ServerConfig::freshness() reaches a live admit check (split from #5119) #8487 and id(serve): no production caller for ServerConfig — load it in id serve and consume [policy] (pull gate, freshness) + provisioning #5119 both OPEN. Codex round on this head completed with two findings, both already dispositioned by the prior holder (lane tmp-code-b) but left unresolved in the thread UI: the P2 (duplicate-registration single-use reset) is fixed in19f991214awith the regression testseitan_duplicate_registration_does_not_reset_single_use_state; the P1 (admissions vs durable world directories) is dispositioned out-of-scope per the recorded design decision 3, with follow-up issue id(serve): seitan admission vs durable world directories — AccountVerified lands in the server-config journal, not the live world directory (Codex P1 follow-up to #8529) #8538 filed and OPEN. This claim marked both threads resolved so the recorded dispositions are now the thread state; no finding is undispositioned.19f991214a: seitan filter 42 passed / 0 failed;serve_freshness_window2 passed / 0 failed (--features web, laptop).Merge pull request #8529 from developing-today/queue/14862-8487-seita…
dezren39 commentedon Nov 11, 2026
🤖 Agent note · done
8f0c8aebf8d59aa02c70c5cceebb8ed7cca7d8a9— the seitan admission path per the recorded design (invite/admit routes, in-memory registry,serve_freshness_windowoverServerConfig::freshness(), DirectoryAccountVerifiedposted before the 200). Issue id(serve): build the seitan admission path so ServerConfig::freshness() reaches a live admit check (split from #5119) #8487 auto-closed on the merge;pkgs/id/src/web/seitan.rsverified present onmain.serve_freshness_window2 passed / 0 failed at head19f991214a(--features web, laptop), matching the prior holder's record. Codex round on that head: P2 (duplicate-registration single-use reset) fixed in the head with its regression test; P1 (admissions vs durable world directories) dispositioned out-of-scope per design decision 3 with follow-up issue id(serve): seitan admission vs durable world directories — AccountVerified lands in the server-config journal, not the live world directory (Codex P1 follow-up to #8529) #8538 OPEN — both threads carried replies from the prior holder and were left unresolved in the UI; this claim marked both resolved so thread state now matches the recorded dispositions. PR checks were queued in the runner stall with 0 failures — merged under the standing merge authority (CI runs on main).02a41a5a90, Codex completed clean); issue id(serve): no production caller for ServerConfig — load it in id serve and consume [policy] (pull gate, freshness) + provisioning #5119 closed on the PR feat(id): seitan admission path for id serve (#8487) #8529 merge and carries the evidence note from this task.