bxnet-ops/org-ops-core
Tyler J King 62b00ad84c feat(org-ops): worker pre-flight with delegation enforcement
Add worker_preflight() check at dispatch time for commands that
target remote hosts. Enforces three conditions:
1. Session has delegation authority
2. Target host is in delegation scope
3. Target host posture satisfies required shell class

OrgCommands trait extended with target_host() method (default: None
for local commands). SessionContext enriched with delegation_scope.

Lightweight DelegationScope duplicate avoids bascule-core dep chain.
Target posture reader stubbed — requires gateway posture query API
(tracked as follow-up).

Fail-closed: unknown delegation -> denied, unknown posture -> denied.
11 unit tests for delegation and preflight.

Signed-off-by: Tyler King <tking@guildhouse.dev>
Signed-off-by: Tyler J King <tking727@gmail.com>
2026-04-15 15:17:48 -04:00
..
src feat(org-ops): worker pre-flight with delegation enforcement 2026-04-15 15:17:48 -04:00
Cargo.toml refactor: deduplicate git_blob_hash via governance-types crate 2026-04-12 11:55:29 -04:00