access-engine/workplans/FLEX-WP-0040-bounded-execution-pdp-gate.md
tegwick f5b7a9071e
All checks were successful
CI Smoke / host-smoke (push) Successful in 0s
CI Smoke / container-smoke (push) Successful in 1s
NK-WP-0056-T02 owner answer: PDP gate for bounded execution; FLEX-WP-0040 proposed
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

Assistant: claude-code
Assistant-Model: opus
Assistant-Process: 994874@bnt-lap001
Assistant-Session: 6017c416-d619-47eb-bd1a-f670a02d7d87
2026-10-31 14:19:08 +01:00

113 lines
3.8 KiB
Markdown

---
id: FLEX-WP-0040
type: workplan
title: "Bounded execution PDP gate: decide executor steps under an approved admission"
domain: infotech
repo: access-engine
status: proposed
flavor: implementation
owner: access-engine
created: "2026-10-31"
updated: "2026-10-31"
related: [NK-WP-0056, FLEX-WP-0039, FLEX-WP-0031]
---
# FLEX-WP-0040 — Bounded execution PDP gate
NetKingdom's proposed Bounded Execution Admission v0.1 (NK-WP-0056) lets the
founder approve, at `aal2`, an exact digested admission that a bounded executor
consumes once. Owner answer: `docs/bounded-execution-admission-pdp.md`. PDP
gating is in scope and recommended for production; the T06 pilot may run on
local enforcement without it.
Today the typed task path (`docs/trusted-service-task-source.md`) serves only
the secrets-engine v2 contract, requires an unconsumed claim, and the Approval
claim carries no approver assurance. Everything below lands as `proposed`
source, evaluated in tests only. No deployment, caller trust or credential is
admitted by this workplan.
## 1. Settle the claim inputs with approval-engine
```task
id: FLEX-WP-0040-T01
status: wait
priority: high
```
Wait: approval-engine answers to NK-WP-0056-T02 (binding to
`{admission_id, admission_digest}`, approver assurance `aal2`, consume scope)
plus our two additions: `consumed_by` and `consumed_at` in the claim. Record
the agreed claim fields here. Gate: written claim field list with owner ack.
## 2. Pack owner and semantic review
```task
id: FLEX-WP-0040-T02
status: wait
priority: medium
```
Wait: founder confirms the proposal — access-engine owns pack mechanics and
fixtures; NetKingdom (BEA owner) owns what a ceiling admits; gate-house reviews
authority-ceiling semantics. Gate: decision recorded.
## 3. Generalise the typed path caller map
```task
id: FLEX-WP-0040-T03
status: todo
priority: medium
```
Replace the single hard-wired secrets-engine mapping with an owner-installed
caller map; first new entry `system:serviceaccount:sso:nk-bind-executor` →
`service:nk-bind-executor`. Gate: existing secrets-engine v2 tests unchanged
and passing; unknown service accounts refuse; generic `/v1/check` still refuses
task execution.
## 4. Vocabulary and admission digest
```task
id: FLEX-WP-0040-T04
status: todo
priority: medium
depends_on: [FLEX-WP-0040-T01]
```
Add actions `start` and `execute-step` on resource type
`bounded-execution-admission` (system `net-kingdom`). The executor submits the
admission document; access-engine recomputes its digest by NK's BEA digest rule
and requires equality with the claim's admission digest. Gate: digest fixtures
shared with NetKingdom's validator agree byte-for-byte.
## 5. Policy pack `net-kingdom.bounded-execution` (DENY by default)
```task
id: FLEX-WP-0040-T05
status: todo
priority: medium
depends_on: [FLEX-WP-0040-T02, FLEX-WP-0040-T03, FLEX-WP-0040-T04]
```
`start`: claim valid and unconsumed, approver HUMAN at `aal2` and not the
executor, executor equals admission executor, now inside `window`.
`execute-step`: claim consumed once by this executor inside the window; step
id/operation/target/mode/scope match the digested `plan.steps` and lie inside
`scope_ceiling`; `max_concurrent` respected. Fixtures from
`net-kingdom/examples/bounded-execution-admission/bind-rotation-svc-authelia.yaml`
including out-of-ceiling, wrong executor, expired window, replayed consume and
missing assurance. Gate: pack validates, all fixtures pass, the existing
`apply` gap test stays as characterisation.
## 6. Live gate readiness
```task
id: FLEX-WP-0040-T06
status: wait
priority: low
depends_on: [FLEX-WP-0040-T05, FLEX-WP-0039-T01]
```
Wait: FLEX-WP-0039 readiness surface and a founder rollout decision for a pin
serving the pack, with the executor's declared fail-closed stance. Gate:
founder-approved rollout; no live change from this repo's agents.