security: isolate adaptive authority from agent OS identity
Context
The hierarchical adaptive Taskflow design currently assumes that Agent processes, ControlHost, authority credentials, and local authority storage may run under the same OS user identity (UID).
Under that deployment model, protocol checks still prevent accidental or ordinary misuse, but they do not constitute a strong security boundary against a malicious or prompt-injected Agent with same-UID filesystem/process access. Such an Agent may be able to read signing material, access authenticated IPC, or directly reach writable authority files.
This is intentionally not required for the current RFC implementation or release path. The supported claim remains a local, non-adversarial trust model; documentation and capabilities must not describe same-UID mode as resistant to a malicious Agent.
Possible future direction
Introduce an authority boundary whose credentials and write permissions are unavailable to the Agent identity:
- a dedicated
taskflow-authoritydaemon/service under a separate OS identity, container, or protected service account; - OS-backed credentials such as Keychain, Secure Enclave, keyring, TPM, or HSM, combined with caller authentication that distinguishes Host/ControlHost from Agent processes;
- authenticated IPC with replay protection, scoped one-shot capabilities, CAS/Approval/policy revalidation, key rotation, recovery, and audit receipts;
- exclusive authority-service write access to ControlStore/adaptive authority state.
OS-backed key storage alone is insufficient if the Agent and Host receive the same credential-use permission.
Deferred acceptance criteria
- [ ] Define the threat model and supported platforms.
- [ ] Prove Agent processes cannot read/export/use authority credentials.
- [ ] Prove Agent processes cannot directly mutate authority storage.
- [ ] Authenticate Host/ControlHost callers independently of the Agent UID.
- [ ] Revalidate CAS, Approval, policy, scope, and effect constraints inside the authority boundary.
- [ ] Cover restart, replay, key rotation, revocation, downgrade, and recovery.
- [ ] Add adversarial tests for credential theft, IPC impersonation, replay, and direct-store mutation.
- [ ] Update capability negotiation and product copy so strong isolation is advertised only when attested.
Current disposition
Deferred. Do not block the hierarchical adaptive RFC on this issue. Until implemented and qualified, treat same-UID operation as a trusted-local deployment mode rather than a malicious-Agent security boundary.
Not closing this with the 0.3.0-beta.1.1 hotfix (#140).
This issue is a deferred security architecture: a separate OS identity / authority daemon, OS-backed credentials, authenticated IPC, and adversarial tests. A same-UID protocol check is still not a malicious-Agent boundary. The issue text itself says it must not block the current release path.
Staying open. #137 (/tf web) also stays open on the 0.3-C WebUI track.