2026-06-28 12:28:45 +02:00
# ops-warden → secrets-engine Routing Contract
2026-06-30 00:52:05 +02:00
ops-warden issues **SSH certificates only** . Every other credential or scoped
capability need (API keys, provider tokens, DB passwords, npm publish tokens,
and OpenBao capability lanes) routes to **secrets-engine** . secrets-engine
returns non-secret pointers and safe next commands while OpenBao remains the
custody, policy, lease, and audit backend. ops-warden must never request, hold,
cache, or vend a raw secret value. A route result is a **pointer** , not a key.
2026-06-28 12:28:45 +02:00
## What ops-warden calls
```bash
secrets-engine route < catalog-id > --json
```
## What it returns (the contract)
```json
{
"catalog_id": "whynot-design-npm-publish",
2026-06-29 16:58:16 +02:00
"kind": "kv",
2026-06-28 12:44:55 +02:00
"owner": "coulomb/whynot-design",
2026-06-28 12:28:45 +02:00
"stage": "prod",
"decision_status": "resolved",
2026-06-29 16:58:16 +02:00
"decision_ref": "e6381a56-6b04-4fd5-b2de-f3ef59cde888",
2026-06-28 12:28:45 +02:00
"review_url": "http://127.0.0.1:8000/decisions/< id > ",
"metadata_applied": true,
"value_present": true,
"ready": true,
"next_command": "secrets-engine exec --catalog whynot-design-npm-publish -- < command... > ",
"missing": ""
}
```
| Field | Meaning |
| --- | --- |
| `decision_status` | `resolved` /`approved` => approved; `missing` /`pending` => not yet |
2026-06-29 16:58:16 +02:00
| `kind` | `kv` for stored-value lanes, `auth-capability` for policy/AppRole capability lanes |
2026-06-28 12:28:45 +02:00
| `metadata_applied` | OpenBao ACL policy + approle exist for the lane |
2026-06-29 16:58:16 +02:00
| `value_present` | for `kv` , the secret value has been provisioned (boolean only — value never read); for `auth-capability` , there is no KV value and this is true once metadata is handoff-ready |
| `ready` | approved **and** applied **and** provisioned or handoff-ready |
2026-06-28 12:28:45 +02:00
| `next_command` | the single safe command the caller should run next |
| `missing` | the one human/provisioning step still outstanding |
## Guarantees
- **No value crosses this boundary.** `route` reports a boolean `value_present` ,
2026-06-29 16:58:16 +02:00
derived from a metadata/presence check for KV lanes or from policy/AppRole
readiness for auth-capability lanes — it never reads or mints a secret.
2026-06-28 12:28:45 +02:00
- **Actionable when not ready.** If a lane is unapproved, unapplied, or
unprovisioned, `next_command` + `missing` tell the caller exactly what to do.
- **Idempotent / read-only.** `route` performs no mutation.
2026-06-30 00:52:05 +02:00
- **Custody stays in OpenBao.** secrets-engine orchestrates approved issuance,
delivery, handoff, verification, and revocation paths; it does not make
ops-warden a secret store or token broker.
2026-06-28 12:28:45 +02:00
## whynot-design retry flow
1. whynot-design CI needs a publish token → asks ops-warden.
2. ops-warden runs `secrets-engine route whynot-design-npm-publish --json` .
3. If `ready=false` , it surfaces `missing` + `next_command` to the human (e.g.
"needs approved decision" or "needs provisioning").
4. Once `ready=true` , the workload runs
`secrets-engine exec --catalog whynot-design-npm-publish -- npm publish` .
2026-06-29 16:58:16 +02:00
Safe whynot-design pointer payload for ops-warden:
```json
{
"catalog_id": "whynot-design-npm-publish",
"kind": "kv",
"decision_ref": "e6381a56-6b04-4fd5-b2de-f3ef59cde888",
"owner": "coulomb/whynot-design",
"stage": "prod",
"next_command": "secrets-engine exec --catalog whynot-design-npm-publish -- npm publish"
}
```
## warden-sign auth-capability flow
1. ops-warden needs a scoped `VAULT_TOKEN` for the FLEX-WP-0007 T4 smoke.
2. ops-warden runs `secrets-engine route warden-sign --json` .
3. If `ready=false` , it surfaces `missing` + `next_command` to the human.
4. Once `ready=true` , `next_command` points to `secrets-engine handoff ...` ; the
operator receives `role_id` and `secret_id` out-of-band and performs AppRole
login on CoulombCore.
5. State Hub receives only non-secret pointers: addr, mount, policy, AppRole,
TTLs, allowed paths, and status. It must not receive `role_id` , `secret_id` ,
`VAULT_TOKEN` , token accessor, or raw smoke output containing token material.
See [warden-sign-auth-capability.md ](warden-sign-auth-capability.md ).
2026-06-28 12:28:45 +02:00
## Anti-patterns (forbidden)
2026-06-29 16:58:16 +02:00
- ops-warden `POST /messages/` asking for `NPM_TOKEN` / `OPENROUTER_API_KEY` /
`VAULT_TOKEN` .
2026-06-28 12:28:45 +02:00
- Caching `value_present` as if it were the value.
- Inventing `warden secret` / `warden bao` — they do not exist.