Back to skill

Security audit

Complex Task Subagent

Security checks for vulnerabilities and agentic risk

Overview

This skill supports task automation, but it also asks users to weaken device pairing and set up persistent unattended agent behavior that can continue after user silence.

Review this skill carefully before installing. Use it only in a test or tightly controlled OpenClaw environment, do not enable silent device auto-approval, do not put task-specific heartbeat instructions under agents.defaults without an expiry and rollback plan, and do not allow timeout-based escalation for critical actions. Treat the bundled scripts and reference snippets as unsafe until path validation, eval removal, and credential-handling guidance are fixed.

Vulnerability Patterns
  • Unauthorized Access and Privilege EscalationObtains permissions beyond the task's legitimate needs
  • System PersistenceInstalls backdoors, hooks, services, or scheduled tasks that survive the run
  • 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
Findings (6)

T05 · Unauthorized Access and Privilege Escalation

Error
Location
SKILL.md:223
Finding

Pairing Controls Can Be Replaced with Silent Automatic Approval

Content
View full analysis
~/.openclaw/devices/pending.json << 'EOF' { "silent": true, "autoApprove": ["browser", "cli", "openclaw-control-ui"], "logLevel": "warn" } EOF openclaw gateway restart ``` ### Technical Analysis The documented procedure replaces the OpenClaw pending-device policy with a configuration that silently approves browser, CLI, and control-UI clients. Pairing is an authentication and authorization boundary intended to require an explicit trust decision before a new client receives access. Setting `silent` to `true` while adding powerful client classes to `autoApprove` removes that interactive control. Reducing logging to `warn` also makes successful automatic approvals less visible. The replacement operation discards any existing policy entries rather than applying a narrowly scoped change. This behavior is not required for task orchestration and violates least-privilege principles. ### Attack Path 1. A user follows the documented procedure to resolve a CLI pairing problem. 2. The existing `pending.json` policy is overwritten. 3. The Gateway is restarted and loads the automatic-approval policy. 4. An untrusted browser, CLI client, or control UI submits a pairing request. 5. The request is approved without an explicit user decision. 6. The newly approved client can access whatever OpenClaw capabilities are granted to that client class. ### Impact Assessment Successful exploitation may grant unauthorized access to OpenClaw control interfaces. Depending on the Gateway's client permissions, this could expose Agent sessions, tools, files, messaging integrations, configuration changes, or command-execution capabilities. The scope extends beyond the current task becaus ...[truncated 111 chars]
Remediation
View remediation

T06 · System Persistence

Error
Location
SKILL.md:966
Finding

Persistent Global Heartbeat Installs Cross-Session Agent Instructions

Content
View full analysis
Remediation
View remediation

T05 · Unauthorized Access and Privilege Escalation

Error
Location
scripts/notification-manager.sh:261
Finding

Confirmation Timeout Escalates Tasks into Unattended Execution

Content
View full analysis
"${TASK_PROGRESS_FILE}.tmp" mv "${TASK_PROGRESS_FILE}.tmp" "$TASK_PROGRESS_FILE" log_notification "$task_id" \ "Switched to unattended mode after timeout" \ "FALLBACK" fi return 0 fi ``` The documented orchestration workflow subsequently advances eligible phases automatically: ```bash if [ $(( $(date +%s) - lastConfirmation )) -gt 7200 ]; then executionMode="unattended" fi ``` ### Technical Analysis The confirmation mechanism treats the absence of a user response as authorization to increase autonomy. After the timeout, `executionMode` becomes `unattended` and `preferredAction` becomes `auto`. This reverses secure approval semantics. A timeout cannot establish that the user understood or accepted an operation. It is especially unsafe because the project uses `requiresConfirmation`, `critical`, and `requiresGatewayRestart` fields for operations that are expected to need explicit approval. When combined with the persistent Heartbeat, the changed state allows the Agent to resume and automatically advance phases after the user has failed to respond. ### Attack Path 1. A phase reaches an operation marked as requiring confirmation. 2. A notification is recorded and the system waits for a response. 3. The user is unavailable, misses the message, or cannot respond. 4. The configured timeout expires. 5. `notification-manager.sh fallback` changes the task to `unattended` and se ...[truncated 692 chars]
Remediation
View remediation

T09 · Insecure Skill Coding Practices

Error
Location
scripts/monitor-task.sh:72
Finding

User-Controlled File Path Is Interpolated into Python Source Code

Content
View full analysis
Remediation
View remediation

T09 · Insecure Skill Coding Practices

Error
Location
scripts/checkpoint-writer.py:50
Finding

Checkpoint Filename Allows Traversal Outside the Checkpoint Directory

Content
View full analysis
Remediation
View remediation

T09 · Insecure Skill Coding Practices

Error
Location
references/advanced-patterns.md:148
Finding

Documented Conditional Branch Evaluator Executes Untrusted Python Expressions

Content
View full analysis
Remediation
View remediation
Vulnerability Patterns
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
  • Excessive AgencyUnrestricted Tool Access, Autonomous Decision Making, Scope Creep
  • Tool MisuseTool Parameter Abuse, Chaining Abuse, Unsafe Defaults
  • Rogue AgentSelf-Modification, Session Persistence
Findings (53)

Tp4

High
Category
MCP Tool Poisoning
Confidence
97% confidence
Finding

The declared description presents a full orchestration framework whose core capability is executing complex multi-stage tasks through subagents with checkpointing, retries, synchronization, and unattended recovery. The supplied code chunk is much narrower: it is a cache-management utility for JSON files under a cache directory. While the cache contents include fields like phase, subagent, step, and status, and there is a recover command, recovery only reads the cache and prints a suggested sessions_spawn command for manual use. There is no actual subagent spawning, no orchestration engine, no retry loop, no timeout handling, no checkpoint-driven execution flow beyond simple file storage, and no synchronization logic. Thus the code is related to orchestration support, but its actual primary purpose and implemented capabilities are materially more limited than the declared description.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
95% confidence
Finding

The declared description presents a full orchestration framework for complex multi-stage tasks using subagents, with execution control features like retries, auto-progress, sync, and recovery. The supplied code chunk only implements checkpoint persistence to local JSON files and a CLI wrapper to write checkpoint records. Checkpoint management is related to the declared system, but this chunk does not actually perform the core orchestrator behaviors claimed in the description. Therefore the description materially overstates what this code does.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
97% confidence
Finding

The description presents an active orchestration framework responsible for executing multi-stage tasks through subagents, managing state, handling checkpoints, retries, timeouts, and unattended recovery. The actual code chunk is purely a monitoring utility: it parses command-line flags, reads an existing progress JSON file, computes and displays progress, inspects phase metadata, verifies whether checkpoint files exist, lists subagents if the openclaw command is available, and shows recent logs. It does not create or manage tasks, spawn subagents, update checkpoints, perform retries, or implement orchestration control flow. This is a material purpose mismatch: monitoring/observability versus orchestration/execution.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
98% confidence
Finding

The declared description promises a broad orchestration framework centered on complex task execution via subagents (sessions_spawn), checkpoint-driven progress, retries, synchronization, and unattended serial orchestration. The supplied code does not implement subagent control, task decomposition, synchronization, or general orchestration. Instead, it manages human confirmation notifications: sending reminders, checking reminder intervals, logging events, and after timeout changing a JSON field to unattended mode. While this could support a larger orchestration system, the code chunk itself is a notification/fallback utility, making the declared purpose materially inaccurate for this specific code.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
96% confidence
Finding

The declared description presents a full complex-task orchestration framework with subagent execution, checkpoint-driven state handling, retries, recovery, and unattended progression. The supplied code chunk does not implement that framework behavior. Instead, it is a preparatory configuration script: it parses CLI flags, reads a task-progress JSON file, prompts the user to choose execution mode, optionally creates/opens a preferences file, and writes selected settings back to the JSON file. While execution-mode selection could support an orchestration system, this code alone is materially narrower and different from the declared primary purpose. Therefore the description does not accurately represent the actual behavior of this code chunk.

Content

No source excerpt is available for this finding.

Missing User Warnings

High
Category
Not specified by scanner
Confidence
98% confidence
Finding

The skill recommends changing device pairing policy to silently auto-approve clients such as browser, CLI, and control UI. That weakens a trust boundary and could allow unauthorized clients to pair without review, enabling remote control or abuse of the OpenClaw environment.

Content

No source excerpt is available for this finding.

Ssd 4

High
Category
Not specified by scanner
Confidence
96% confidence
Finding

This section explicitly couples confirmation prompts with automatic fallback to unattended mode after timeout, creating permission escalation over time. In context, the skill also discusses config edits, bot administration, and external communications, so unattended fallback substantially increases the chance of unauthorized impactful actions.

Content

No source excerpt is available for this finding.

Tool Parameter Abuse

High
Category
Tool Misuse
Confidence
94% confidence
Finding

The cache cleanup command interpolates $cacheFile into rm -f without showing validation or safe path enforcement. If cacheFile is attacker-controlled or malformed, it could delete unintended files via path traversal or shell-unsafe values, especially in an unattended workflow.

Content

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

检查任务状态

if [ "$phase_status" = "completed" ]; then # 回收缓存 rm -f /root/.openclaw/workspace/complex-task-subagent-experience/cache/$cacheFile echo "[$(date '+%Y-%m-%d %H:%M:%S')] ♻️ 缓存已回收: $cacheFile" >> task-cache.log fi

text

Context-Inappropriate Capability

High
Category
Not specified by scanner
Confidence
95% confidence
Finding

The document instructs users to configure external image-generation endpoints and secrets despite the skill being framed as orchestration. This is dangerous because it can route data to arbitrary third-party services and normalize placing API keys into shared configuration without purpose limitation.

Content

No source excerpt is available for this finding.

Context-Inappropriate Capability

High
Category
Not specified by scanner
Confidence
95% confidence
Finding

Managing external messaging groups and bot administration is an unjustified privileged capability for a subagent-orchestration skill. If followed, these instructions could grant bots administrative access in Feishu, enabling message injection, channel misuse, or broader organizational abuse.

Content

No source excerpt is available for this finding.

Credential Access

High
Category
Privilege Escalation
Confidence
90% confidence
Finding

The guide explicitly instructs loading an SSH private key into an agent with ssh-add, which is direct handling of authentication credentials. In the context of an orchestration skill running in a root-scoped workspace, this materially increases risk because compromise or misuse of the environment could expose repository access and enable unauthorized code pushes.

Content

Scanner excerpt · references/troubleshooting.md (reported line 695)May include surrounding context.

md
# 添加到 SSH agent
   eval "$(ssh-agent -s)"
   ssh-add ~/.ssh/id_ed25519

   # 复制公钥到 Gitee
   cat ~/.ssh/id_ed25519.pub

Credential Access

High
Category
Privilege Escalation
Confidence
90% confidence
Finding

Code accesses credential files (SSH keys, AWS credentials, etc.). This could indicate credential theft attempts.

Content

Scanner excerpt · references/troubleshooting.md (reported line 698)May include surrounding context.

ssh-add ~/.ssh/id_ed25519

复制公钥到 Gitee

cat ~/.ssh/id_ed25519.pub

text

3. 解决冲突:

Undeclared Tool Scope

Medium
Category
MCP Least Privilege
Confidence
83% confidence
Finding

The skill documents substantial file read/write and configuration mutation behavior, but it declares no explicit tool scope or permissions. That increases the chance the agent is granted broader capabilities than users expect, especially because the skill edits OpenClaw config, state files, caches, and logs.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
91% confidence
Finding

The operational instructions, prompts, trigger phrases, and examples are predominantly in Chinese, which effectively imposes a language requirement on users. The file does not offer an alternative language option or state that the skill is intentionally limited to a Chinese-speaking or region-specific context.

Content

No source excerpt is available for this finding.

Vague Triggers

Medium
Category
Not specified by scanner
Confidence
97% confidence
Finding

The trigger phrases are broad, including common workflow terms like 'unattended', 'auto-progress', and 'subagent', making accidental invocation more likely. In a skill that promotes unattended execution and config changes, unintended activation materially increases risk.

Content

No source excerpt is available for this finding.

Autonomous Decision Making

Medium
Category
Excessive Agency
Confidence
97% confidence
Finding

The autoApprove pairing configuration enables autonomous trust decisions for new clients. This bypasses an important human authorization step and can let any matching client type gain access without review, which is especially dangerous in an automation platform.

Content

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

md
cat > ~/.openclaw/devices/pending.json << 'EOF'
{
  "silent": true,
  "autoApprove": ["browser", "cli", "openclaw-control-ui"],
  "logLevel": "warn"
}
EOF

Ssd 4

Medium
Category
Not specified by scanner
Confidence
92% confidence
Finding

The document frames a confirmation flow that automatically escalates to unattended execution after user silence. Silence is not valid consent, and converting non-response into authorization can let high-impact tasks proceed without an informed decision.

Content

No source excerpt is available for this finding.

Ssd 4

Medium
Category
Not specified by scanner
Confidence
87% confidence
Finding

Night/unattended mode is intentionally designed to let the agent self-decide while the user is absent. In a skill that mixes orchestration with configuration changes and external platform actions, unattended self-decision increases the chance of overreach or irreversible operations without review.

Content

No source excerpt is available for this finding.

Session Persistence

Medium
Category
Rogue Agent
Confidence
60% 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 · SKILL.md (reported line 1125)May include surrounding context.

创建必要的目录结构

cd $WORKSPACE mkdir -p cache output 配置

text

### 2. 配置绘图模型(第三方 API)

Session Persistence

Medium
Category
Rogue Agent
Confidence
60% 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 · SKILL.md (reported line 1125)May include surrounding context.

创建必要的目录结构

cd $WORKSPACE mkdir -p cache output 配置

text

### 2. 配置绘图模型(第三方 API)

Description-Behavior Mismatch

Medium
Category
Not specified by scanner
Confidence
93% confidence
Finding

The skill expands beyond orchestration into configuring third-party image-generation endpoints and API keys, which introduces external data flow and secret-handling that are unrelated to the declared purpose. That kind of scope creep increases attack surface and can cause users to expose credentials to services they did not intend this skill to manage.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
88% confidence
Finding

The examples show third-party API endpoints and API keys without meaningful warnings about credential handling or data transfer. This can lead operators to paste secrets into persistent config and unknowingly send sensitive prompts or media to untrusted external services.

Content

No source excerpt is available for this finding.

Description-Behavior Mismatch

Medium
Category
Not specified by scanner
Confidence
94% confidence
Finding

The skill also provides operational instructions for creating and administering Feishu groups, which is broader than task orchestration and introduces messaging-platform administration capabilities. This mismatch makes the skill more dangerous because users may authorize a seemingly harmless orchestration tool that actually teaches privileged external actions.

Content

No source excerpt is available for this finding.

External Transmission

Medium
Category
Data Exfiltration
Confidence
86% confidence
Finding

The documented Feishu API calls cause external transmission of credentials and administrative requests to a third-party service. External transmission is not always malicious, but here it is security-relevant because the skill encourages handling app secrets and group-management operations under an unrelated orchestration label.

Content

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

bash
# 首先需要飞书 API 的 app_access_token
curl -X POST "https://open.feishu.cn/open-apis/auth/v3/tenant_access_token/internal" \
  -H "Content-Type: application/json" \
  -d '{
    "app_id": "cli_a92f97ca9b799cd4",

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
89% confidence
Finding

该 markdown 文件整体以中文呈现,标题和说明未表明这是区域限定或面向中文用户的专用文档,也未提供语言/locale 选择。根据规则,若技能内容强制特定语言而没有用户 opt-in 或合理说明,属于自然语言层面的语言策略违例。

Content

No source excerpt is available for this finding.

Static analysis

No suspicious patterns detected.