shell_exec
Run a one-shot shell command with rule-based secret injection while redacting secret values from output and blocking dangerous environment-reading commands.
Instructions
Execute a one-shot shell command with secrets injected per matching rule. Output is redacted: injected secret values never appear in the response. Dangerous commands (env, printenv, export -p, /proc/*/environ, ...) are hard-blocked. There is no free-form env parameter; secrets are only injected by reference via rules.
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": "shell_exec"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| cwd | No | working directory (~ is expanded); default: server cwd | |
| command | Yes | shell command to execute | |
| profile | No | optional profile name for rule matching | |
| extraEnv | No | non-secret env vars, keys must be in defaults.extraEnvAllowlist |