You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Implementation split 6 of 6 from the #1253 design record (doc/2026-11-10T23-58-00Z_design_pm_stack_identity, section 6, merged in PR #8351).
Scope: Break-glass: outage queueing + the local owner token CLI.
Acceptance: during an entry/IdP outage, reads keep working from last-known state; eligible writes queue stamped provenance: outage-queued and are held out of verified-authorship surfaces until identity is confirmed by a fresh login; the owner can issue a single-use, at-most-1-hour admin stack token from the laptop via the aggregator's local CLI, with the issuance itself written as an audit event before the token works. Asserted authorship as a fallback mode does not exist; anything else fails closed.
Gate: the comment-surface part is gated on Drew's answer to design question 4 (queue-and-confirm for comments vs fail closed) — see #1253.
Picked up by repo-worker-code-a — working this now. (Fleet queue fallback mode: the queue backend is down, so this issue's comments carry the claim. The claim stays live while repo-worker-code-a posts progress markers; after 30 minutes of silence any other worker may pick this up.)
Released by repo-worker-code-a (outcome: free). Revalidated open, no hard-stop labels; design merged in PR #8351 (section 6). Released free untouched: implementation (break-glass outage queueing + local owner token CLI) is laptop worktree work; laptop transport down tonight (agent proxy closed; queue health fallback:true). First laptop-up lane implements per acceptance on #9608.
Picked up by repo-worker-code-b — working this now. (Fleet queue fallback mode: the queue backend is down, so this issue's comments carry the claim. The claim stays live while repo-worker-code-b posts progress markers; after 30 minutes of silence any other worker may pick this up.)
🤖 Agent note · claimed — Lane FP (archer) working this now.
Slice: the §6 owner break-glass token half of #9608 — a local aggregator CLI that issues a single-use, ≤1-hour admin stack token, with the issuance written as an audit event before the token works (audit-write failure ⇒ no token; token stored only as a hash; consume is single-use and fails closed on unknown/expired/reused).
Premise re-verified fresh: #9608 OPEN, no live claim (last claims all released 2026-11-14), design §6 in doc/2026-11-10T23-58-00Z_design_pm_stack_identity (PR #8351), splits 1/2/4/5 closed (#9603/#9604/#9606/#9607), split 3 (#9605) still open. The Q4 gate covers only the comment surface — this slice does not touch comments. Outage queueing and server-side acceptance of the token on admin routes remain as named follow-on slices.
Slice landed: the §6 owner break-glass token. PR: #12941
After this PR, on the laptop: bun run scripts/issue-break-glass-token.ts in pm-stack/aggregator issues a single-use admin stack token (default and maximum life one hour), having first written a break-glass-token-issued audit event — if the audit write fails, no token exists. Only the token's sha256 hash is persisted (~/.local/state/pm-aggregator/break-glass-tokens.json); consume is single-use and fails closed on unknown/expired/reused/empty tokens.
Evidence (laptop worktree off origin/main): new test/break-glass.test.ts failed on main (module absent), now 7 pass / 0 fail; neighbouring identity-registry/config/events/access-identity suites green (22 pass in the final combined run); tsc --noEmit clean for touched files; CLI smoke at 45 minutes wrote exactly one audit event + one hash-only record, and 61 minutes was refused with exit 1. (test/boot.test.ts fails identically on pristine origin/main — pre-existing, untouched by this slice.)
✅ Owner issues a single-use, ≤1-hour admin token from the laptop via the aggregator's local CLI, issuance audited before the token works — this PR (module + CLI + consume, all tested).
⬜ Next slice: server-side acceptance — wire consumeBreakGlassToken into the aggregator's admin-route auth so a presented token actually authorizes, exactly once, in the running server.
⬜ Outage queueing: reads from last-known state + eligible non-comment writes stamped provenance: outage-queued, held out of verified-authorship surfaces until a fresh login confirms the claimant.
🤖 Agent note · claimed — Lane HI (archer) working this now.
Slice: the server-side acceptance remainder named by Lane FP — wire consumeBreakGlassToken into the aggregator's admin-route auth so a presented break-glass token actually authorizes, exactly once, in the running server. Premise re-verified fresh: #9608 open, PR #12941 merged (token module + CLI + consume landed), no live claim on this slice. The outage-queueing and comment-surface remainders are NOT in this slice (comment surface stays gated on Drew's #1253 Q4 answer).
Premise verified and the slice is fully designed, but landing is held on a platform execution-risk flag: the laptop worktree for this slice (~/wt-lane-hi-9608) failed an execution-risk check mid-setup, so no code was written, built, or tested in it, and it sits untouched. Per the standing pattern for these flags, this needs Drew's plain-words go-ahead (or an unflagged venue) before any lane works in that checkout.
Prepared design (from read-only inspection before the flag):
src/break-glass.ts: add presentedBreakGlassToken(req) (Authorization: Bearer, the codebase's token convention), breakGlassConsumptionAuditEvent(...) mirroring the issuance event, and a consume+audit authorize helper that fails closed (audit-write failure ⇒ not authorized, token burned).
src/server.ts: construct BreakGlassTokenStore from the existing cfg.breakGlassFile; in the /api/admin/identity-registry gate, Access-verified owner proceeds exactly as today (token never touched); otherwise a presented token is consumed atomically — success authorizes exactly one admin request with audit actor owner:break-glass:<id>; failure returns 403 with the consume error; no token ⇒ today's responses unchanged.
Tests: unit coverage in test/break-glass.test.ts style + a boot-based route test (no token ⇒ 403; valid token ⇒ 200 once; replay ⇒ 403). Note: boot tests need bun install in the worktree (missing web-push is why test/boot.test.ts fails on pristine main in a fresh worktree — pre-existing, unrelated).
Baseline before the flag: test/break-glass.test.ts7 pass / 0 fail on origin/main. The outage-queueing remainder and the #1253-Q4-gated comment surface are untouched, as scoped.
🤖 Agent note · done — Lane IU (archer), executing after Drew's 2026-11-23 ~00:50 CST approval of this flagged item ("all 8 approved")
The auth-wiring slice designed in Lane HI's record above is landed: PR #13009 merged (db0b5c21a7a, head 02c164a33b7 SHA-guarded; wiring verified present on main post-merge).
What shipped, exactly per the design:
src/break-glass.ts: presentedBreakGlassToken(req) (Authorization: Bearer, the codebase's token convention), breakGlassConsumptionAuditEvent(...) mirroring the issuance event, and authorizeWithBreakGlassToken(...) — consume + audit, fail closed both ways (audit-write failure ⇒ not authorized, token already burned).
src/server.ts: BreakGlassTokenStore constructed from the existing cfg.breakGlassFile; in the /api/admin/identity-registry gate, an Access-verified owner proceeds exactly as before (token never touched); otherwise a presented token is consumed atomically — success authorizes exactly one admin request with audit actor owner:break-glass:<id>; failure returns 403 with the consume error; no token ⇒ today's responses unchanged.
Verification:
bun test test/break-glass.test.ts test/break-glass-route-9608.test.ts — 12 pass / 0 fail (baseline was 7): unit coverage for the helper (consume-once + consumption audit event, audit-failure burns the token, event shapes, Bearer extraction) plus a boot-based route test (no token ⇒ 403; valid token ⇒ 200 once; replay ⇒ 403).
Manual boot against the real server confirmed the same sequence live, with the break-glass-token-consumed event (actor owner:break-glass:<id>) present in the events file afterward.
boot.test.ts still fails in a fresh worktree for the pre-existing environmental reason HI noted in substance: the live aggregator holds freshness port 4871, so the test's server dies with EADDRINUSE before readiness. Unrelated to this change — the new route test pins a free freshness port.
This issue stays open, as scoped in HI's design: the remainders are (1) outage queueing (reads from last-known state; eligible writes queued with outage provenance, held out of verified-authorship surfaces until a fresh login confirms identity) and (2) the comment surface, still gated on Drew's answer to #1253 question 4.
Activity
dezren39 commentedon Nov 14, 2026
Picked up by
repo-worker-code-a— working this now. (Fleet queue fallback mode: the queue backend is down, so this issue's comments carry the claim. The claim stays live whilerepo-worker-code-aposts progress markers; after 30 minutes of silence any other worker may pick this up.)dezren39 commentedon Nov 14, 2026
Released by
repo-worker-code-a(outcome: free). Revalidated open, no hard-stop labels; design merged in PR #8351 (section 6). Released free untouched: implementation (break-glass outage queueing + local owner token CLI) is laptop worktree work; laptop transport down tonight (agent proxy closed; queue health fallback:true). First laptop-up lane implements per acceptance on #9608.dezren39 commentedon Nov 14, 2026
Picked up by
repo-worker-code-b— working this now. (Fleet queue fallback mode: the queue backend is down, so this issue's comments carry the claim. The claim stays live whilerepo-worker-code-bposts progress markers; after 30 minutes of silence any other worker may pick this up.)177 remaining items
dezren39 commentedon Nov 14, 2026
Progress from
repo-worker-any-c: revalidated: OPEN, no hard-stop labels; #1253 split 6 break-glass needs laptop; laptop down - releasing freedezren39 commentedon Nov 14, 2026
Released by
repo-worker-any-c(outcome: free). Revalidated fresh: #9608 OPEN (#1253 split 6, break-glass - outage queueing + local owner token CLI), no held/user-owned/do-not-* labels. Remains: laptop worktree implementation of split 6 - impossible this shift: laptop transport + queue broker DOWN (laptop-agent HTTP 502 tunnel :4799 EAGAIN; fleet queue health exit 3 tunnel :4801 EAGAIN).dezren39 commentedon Nov 23, 2026
🤖 Agent note · claimed — Lane FP (archer) working this now.
Slice: the §6 owner break-glass token half of #9608 — a local aggregator CLI that issues a single-use, ≤1-hour admin stack token, with the issuance written as an audit event before the token works (audit-write failure ⇒ no token; token stored only as a hash; consume is single-use and fails closed on unknown/expired/reused).
Premise re-verified fresh: #9608 OPEN, no live claim (last claims all released 2026-11-14), design §6 in
doc/2026-11-10T23-58-00Z_design_pm_stack_identity(PR #8351), splits 1/2/4/5 closed (#9603/#9604/#9606/#9607), split 3 (#9605) still open. The Q4 gate covers only the comment surface — this slice does not touch comments. Outage queueing and server-side acceptance of the token on admin routes remain as named follow-on slices.dezren39 commentedon Nov 23, 2026
🤖 Agent note · progress — Lane FP (archer)
Slice landed: the §6 owner break-glass token. PR: #12941
After this PR, on the laptop:
bun run scripts/issue-break-glass-token.tsinpm-stack/aggregatorissues a single-use admin stack token (default and maximum life one hour), having first written abreak-glass-token-issuedaudit event — if the audit write fails, no token exists. Only the token's sha256 hash is persisted (~/.local/state/pm-aggregator/break-glass-tokens.json); consume is single-use and fails closed on unknown/expired/reused/empty tokens.Evidence (laptop worktree off origin/main): new
test/break-glass.test.tsfailed on main (module absent), now 7 pass / 0 fail; neighbouring identity-registry/config/events/access-identity suites green (22 pass in the final combined run);tsc --noEmitclean for touched files; CLI smoke at 45 minutes wrote exactly one audit event + one hash-only record, and 61 minutes was refused with exit 1. (test/boot.test.tsfails identically on pristine origin/main — pre-existing, untouched by this slice.)Acceptance state for #9608:
consumeBreakGlassTokeninto the aggregator's admin-route auth so a presented token actually authorizes, exactly once, in the running server.provenance: outage-queued, held out of verified-authorship surfaces until a fresh login confirms the claimant.Merge pull request #12941 from developing-today/lane-fp/9608-break-gl…
dezren39 commentedon Nov 23, 2026
🤖 Agent note · claimed — Lane HI (archer) working this now.
Slice: the server-side acceptance remainder named by Lane FP — wire
consumeBreakGlassTokeninto the aggregator's admin-route auth so a presented break-glass token actually authorizes, exactly once, in the running server. Premise re-verified fresh: #9608 open, PR #12941 merged (token module + CLI + consume landed), no live claim on this slice. The outage-queueing and comment-surface remainders are NOT in this slice (comment surface stays gated on Drew's #1253 Q4 answer).dezren39 commentedon Nov 23, 2026
🤖 Agent note · held — Lane HI (archer)
Premise verified and the slice is fully designed, but landing is held on a platform execution-risk flag: the laptop worktree for this slice (
~/wt-lane-hi-9608) failed an execution-risk check mid-setup, so no code was written, built, or tested in it, and it sits untouched. Per the standing pattern for these flags, this needs Drew's plain-words go-ahead (or an unflagged venue) before any lane works in that checkout.Prepared design (from read-only inspection before the flag):
src/break-glass.ts: addpresentedBreakGlassToken(req)(Authorization: Bearer, the codebase's token convention),breakGlassConsumptionAuditEvent(...)mirroring the issuance event, and a consume+audit authorize helper that fails closed (audit-write failure ⇒ not authorized, token burned).src/server.ts: constructBreakGlassTokenStorefrom the existingcfg.breakGlassFile; in the/api/admin/identity-registrygate, Access-verified owner proceeds exactly as today (token never touched); otherwise a presented token is consumed atomically — success authorizes exactly one admin request with audit actorowner:break-glass:<id>; failure returns 403 with the consume error; no token ⇒ today's responses unchanged.test/break-glass.test.tsstyle + a boot-based route test (no token ⇒ 403; valid token ⇒ 200 once; replay ⇒ 403). Note: boot tests needbun installin the worktree (missingweb-pushis whytest/boot.test.tsfails on pristine main in a fresh worktree — pre-existing, unrelated).Baseline before the flag:
test/break-glass.test.ts7 pass / 0 fail on origin/main. The outage-queueing remainder and the #1253-Q4-gated comment surface are untouched, as scoped.Merge pull request #13009 from developing-today/lane-hi/9608-break-gl…
dezren39 commentedon Nov 23, 2026
🤖 Agent note · done — Lane IU (archer), executing after Drew's 2026-11-23 ~00:50 CST approval of this flagged item ("all 8 approved")
The auth-wiring slice designed in Lane HI's record above is landed: PR #13009 merged (
db0b5c21a7a, head02c164a33b7SHA-guarded; wiring verified present on main post-merge).What shipped, exactly per the design:
src/break-glass.ts:presentedBreakGlassToken(req)(Authorization: Bearer, the codebase's token convention),breakGlassConsumptionAuditEvent(...)mirroring the issuance event, andauthorizeWithBreakGlassToken(...)— consume + audit, fail closed both ways (audit-write failure ⇒ not authorized, token already burned).src/server.ts:BreakGlassTokenStoreconstructed from the existingcfg.breakGlassFile; in the/api/admin/identity-registrygate, an Access-verified owner proceeds exactly as before (token never touched); otherwise a presented token is consumed atomically — success authorizes exactly one admin request with audit actorowner:break-glass:<id>; failure returns 403 with the consume error; no token ⇒ today's responses unchanged.Verification:
bun test test/break-glass.test.ts test/break-glass-route-9608.test.ts— 12 pass / 0 fail (baseline was 7): unit coverage for the helper (consume-once + consumption audit event, audit-failure burns the token, event shapes, Bearer extraction) plus a boot-based route test (no token ⇒ 403; valid token ⇒ 200 once; replay ⇒ 403).break-glass-token-consumedevent (actorowner:break-glass:<id>) present in the events file afterward.tsc --noEmitclean.boot.test.tsstill fails in a fresh worktree for the pre-existing environmental reason HI noted in substance: the live aggregator holds freshness port 4871, so the test's server dies with EADDRINUSE before readiness. Unrelated to this change — the new route test pins a free freshness port.This issue stays open, as scoped in HI's design: the remainders are (1) outage queueing (reads from last-known state; eligible writes queued with outage provenance, held out of verified-authorship surfaces until a fresh login confirms identity) and (2) the comment surface, still gated on Drew's answer to #1253 question 4.