fix(GATE-005): harden helper trusted-input — argv separator + UUID v4 request_id
- apt build_plan: add POSIX '--' before user-derived name=version tokens - dnf build_plan: add POSIX '--' before user-derived name-version token - validate_mint_request: enforce canonical UUID v4 on request_id at intake - RAF components/04: document '--' separator in pipeline step 7 - RAF security/05: document hardened argv contract + UUID v4 validation - RAF flows/03: add stale banner (5 deviations from current code) 14 tests pass. Deferred: artifact_path staging root, name/version charset regex (both need design decisions — see task file).
This commit is contained in:
parent
4e08deef8c
commit
35732a63fd
5 changed files with 94 additions and 17 deletions
|
|
@ -28,7 +28,7 @@ The agent invokes it via `sudo systemd-run --pipe --property=ProtectSystem=no`
|
|||
4. **Signature** — `verify_signature()` checks the token's Ed25519 signature over the signed message (which embeds the closure hash) against the keyring, by `key_id`.
|
||||
5. **Artifact hashes** — `verify_artifacts()` SHA-256s every artifact the token authorizes. A mismatch anywhere is a denial.
|
||||
6. **Replay check** — `replay_check_and_record()`: token IDs are recorded in local state; a token executes once.
|
||||
7. **Plan + execute** — `build_plan()` translates the token into the exact package-manager commands; `execute_plan()` runs them. No interpretation, no substitution.
|
||||
7. **Plan + execute** — `build_plan()` translates the token into the exact package-manager commands; `execute_plan()` runs them. No interpretation, no substitution. A POSIX `--` (end-of-options) separator precedes all user-derived values (package names, versions) to prevent option injection (GATE-005).
|
||||
8. **Receipt** — `emit_result()` writes a `PolicyResult` the agent reports back; the server reconciles it into lifecycle state.
|
||||
|
||||
---
|
||||
|
|
|
|||
Loading…
Reference in a new issue