[team] Review fixes: deployment ticket on target.request, unknown author under others, refuse after sign (v0.18.1) #24

Manually merged
mnovak merged 1 commits from fix/team-review into main 2026-11-17 12:45:35 +01:00
Owner

Fixes from an independent review of v0.18.0 (Custos docs/27_team_vault.md, "Review"). v0.18.1.

What

  • Target credentials are bound to the requesting Fabrica.
    • Before: anyone who knew a deployment's hash (the service stores every request text; proofs name it) could ask for its credentials.
    • Now: team_sign makes a 32-byte ticket per signed request and keeps it 25 hours. The ticket goes only into the sealed sign.reply (ticket).
    • A target.request now ends with "mac": HMAC-SHA256(ticket, domain ‖ the request without mac). team_target_release refuses a request without the right MAC.
  • others no longer fails open. With 2+ members, an empty author, or one no member is, is Unsatisfiable, and may_approve says why.
  • team_refuse is Replayed once the request was signed, so a refusal can never contradict a signature.
  • TEAM.md:
    • the ticket and the MAC;
    • the unknown-author rule;
    • a "Limits" section: every member holds the team's secrets in their Custos, and any member can change the policy.

Tests

  • cargo test --workspace --release: 275 passed, 0 failed.
  • New assertions:
    • a target request with the wrong ticket is refused;
    • a refusal after a signature is refused;
    • an unknown or empty author is unsatisfiable and blocks may_approve;
    • the policy oracle was updated for every combination.

Self-review

  • HMAC comes from RustCrypto hmac (already a workspace dependency); verification is constant time (verify_slice).
  • The ticket is a secret: SecretString in the body, only in the sealed reply, never in a view.
  • A target.request without mac no longer parses. Nothing used it outside this team's own repositories: Fabrica (T2) is told to use v0.18.1.
Fixes from an independent review of v0.18.0 (Custos docs/27_team_vault.md, "Review"). v0.18.1. ## What - **Target credentials are bound to the requesting Fabrica.** - Before: anyone who knew a deployment's hash (the service stores every request text; proofs name it) could ask for its credentials. - Now: `team_sign` makes a 32-byte **ticket** per signed request and keeps it 25 hours. The ticket goes only into the sealed `sign.reply` (`ticket`). - A `target.request` now ends with `"mac"`: HMAC-SHA256(ticket, domain ‖ the request without `mac`). `team_target_release` refuses a request without the right MAC. - **`others` no longer fails open.** With 2+ members, an empty author, or one no member is, is `Unsatisfiable`, and `may_approve` says why. - **`team_refuse` is `Replayed`** once the request was signed, so a refusal can never contradict a signature. - TEAM.md: - the ticket and the MAC; - the unknown-author rule; - a "Limits" section: every member holds the team's secrets in their Custos, and any member can change the policy. ## Tests - `cargo test --workspace --release`: 275 passed, 0 failed. - New assertions: - a target request with the wrong ticket is refused; - a refusal after a signature is refused; - an unknown or empty author is unsatisfiable and blocks `may_approve`; - the policy oracle was updated for every combination. ## Self-review - HMAC comes from RustCrypto `hmac` (already a workspace dependency); verification is constant time (`verify_slice`). - The ticket is a secret: `SecretString` in the body, only in the sealed reply, never in a view. - A `target.request` without `mac` no longer parses. Nothing used it outside this team's own repositories: Fabrica (T2) is told to use v0.18.1.
mnovak added 1 commit 2026-11-17 12:45:13 +01:00
mnovak manually merged commit 47146a6ea2 into main 2026-11-17 12:45:35 +01:00
Sign in to join this conversation.
No Reviewers
No Label
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: mnovak/CustosPublic#24