mirror of
https://bitbucket.org/siakitem/my-pi.git
synced 2026-08-28 08:35:57 +00:00
feat: add pure ssh2 remote operations
This commit is contained in:
@@ -171,19 +171,31 @@
|
||||
"description": "Optional name of the tool's input argument holding the working directory (e.g. 'workdir').",
|
||||
"type": "string",
|
||||
"minLength": 1
|
||||
},
|
||||
"decisionFloor": {
|
||||
"description": "Require every invocation of this shell alias to be reviewed at least as an ask; deny remains deny.",
|
||||
"markdownDescription": "Sets the minimum review decision for this alias. `allow` results from Bash policy are raised to `ask`, while existing `ask` and `deny` results are preserved. Only `\"ask\"` is accepted so a project override cannot weaken a global floor.",
|
||||
"type": "string",
|
||||
"const": "ask"
|
||||
}
|
||||
},
|
||||
"required": ["commandArgument"],
|
||||
"required": [
|
||||
"commandArgument"
|
||||
],
|
||||
"additionalProperties": false,
|
||||
"description": "Maps one shell-aliased tool to the input arguments holding its command and (optionally) its working directory."
|
||||
"description": "Maps one shell-aliased tool to the input arguments holding its command and optional working directory, plus an optional ask decision floor."
|
||||
},
|
||||
"description": "Maps non-bash tool names that carry shell semantics to the input arguments holding their command and working directory.",
|
||||
"markdownDescription": "Records which non-`bash` tools carry shell semantics, mapping each tool name to the input argument holding its command (and optionally its working directory).\n\nUse this when an extension replaces the native `bash` tool under a different name — e.g. `@howaboua/pi-codex-conversion` registers `exec_command` with a `cmd` argument and an optional `workdir`. Recording the alias lets the permission system gate that tool through the same bash enforcement stack as native `bash` (command decomposition, wrapper flooring, path/external-directory token gates, and `bash:` rules).\n\nExample:\n\n```json\n\"shellTools\": {\n \"exec_command\": { \"commandArgument\": \"cmd\", \"workdirArgument\": \"workdir\" }\n}\n```\n\n**Merge order:** shallow-merge by tool name across global → project. A project entry overrides a specific tool's mapping on key collision but never drops a global entry.",
|
||||
"markdownDescription": "Records which non-`bash` tools carry shell semantics, mapping each tool name to the input argument holding its command (and optionally its working directory).\n\nUse this when an extension replaces the native `bash` tool under a different name — e.g. `@howaboua/pi-codex-conversion` registers `exec_command` with a `cmd` argument and an optional `workdir`. Recording the alias lets the permission system gate that tool through the same bash enforcement stack as native `bash` (command decomposition, wrapper flooring, path/external-directory token gates, and `bash:` rules).\n\nSet `decisionFloor` to `\"ask\"` when the wrapper crosses an additional trust boundary, such as SSH or container execution. Bash `allow` results are raised to `ask`; existing `ask` and `deny` results remain unchanged.\n\nExample:\n\n```json\n\"shellTools\": {\n \"exec_command\": { \"commandArgument\": \"cmd\", \"workdirArgument\": \"workdir\" },\n \"ssh_bash\": { \"commandArgument\": \"command\", \"decisionFloor\": \"ask\" }\n}\n```\n\n**Merge order:** merge each tool mapping by field across global → project. Project values can replace argument names, while a global `decisionFloor: \"ask\"` survives when the project entry omits it.",
|
||||
"examples": [
|
||||
{
|
||||
"exec_command": {
|
||||
"commandArgument": "cmd",
|
||||
"workdirArgument": "workdir"
|
||||
},
|
||||
"ssh_bash": {
|
||||
"commandArgument": "command",
|
||||
"decisionFloor": "ask"
|
||||
}
|
||||
}
|
||||
]
|
||||
@@ -248,7 +260,9 @@
|
||||
"maxLength": 500
|
||||
}
|
||||
},
|
||||
"required": ["action"],
|
||||
"required": [
|
||||
"action"
|
||||
],
|
||||
"additionalProperties": false,
|
||||
"description": "Deny with an optional custom reason shown to the agent when the action is blocked."
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user