fix: quote \$ARGUMENTS in cancel, result, and status commands (#168)
Unquoted \$ARGUMENTS in the ! shell commands allowed shell metacharacters in user-supplied job IDs to be expanded before Node received them (e.g., `task-123; malicious-cmd` would execute the trailing command). This is inconsistent with review.md and adversarial-review.md, which both wrap "$ARGUMENTS" in double quotes. Co-authored-by: claude[bot] <claude-bot@anthropic.com> Co-authored-by: Claude Code <noreply@anthropic.com>
This commit is contained in:
parent
8e9a38cdfe
commit
6a5c2ba53b
@ -5,4 +5,4 @@ disable-model-invocation: true
|
|||||||
allowed-tools: Bash(node:*)
|
allowed-tools: Bash(node:*)
|
||||||
---
|
---
|
||||||
|
|
||||||
!`node "${CLAUDE_PLUGIN_ROOT}/scripts/codex-companion.mjs" cancel $ARGUMENTS`
|
!`node "${CLAUDE_PLUGIN_ROOT}/scripts/codex-companion.mjs" cancel "$ARGUMENTS"`
|
||||||
|
|||||||
@ -5,7 +5,7 @@ disable-model-invocation: true
|
|||||||
allowed-tools: Bash(node:*)
|
allowed-tools: Bash(node:*)
|
||||||
---
|
---
|
||||||
|
|
||||||
!`node "${CLAUDE_PLUGIN_ROOT}/scripts/codex-companion.mjs" result $ARGUMENTS`
|
!`node "${CLAUDE_PLUGIN_ROOT}/scripts/codex-companion.mjs" result "$ARGUMENTS"`
|
||||||
|
|
||||||
Present the full command output to the user. Do not summarize or condense it. Preserve all details including:
|
Present the full command output to the user. Do not summarize or condense it. Preserve all details including:
|
||||||
- Job ID and status
|
- Job ID and status
|
||||||
|
|||||||
@ -5,7 +5,7 @@ disable-model-invocation: true
|
|||||||
allowed-tools: Bash(node:*)
|
allowed-tools: Bash(node:*)
|
||||||
---
|
---
|
||||||
|
|
||||||
!`node "${CLAUDE_PLUGIN_ROOT}/scripts/codex-companion.mjs" status $ARGUMENTS`
|
!`node "${CLAUDE_PLUGIN_ROOT}/scripts/codex-companion.mjs" status "$ARGUMENTS"`
|
||||||
|
|
||||||
If the user did not pass a job ID:
|
If the user did not pass a job ID:
|
||||||
- Render the command output as a single Markdown table for the current and past runs in this session.
|
- Render the command output as a single Markdown table for the current and past runs in this session.
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user