Repository navigation
fix(agents): enforce Claude CLI cron tool policies - #112457
Conversation
|
ClawSweeper status: review started. I am starting a fresh review of this pull request: fix(agents): enforce Claude CLI cron tool policies This is item 1/1 in the current shard. Shard 0/1. This placeholder means the worker is alive and reading the current context. I will edit this same comment with the actual review when the claws are done clicking. Crustacean status: shell secured, claws on keyboard, evidence pebbles being sorted. |
|
ClawSweeper status: review started. I am starting a fresh review of this pull request: fix(agents): enforce Claude CLI cron tool policies This is item 1/1 in the current shard. Shard 0/1. This placeholder means the worker is alive and reading the current context. I will edit this same comment with the actual review when the claws are done clicking. Crustacean status: shell secured, claws on keyboard, evidence pebbles being sorted. |
|
ClawSweeper status: review started. I am starting a fresh review of this pull request: fix(agents): enforce Claude CLI cron tool policies This is item 1/1 in the current shard. Shard 0/1. This placeholder means the worker is alive and reading the current context. I will edit this same comment with the actual review when the claws are done clicking. Crustacean status: shell secured, claws on keyboard, evidence pebbles being sorted. |
|
Maintainer decision: The final head also isolates Claude customization processes for exact restricted runs. Focused tests, the Blacksmith changed-surface gate, fresh autoreview, and live Claude Code 2.1.217 hook-bypass proof are clean. |
|
Merged via squash.
|
* fix(agents): enforce Claude CLI tool policies * fix(agents): bound CLI runtime tool grants * fix(agents): isolate restricted Claude runs
Summary
toolsAllowpolicies through a backend-owned MCP allowlistCLAUDE.mdCloses #112454
Testing
node scripts/run-vitest.mjs src/agents/cli-runner/prepare.test.ts(77 passed)node scripts/run-vitest.mjs extensions/anthropic/cli-shared.test.ts(40 passed)node scripts/run-vitest.mjs src/gateway/mcp-http.runtime.test.tsfocused policy tests (5 passed)node scripts/check-changed.mjs -- docs/gateway/cli-backends.md docs/plugins/cli-backend-plugins.md extensions/anthropic/cli-shared.test.ts extensions/anthropic/cli-shared.ts(Blacksmith Testbox passed)SessionStartuser hook ran with native tools disabled and onlymcp__openclaw__messageallowed; the isolated restricted argv suppressed the hook while retaining explicit MCP config and the exact allowed name. Both probes used an invalid API key and reportedduration_api_ms: 0.git diff --checkSecurity
Restricted runtime caps are host-owned: plugins may select only grant-scoped OpenClaw MCP tools, core rejects authority expansion before minting the loopback grant, Claude customizations are disabled for exact restricted runs, and native backend tools stay disabled.