Summary
Add runtime policy enforcement for externally provided generated tools, including provider/capability revocation and audit correlation.
Background
OpenHuman has a generic policy middleware and approval/audit primitives. External generated tools need generic runtime enforcement so provider trust, capability status, risk, approvals, and execution audit can be checked on every call.
Acceptance criteria
- Add config-backed runtime policy rules for generated tools by provider id, tool name/capability id, and risk level.
- Policy supports allow, deny, and approval-required outcomes.
- Provider or capability revocation takes effect before tool execution.
- Policy decisions include structured denial/approval reasons suitable for diagnostics.
- Tool execution audit can correlate provider id, capability id, risk, policy decision, approval id when present, and final execution outcome.
- Default behavior remains backward-compatible for existing tools unless generated-tool runtime enforcement is enabled.
- Add focused Rust tests for allow, deny, approval-required, revoked provider/capability, and audit correlation paths.
Non-goals
- Do not add any runtime-specific bundle format.
- Do not implement OS sandboxing.
- Do not add frontend policy editors in this issue.
Summary
Add runtime policy enforcement for externally provided generated tools, including provider/capability revocation and audit correlation.
Background
OpenHuman has a generic policy middleware and approval/audit primitives. External generated tools need generic runtime enforcement so provider trust, capability status, risk, approvals, and execution audit can be checked on every call.
Acceptance criteria
Non-goals