Community plugin: dsh-tool-policy #174
Replies: 2 comments 2 replies
|
I read through the repo and the real Loader test. One packaging detail looks worth fixing before publication. The current Affiliation: I work on BitFun. We started a dsh-plugin compatibility adapter today, and this would be a useful first third-party fixture because it exercises a real Cordis plugin plus trust/version diagnostics. Our current milestone is projection-only—manifest/patch discovery, provenance, content hash, trust, status and diagnostics; no npm install or Cordis execution yet, and unreleased. If you add the bundle metadata, I’m happy to run its package shape through that adapter and report concrete incompatibilities: https://github.com/GCWing/BitFun |
|
I built a small answerer against
|
| layer | role | strength |
|---|---|---|
| sandbox mode | removes the capability | enforcing |
tools/pre-execute |
catches known-bad shapes early, records the decision | advisory — bypassable by rephrasing |
approval/request |
verdict on anything that escalates | enforcing — the only way out |
Under that framing this plugin is doing exactly the right job, and expanding the predicate language would make it look like the top row without becoming it.
Presets that match the layer. I'd avoid anything named for danger (block-destructive, safe-shell), because such a preset cannot deliver what its name promises. Presets built around visibility and routing seem more defensible — e.g. one that marks mutating and external tools ask so every such call becomes an audited verdict, one that denies known credential-exfil shapes as a fast fail with a clear reason, and a deny-default starter with an explicit allowlist for read-only tools. All three are honest about being routing rather than containment.
One documentation request. A short "what this does not do" section stating that argument matching is advisory and should be paired with a restrictive sandbox mode would save deployers the experiment above. Right now the README reads as stronger than the mechanism can be.
Packaging looked correct when I checked: dsh.bundle.patch is declared, cordis.patch.yml ships a deny-default row, and the >=0.1.0-rc.5 <0.2.0 peer range covers rc.6 — I verified tools/pre-execute and the PreToolDecision shape are unchanged in rc.6, so the earlier packaging comment appears resolved.
Uh oh!
There was an error while loading. Please reload this page.
DeepSeek Harness already provides the execution primitives that a production agent needs: sandboxing, one-shot approval, cooperative timeouts, provider retry, repeat-call reminders, and session telemetry. The remaining deployment gap is a small, generic policy seam that can apply the same decision vocabulary to every registered tool, including third-party and MCP tools.
dsh-tool-policyis an independent Cordis plugin that attaches to the publictools/pre-executewaterfall. It compiles ordered tool-name and JSON-Pointer argument rules, then returnsdeny, routesaskinto the existing Harness approval seam, or delegatesallowwithnext(). It defaults to deny, never rewrites arguments, never runs tool bodies, and does not create a second audit, timeout, retry, or approval implementation.After publication, install it with
pnpm add dsh-tool-policyand add it to a Cordis composition:Repository: https://github.com/Drifter-yh/dsh-tool-policy
The repository includes pure matcher tests, ToolRuntime plugin tests, and a real Cordis Loader composition. It was tested against Harness commit
47f943859bef60e4160492346772ded9b24f765a(0.1.0-rc.5).Feedback requested:
tools/pre-executethe right public extension point for deployment policy?Topics suggested for the repository:
dsh-plugin,deepseek-harness,cordis,agent-security,tool-governance.All reactions