ketan_run_bash_safe
Execute shell commands with automatic snapshot and rollback, blocking dangerous commands for safe state-changing operations.
Instructions
Execute a shell command with FULL Ketan-OS protection:
Pre-flight dangerous command guard (blocks rm -rf /, fork bombs, etc.).
Atomic snapshot before execution.
Run the command in the workspace directory.
On non-zero exit or exception → automatic rollback to pre-command state.
Always prefer this over raw bash for state-changing commands.
Args: command: Shell command to run (executed in workspace directory) timeout_seconds: Maximum execution time before timeout (default: 30s)
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"command": "<command>"
},
"name": "ketan_run_bash_safe"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| command | Yes | ||
| timeout_seconds | No |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |