policy: the runner reads the control plane's own pair (THE-98) #58

Merged
pit merged 1 commit from hermes/the98-paperclip-credentials into main 2026-11-13 09:03:34 +00:00
Owner

What this is

The infra-secrets half of THE-98: infra-agents' paperclip/service writes 153's /opt/paperclip-ai/.env whole, and two of its thirteen values can only come from the store — the database password the role sets on the paperclip role, and BETTER_AUTH_SECRET, the secret the app's auth layer signs with. The runner's policy grows by two named paths, one per value, read-only.

Companion: olympus/infra-agents#4.

The two paths

path name on the host
secret/services/paperclip/db PAPERCLIP_DB_PASSWORD
secret/services/paperclip/auth PAPERCLIP_BETTER_AUTH_SECRET

Two path blocks, not a prefix: the pair rotates apart from each other, and secret/services/paperclip/* is not a subtree this policy should grant blind. The policy's comment carries the cost — a runner login can read the board's database password and the secret its auth layer signs with, so it can reach the database and mint a session. That is the machine the same policy already deploys, and the alternative is a role that cannot rebuild the board.

The pages

docs/store-layout.md's secret/services/… table gains both paths, marked declared here and not yet seeded. docs/store-identity.md's runner row names the pair in infra-agents' reach, and the grants table's count moves from thirty-eight to forty — read back against the policy itself, which now carries forty path blocks.

Evidence

check result
mise exec -- make check green — env-check, env-test, host-env-check, host-env-test, plan-test, rotation-test
bao policy fmt on a copy accepted, unchanged
grep -c '^path "' bao/policies/automation-runner.hcl 40, the number the identities table now states

Not run: applying the policy to the live store. bao policy write is the store's own act and this session holds no token; the store's service role applies bao/policies/ on its next run, or the Operator writes it by hand.

Merge Danger

Door: none — the policy only widens a read set by two paths.

Order matters. Both paths must hold a value before infra-agents#4's first credential guard passes, and seeding them is the Operator's: the database password is the one the role will set on the paperclip role (the deploy moves the role and the rendered DATABASE_URL together), and BETTER_AUTH_SECRET is the value already in 153's live .env. Until both are written, make env ACTOR=runner refuses by name and the deploy stops before it touches the machine.

Blast radius: the runner can now read the control plane's own pair. That is an increase in what a stolen runner credential reaches, stated in the policy's comment as the price of the grant.

## What this is The `infra-secrets` half of [THE-98](/THE/issues/THE-98): `infra-agents`' `paperclip/service` writes 153's `/opt/paperclip-ai/.env` whole, and two of its thirteen values can only come from the store — the database password the role sets on the `paperclip` role, and `BETTER_AUTH_SECRET`, the secret the app's auth layer signs with. The runner's policy grows by two named paths, one per value, read-only. Companion: `olympus/infra-agents#4`. ## The two paths | path | name on the host | | --- | --- | | `secret/services/paperclip/db` | `PAPERCLIP_DB_PASSWORD` | | `secret/services/paperclip/auth` | `PAPERCLIP_BETTER_AUTH_SECRET` | Two `path` blocks, not a prefix: the pair rotates apart from each other, and `secret/services/paperclip/*` is not a subtree this policy should grant blind. The policy's comment carries the cost — a runner login can read the board's database password and the secret its auth layer signs with, so it can reach the database and mint a session. That is the machine the same policy already deploys, and the alternative is a role that cannot rebuild the board. ## The pages `docs/store-layout.md`'s `secret/services/…` table gains both paths, marked declared here and not yet seeded. `docs/store-identity.md`'s `runner` row names the pair in infra-agents' reach, and the grants table's count moves from thirty-eight to forty — read back against the policy itself, which now carries forty `path` blocks. ## Evidence | check | result | | --- | --- | | `mise exec -- make check` | **green** — env-check, env-test, host-env-check, host-env-test, plan-test, rotation-test | | `bao policy fmt` on a copy | **accepted, unchanged** | | `grep -c '^path "' bao/policies/automation-runner.hcl` | **40**, the number the identities table now states | Not run: applying the policy to the live store. `bao policy write` is the store's own act and this session holds no token; the store's service role applies `bao/policies/` on its next run, or the Operator writes it by hand. ## Merge Danger **Door:** none — the policy only widens a read set by two paths. **Order matters.** Both paths must hold a value before `infra-agents#4`'s first credential guard passes, and seeding them is the Operator's: the database password is the one the role will set on the `paperclip` role (the deploy moves the role and the rendered `DATABASE_URL` together), and `BETTER_AUTH_SECRET` is the value already in 153's live `.env`. Until both are written, `make env ACTOR=runner` refuses by name and the deploy stops before it touches the machine. **Blast radius:** the runner can now read the control plane's own pair. That is an increase in what a stolen runner credential reaches, stated in the policy's comment as the price of the grant.
policy: the runner reads the control plane's own pair (THE-98)
All checks were successful
plan / guest-plan-check (pull_request_target) Successful in 18s
pr-checks / check (pull_request) Successful in 22s
312615af47
infra-agents' paperclip/service writes 153's /opt/paperclip-ai/.env whole.
Two of its thirteen values can only come from the store: the database
password the role sets, and BETTER_AUTH_SECRET. Two named read paths, one
each, read-only; no prefix, because secret/services/paperclip/* is not a
boundary this policy should grant blind.

The cost is stated where the grant is: a runner login can read the board's
database password and the secret its auth layer signs with.
Member

Review started (round 1/5) on 312615af47 — reading the diff now.

**Review started** (round 1/5) on 312615af479ddfadab3f4ed9fc2e5c551e52d8e5 — reading the diff now.
bot-minos approved these changes 2026-11-13 08:32:07 +00:00
bot-minos left a comment

olympus/infra-secrets#58 · policy: the runner reads the control plane's own pair (THE-98) · head 312615af · round 1/5 · reviewer bot-minos · verdict merge

Recommendation: merge

What this is, and the contract I judged it against

The spec is the PR body — which is also the infra-secrets half of paperclip:THE-98, read live this round — together with olympus/infra-agents#4's Merge Danger and What this change does not do sections, which state the split between the two repositories: #58 grants the runner read on secret/services/paperclip/db and …/auth; #4's env.map maps those two paths to PAPERCLIP_DB_PASSWORD and PAPERCLIP_BETTER_AUTH_SECRET. Three files carry it: the two path blocks and the header comment in bao/policies/automation-runner.hcl, the runner row and the grants count in docs/store-identity.md, and the two layout rows in docs/store-layout.md.

Standards — 1 advisory

A1 · ADVISORY · bao/policies/automation-runner.hcl:7-8 — the header comment's reach sentence has a punctuation slip and a stale pointer, both from this diff's own edit.

The edited line now reads its two Guests' state records; — from THE-97 —: a bare semicolon immediately before an em-dash, where the same list's third item reads ; and — from THE-98 —. The base read state records, and — from THE-97 —, so the change moved the comma and dropped the conjunction. One pass fixes both: , — from THE-97 — (or ; and — from THE-97 —).

The line beneath still says the ten THE-97 paths are named at the end of this file. The last of them ends at :283 and the file now closes with the THE-98 pair at :296-302, so the pointer sends a reader to the wrong block; named below would hold. Neither slip is functional — bao policy fmt parses the file and reproduces it byte-identically — so this is one finding: one editing pass, two slips.

No documented standard is broken. docs/store-layout.md:1-40 (ADR-0007's layout rules) holds: one credential per path, two paths each holding one value, read only, no prefix, no list. The policy's accepted-risks block and the new block's own paragraph carry the cost in the shape THE-97 used.

Spec — 1 advisory

Every requirement in the body is present: both named path blocks, read-only (bao/policies/automation-runner.hcl:296, :300); the two secret/services/… rows (docs/store-layout.md:252-253); the pair named in the runner's reach (docs/store-identity.md:121); the grants count moved (:387). Nothing in the diff is unasked for — no extra path, no prefix, no capability beyond read.

S1 · ADVISORY · docs/store-layout.md:252-253 — "not in the store yet" is asserted without the read-back its neighbours carry.

The page's own rule is that a path's writtenness is the ticket's claim, not the page's (:26-30), and where its rows do state a store fact they name the read that proves it: secret/hermes/api-server, …/providers/ollama, …/telegram/bot, …/webhook, …/dashboard and secret/paperclip/api/hermes all say (answers 404 on 2026-11-12) (:259-263, :274). These two rows state it bare, and this PR's evidence table records no store read (Not run: applying the policy to the live store). Drop the claim, or give it the same read-back as its neighbours — one clause per row.

Verified

claim how
40 path blocks, each capabilities = ["read"] grep -c '^path "' → 40 at head, 38 at base 566cebf; 40 capabilities = ["read"] lines
the identities row enumerates exactly those 40 paths parsed the runner row's by name: cell, expanded every {a,b} group, normalised to secret/…: 40 unique, set-equal to the policy — nothing in the row the policy lacks, nothing the other way
the grants count is real, not asserted docs/store-identity.md:387 at head vs 566cebf:docs/store-identity.md:387 ("thirty-eight")
bao policy fmt accepted, unchanged ran it on a scratch copy: rc 0, diff against the head file empty, sha256 75aad867…; worktree clean afterwards
mise exec -- make check green rc 0, 357 ok lines ending rotation tests: all passed; the six targets are the check prerequisites at Makefile:349 (env-check, env-test, host-env-check, host-env-test, plan-test, rotation-test)
CI at the reviewed head pr-checks / check (pull_request) success, run 140; plan / guest-plan-check (pull_request_target) success, run 139 — both at 312615af
grant and consumer name the same two paths olympus/infra-agents@688cefb env.map:75-76 — actors=pit,hermes,runner secret/services/paperclip/db PAPERCLIP_DB_PASSWORD and the auth / PAPERCLIP_BETTER_AUTH_SECRET row
no secret in the diff, body or comment read all three: path names, host variable names and prose only, no value

Could not verify

  • "Not in the store yet." This session holds no store token, so I did not read the two paths live. The claim rests on the author's and #4's statement — and it is the subject of S1.
  • Applying the policy. bao policy write is the store's service role's act; the author did not run it and neither did I, which the PR states plainly rather than implying otherwise.

Named, not charged

  • docs/store-identity.md's The grants table still dates the runner's grant 2026-11-05, grown 2026-11-09 and with SC-25. The diff does not touch that line, and THE-97 left it as it stood. Pre-existing.
  • Appendix A of docs/store-layout.md maps the WR-27 inventory, which does not carry these two values, so its row accounting is unchanged; the secret/services/… table states no total, so no arithmetic elsewhere moves.

Summary

Standards 1 advisory, Spec 1 advisory, 0 blockers. Worst per axis: A1 — prose in a policy header that ships with the file it documents; S1 — a store-state claim with no read-back. Two counted advisories do not reach the volume trip, so the recommendation is merge; both are advice, and both fix in one pass.

Class and the board's gate. This is a tier-1 change under the reviewer charter: the secrets store's access policy, widening what the runner reads on .153, up to the board's database password and its session-signing secret. The dispatch puts that hold outside this review and ties the state to the findings, so the state above is the findings'. The board's gate is paperclip:THE-102, created this round and read back (todo, assignee the Board's agent, no parent), which cites paperclip:THE-100 — the same class one ticket earlier on #57, still in_review with the board's decision card unanswered. Merging remains the board's call, and the policy's own comment states the price of the grant.

<!-- minos review-loop: repo=olympus/infra-secrets pr=58 head=312615af479ddfadab3f4ed9fc2e5c551e52d8e5 round=1/5 axes=standards,spec --> **olympus/infra-secrets#58** · `policy: the runner reads the control plane's own pair (THE-98)` · head `312615af` · round **1/5** · reviewer `bot-minos` · verdict **merge** Recommendation: merge ## What this is, and the contract I judged it against The spec is the PR body — which is also the `infra-secrets` half of `paperclip:THE-98`, read live this round — together with `olympus/infra-agents#4`'s **Merge Danger** and **What this change does not do** sections, which state the split between the two repositories: #58 grants the runner read on `secret/services/paperclip/db` and `…/auth`; #4's `env.map` maps those two paths to `PAPERCLIP_DB_PASSWORD` and `PAPERCLIP_BETTER_AUTH_SECRET`. Three files carry it: the two `path` blocks and the header comment in `bao/policies/automation-runner.hcl`, the runner row and the grants count in `docs/store-identity.md`, and the two layout rows in `docs/store-layout.md`. ## Standards — 1 advisory **A1 · ADVISORY · `bao/policies/automation-runner.hcl:7-8`** — the header comment's reach sentence has a punctuation slip and a stale pointer, both from this diff's own edit. The edited line now reads `its two Guests' state records; — from THE-97 —`: a bare semicolon immediately before an em-dash, where the same list's third item reads `; and — from THE-98 —`. The base read `state records, and — from THE-97 —`, so the change moved the comma and dropped the conjunction. One pass fixes both: `, — from THE-97 —` (or `; and — from THE-97 —`). The line beneath still says the ten THE-97 paths are `named at the end of this file`. The last of them ends at `:283` and the file now closes with the THE-98 pair at `:296-302`, so the pointer sends a reader to the wrong block; `named below` would hold. Neither slip is functional — `bao policy fmt` parses the file and reproduces it byte-identically — so this is one finding: one editing pass, two slips. No documented standard is broken. `docs/store-layout.md:1-40` (ADR-0007's layout rules) holds: one credential per path, two paths each holding one value, `read` only, no prefix, no `list`. The policy's accepted-risks block and the new block's own paragraph carry the cost in the shape THE-97 used. ## Spec — 1 advisory Every requirement in the body is present: both named `path` blocks, read-only (`bao/policies/automation-runner.hcl:296`, `:300`); the two `secret/services/…` rows (`docs/store-layout.md:252-253`); the pair named in the runner's reach (`docs/store-identity.md:121`); the grants count moved (`:387`). Nothing in the diff is unasked for — no extra path, no prefix, no capability beyond `read`. **S1 · ADVISORY · `docs/store-layout.md:252-253`** — "not in the store yet" is asserted without the read-back its neighbours carry. The page's own rule is that a path's writtenness is the ticket's claim, not the page's (`:26-30`), and where its rows do state a store fact they name the read that proves it: `secret/hermes/api-server`, `…/providers/ollama`, `…/telegram/bot`, `…/webhook`, `…/dashboard` and `secret/paperclip/api/hermes` all say `(answers 404 on 2026-11-12)` (`:259-263`, `:274`). These two rows state it bare, and this PR's evidence table records no store read (`Not run: applying the policy to the live store`). Drop the claim, or give it the same read-back as its neighbours — one clause per row. ## Verified | claim | how | | --- | --- | | 40 `path` blocks, each `capabilities = ["read"]` | `grep -c '^path "'` → 40 at head, 38 at base `566cebf`; 40 `capabilities = ["read"]` lines | | the identities row enumerates exactly those 40 paths | parsed the runner row's `by name:` cell, expanded every `{a,b}` group, normalised to `secret/…`: 40 unique, set-equal to the policy — nothing in the row the policy lacks, nothing the other way | | the grants count is real, not asserted | `docs/store-identity.md:387` at head vs `566cebf:docs/store-identity.md:387` ("thirty-eight") | | `bao policy fmt` accepted, unchanged | ran it on a scratch copy: rc 0, `diff` against the head file empty, sha256 `75aad867…`; worktree clean afterwards | | `mise exec -- make check` green | rc 0, 357 `ok` lines ending `rotation tests: all passed`; the six targets are the `check` prerequisites at `Makefile:349` (env-check, env-test, host-env-check, host-env-test, plan-test, rotation-test) | | CI at the reviewed head | `pr-checks / check (pull_request)` success, run 140; `plan / guest-plan-check (pull_request_target)` success, run 139 — both at `312615af` | | grant and consumer name the same two paths | `olympus/infra-agents@688cefb` `env.map:75-76` — `actors=pit,hermes,runner secret/services/paperclip/db PAPERCLIP_DB_PASSWORD` and the `auth` / `PAPERCLIP_BETTER_AUTH_SECRET` row | | no secret in the diff, body or comment | read all three: path names, host variable names and prose only, no value | ## Could not verify - **"Not in the store yet."** This session holds no store token, so I did not read the two paths live. The claim rests on the author's and #4's statement — and it is the subject of S1. - **Applying the policy.** `bao policy write` is the store's service role's act; the author did not run it and neither did I, which the PR states plainly rather than implying otherwise. ## Named, not charged - `docs/store-identity.md`'s **The grants** table still dates the runner's grant `2026-11-05, grown 2026-11-09 and with SC-25`. The diff does not touch that line, and THE-97 left it as it stood. Pre-existing. - Appendix A of `docs/store-layout.md` maps the WR-27 inventory, which does not carry these two values, so its row accounting is unchanged; the `secret/services/…` table states no total, so no arithmetic elsewhere moves. ## Summary Standards **1 advisory**, Spec **1 advisory**, **0 blockers**. Worst per axis: A1 — prose in a policy header that ships with the file it documents; S1 — a store-state claim with no read-back. Two counted advisories do not reach the volume trip, so the recommendation is **merge**; both are advice, and both fix in one pass. **Class and the board's gate.** This is a tier-1 change under the reviewer charter: the secrets store's access policy, widening what the runner reads on .153, up to the board's database password and its session-signing secret. The dispatch puts that hold outside this review and ties the state to the findings, so the state above is the findings'. The board's gate is `paperclip:THE-102`, created this round and read back (`todo`, assignee the Board's agent, no parent), which cites `paperclip:THE-100` — the same class one ticket earlier on #57, still `in_review` with the board's decision card unanswered. Merging remains the board's call, and the policy's own comment states the price of the grant.
pit merged commit 71c5f89a02 into main 2026-11-13 09:03:34 +00:00
pit deleted branch hermes/the98-paperclip-credentials 2026-11-13 09:03:34 +00:00
Sign in to join this conversation.
No reviewers
No milestone
No project
No assignees
2 participants
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
olympus/infra-secrets!58
No description provided.