Back to skill

Security audit

Clawclau

Security checks for vulnerabilities and agentic risk

Overview

This skill is a real background Claude task manager, but it gives spawned agents unattended high-risk execution authority and handles task content in ways users may not expect.

Review before installing. Use this only in workspaces where unattended Claude Code execution is acceptable, because spawned tasks bypass Claude permission prompts by default. Avoid untrusted repositories and untrusted prompt content, do not pass suspicious model names or paths, keep CC_HOME to a normal trusted directory, and assume prompts, logs, and result snippets may persist under ~/.clawclau and may be sent to Feishu if notifications are configured.

Vulnerability Patterns
  • Unauthorized Access and Privilege EscalationObtains permissions beyond the task's legitimate needs
  • Insecure Skill Coding PracticesFinds exploitable flaws such as hardcoded secrets or command injection
  • Skill Instruction HijackingAlters the agent's session goals or safety constraints when the skill loads
  • Agent Memory PoisoningWrites attacker-controlled rules into memory that affect later sessions
  • Remote Payload Retrieval and ExecutionFetches external code whose behavior can change after review
Findings (2)

T09 · Insecure Skill Coding Practices

Error
Location
scripts/claude-spawn.sh:159
Finding

Shell Command Injection Through Unescaped tmux Command Construction

Content
View full analysis
> $LOG_FILE" ``` ### Technical Analysis The script builds command strings by directly interpolating variables into arguments that tmux subsequently executes through a shell. The affected values include: - `WORKDIR`, supplied as a positional command-line argument. - `MODEL`, supplied through `--model`. - `LOG_FILE`, derived from the environment-controlled `CC_HOME`. - `WRAPPER_FILE` and `PROMPT_FILE`, also derived from `CC_HOME`. Quoting the complete command string in the outer shell does not protect the interpolated values when tmux later passes that string to another shell. Spaces and shell metacharacters inside these values are therefore interpreted during this second parsing stage. The validation of `WORKDIR` only verifies that the supplied value names an existing directory. A directory name may legally contain spaces, semicolons, command substitutions, or other shell metacharacters. No restrictive validation is applied to `MODEL` or `CC_HOME`. The `pipe-pane` command has the same issue because `LOG_FILE` is inserted into the shell command `cat >> $LOG_FILE` without shell-safe quoting. ### Attack Path 1. An attacker who can invoke the skill creates an existing directory whos ...[truncated 1284 chars]
Remediation
View remediation
> %q' "$LOG_FILE" tmux pipe-pane -t "$TMUX_SESSION" "$PIPE_COMMAND" ``` 4. Prefer passing data through a controlled wrapper or environment variables rather than embedding it in a shell command. 5. Validate `MODEL` against an explicit allowlist of supported model identifiers. 6. Canonicalize and validate `CC_HOME` and `WORKDIR`, rejecting unexpected control characters. 7. Add regression tests using paths and model values containing spaces, quotes, semicolons, dollar signs, command substitutions, and newlines. ]]>

T05 · Unauthorized Access and Privilege Escalation

Error
Location
scripts/claude-spawn.sh:129
Finding

Claude Code Permission Checks Are Disabled for Every Dispatched Task

Content
View full analysis
"$3" 2>&1 ``` ```bash #!/usr/bin/env bash # Args: $1=WORKDIR [$2=MODEL] export PATH="/opt/homebrew/bin:/usr/local/bin:$PATH" cd "$1" MODEL_FLAG=() [[ -n "${2:-}" ]] && MODEL_FLAG=(--model "$2") exec claude --dangerously-skip-permissions "${MODEL_FLAG[@]}" ``` ### Technical Analysis Both print and steerable modes invoke Claude Code with `--dangerously-skip-permissions`. This flag disables the normal approval boundary for tool use and filesystem or command operations. As a result, task prompts and untrusted content found in the selected working directory can influence an autonomous agent that has the full access of the invoking user. Relevant untrusted inputs can include repository documentation, source comments, generated files, task data, or other instructions that Claude reads while processing the assignment. The detached tmux execution model further reduces immediate user visibility. Although timeout monitoring limits task duration, it does not constrain which commands may run or which files may be accessed during that period. ### Attack Path 1. A user dispatches Claude against an untrusted or compromised repository or supplies a prompt containing unsafe instructions. 2. Claude reads attacker-controlled content while attempting to complete the assigned task. 3. The content induces Claude to invoke command execution or filesystem tools. 4. Because `--dangerously-skip-permissions` is always enabled, ...[truncated 1116 chars]
Remediation
View remediation
Vulnerability Patterns
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Excessive AgencyUnrestricted Tool Access, Autonomous Decision Making, Scope Creep
  • Rogue AgentSelf-Modification, Session Persistence
  • Trigger AbuseOverly Broad Trigger, Shadow Command Trigger, Keyword Baiting Trigger
  • MCP Least PrivilegeUnderdeclared Capability, Wildcard Permission, Missing Permission Declaration
Findings (22)

Context-Inappropriate Capability

High
Category
Not specified by scanner
Confidence
98% confidence
Finding

The wrapper launches Claude with --dangerously-skip-permissions in both print and steerable modes, allowing dispatched prompts to execute actions without interactive approval. In a background tmux scheduler, this materially expands the authority of any queued task beyond simple orchestration and makes prompt-originated abuse or mistakes far more dangerous.

Content

No source excerpt is available for this finding.

Missing User Warnings

High
Category
Not specified by scanner
Confidence
97% confidence
Finding

The script silently enables Claude's dangerous permission-bypass mode without any explicit warning, consent step, or trust boundary explanation to the caller. That creates a deceptive interface where users may believe they are merely scheduling a task, while in reality they are authorizing unattended high-privilege actions.

Content

No source excerpt is available for this finding.

Undeclared Tool Scope

Medium
Category
MCP Least Privilege
Confidence
93% confidence
Finding

The skill clearly describes shell-based operational behavior (tmux orchestration, cron setup, file writes, process control) but does not declare any tool scope such as permissions or allowed-tools. This creates an authorization gap where consumers may invoke a capability-rich skill without explicit boundaries, increasing the chance of unintended command execution or filesystem/process manipulation.

Content

No source excerpt is available for this finding.

Vague Triggers

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The trigger description includes broad natural-language activation scenarios such as delegating arbitrary work, checking status, terminating tasks, and batch dispatching. Ambiguous triggering increases the risk that the skill is invoked in contexts the user did not intend, especially because the skill controls background processes, persistent state, and shell operations.

Content

No source excerpt is available for this finding.

Session Persistence

Medium
Category
Rogue Agent
Confidence
88% confidence
Finding

This is the same persistence issue duplicated by the analyzer: the documented setup persists task data, prompts, logs, and config in a user home directory and encourages shell profile export. In a task-dispatch skill, that context makes the persistence more dangerous because long-lived background jobs and stored wrappers can outlast the initiating session and operate on stale or sensitive context.

Content

Scanner excerpt · SKILL.md (reported line 40)May include surrounding context.

md
brew install tmux jq && which claude

# 初始化
mkdir -p ~/.clawclau/logs ~/.clawclau/prompts

# 配置通知(可选)
echo "notify_chat = oc_xxxxxxxx" >> ~/.clawclau/config

Session Persistence

Medium
Category
Rogue Agent
Confidence
88% confidence
Finding

This is the same persistence issue duplicated by the analyzer: the documented setup persists task data, prompts, logs, and config in a user home directory and encourages shell profile export. In a task-dispatch skill, that context makes the persistence more dangerous because long-lived background jobs and stored wrappers can outlast the initiating session and operate on stale or sensitive context.

Content

Scanner excerpt · SKILL.md (reported line 40)May include surrounding context.

md
brew install tmux jq && which claude

# 初始化
mkdir -p ~/.clawclau/logs ~/.clawclau/prompts

# 配置通知(可选)
echo "notify_chat = oc_xxxxxxxx" >> ~/.clawclau/config

Description-Behavior Mismatch

Medium
Category
Not specified by scanner
Confidence
82% confidence
Finding

Manifest 将该技能描述为基于 tmux 的 Claude Code 异步任务调度工具,重点在任务派发、进度汇报、完成通知和状态管理。L12-L17 的设计却明确加入通过 openclaw 向飞书群直接发送消息的外部通知机制,这属于额外的消息投递能力,而不是调度本身的显然实现细节。

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
92% confidence
Finding

The document instructs the skill to send notifications to Feishu chat targets configured via environment variable or local config, but it provides no warning about external transmission of task data. In a task-scheduling skill, notifications can easily include prompts, filenames, statuses, or error details, creating a real risk of unintended data disclosure to a third-party messaging platform.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
90% confidence
Finding

The schema explicitly documents persistent storage of the full prompt and log file path, which likely means potentially sensitive user inputs, secrets, file contents, or task outputs are retained on disk. In this skill's context, the tool dispatches background Claude Code tasks and supports status inspection and steering, making prompt/log retention more dangerous because operational data may accumulate silently and be exposed through local compromise, overbroad sharing, backups, or debugging workflows.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
97% confidence
Finding

The script’s comments and runtime messages are written in Chinese, and later user-facing output continues in Chinese as well. For a general-purpose utility, this imposes a specific language/locale without user opt-in or any documented justification that the tool is region-specific.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The script emits multiple Chinese-only error, status, and help messages to users during normal operation. This creates a natural-language policy concern because the file does not offer alternative locales or explain that the skill is intentionally limited to a Chinese-language audience.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
90% confidence
Finding

The script writes the full prompt to disk and later stores it in the task registry JSON, while progress/completion notifications may include extracted log snippets. If prompts contain secrets, tokens, proprietary code, or sensitive instructions, they can persist on disk and be exposed through status tooling or notifications beyond the original caller.

Content

No source excerpt is available for this finding.

Session Persistence

Medium
Category
Rogue Agent
Confidence
65% confidence
Finding

Skill establishes unauthorized persistence across sessions via cron jobs, startup scripts, or state files. Session persistence allows an attacker to maintain access beyond the current interaction.

Content

Scanner excerpt · scripts/claude-spawn.sh (reported line 229)May include surrounding context.

sh
cc_notify "$_MSG"
    ) &
    ) &
    disown

    # 进度汇报器(双重 fork,仅在 INTERVAL > 0 时启动)
    if [[ "$INTERVAL" -gt 0 ]]; then

Session Persistence

Medium
Category
Rogue Agent
Confidence
65% confidence
Finding

Skill establishes unauthorized persistence across sessions via cron jobs, startup scripts, or state files. Session persistence allows an attacker to maintain access beyond the current interaction.

Content

Scanner excerpt · scripts/claude-spawn.sh (reported line 272)May include surrounding context.

sh
cc_notify "$_MSG"
    ) &
    ) &
    disown

    # 进度汇报器(双重 fork,仅在 INTERVAL > 0 时启动)
    if [[ "$INTERVAL" -gt 0 ]]; then

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The script's description, warnings, and usage notes are written in Chinese, and later runtime messages are also emitted only in Chinese. This imposes a specific language on users without offering a language choice or documenting that the skill is intentionally limited to a Chinese-speaking context.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
91% confidence
Finding

The file's descriptions, examples, and error/output strings are written in Chinese throughout, including user-visible messages such as installation and validation errors. There is no indication that the skill is intentionally limited to a Chinese-speaking context or that users can opt into another language, which may violate language/locale policy requirements.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
84% confidence
Finding

cc_notify forwards arbitrary message text to an external Feishu target from environment or local config, with no consent check, content filtering, or caller-side warning. In a task orchestration skill, task messages may include prompts, status text, or model output that can contain sensitive project data, so this creates a realistic unintended data-exfiltration path.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
71% confidence
Finding

The natural-language guidance explicitly prioritizes Feishu direct-send notifications, which can reflect a region/platform-specific policy choice. The file does not indicate that this locale/platform constraint is optional, user-selectable, or justified as region-specific.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
98% confidence
Finding

The script's natural-language comments, usage text, and runtime messages are all in Chinese, and there is no indication that the skill is region-specific or that users can opt into another language. This can violate a language/locale policy when skills are expected to be language-neutral or offer user choice.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
96% confidence
Finding

This shell script’s natural-language comments and runtime messages are predominantly in Chinese, including status and usage text shown to users. The policy scope includes language/locale constraints in natural language, and there is no indication that users can choose another language or that the tool is explicitly limited to a Chinese-speaking environment.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
91% confidence
Finding

User-facing comments, usage text, and status/error messages in this script are written in Chinese only. Under the policy, forcing a specific language without user opt-in or a documented justification is a natural-language policy concern.

Content

No source excerpt is available for this finding.

Context-Inappropriate Capability

Low
Category
Not specified by scanner
Confidence
77% confidence
Finding

The skill manifest focuses on asynchronous Claude Code task dispatch, status queries, termination, and steering. While completion notifications are in scope, this shared library also implements outbound delivery to a specific external channel (Feishu) and parses local config to discover that target, which is a capability beyond core tmux-based scheduling mechanics.

Content

No source excerpt is available for this finding.

Static analysis

No suspicious patterns detected.