Back to skill

Security audit

Openclaw Team Builder

Security checks for vulnerabilities and agentic risk

Overview

This skill mostly does what it claims, but it has high-impact team and channel administration behavior with unsafe credential handling and a confirmed local code-injection risk.

Review this before installing in a production OpenClaw setup. Do not paste real bot tokens or Feishu secrets into chat or shell history; use throwaway credentials if testing and rotate any secrets already shared. Run mutating commands only after reviewing the planned changes, and be cautious with --yes, --fix, --rollback, and channel binding because they can change persistent agent configuration and trust relationships.

Vulnerability Patterns
  • Insecure DependenciesIntroduces malicious components through unsafe dependency sources
  • 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 (3)

T09 · Insecure Skill Coding Practices

Error
Location
scripts/team-builder.sh:780
Finding

Python Code Injection Through Unvalidated Agent Identifiers

Content
View full analysis
/dev/null) fi local subordinates="" if [ -f "$HIERARCHY_FILE" ]; then subordinates=$(python3 -c " import json h=json.load(open('$HIERARCHY_FILE')) a=h.get('agents',{}).get('$aid',{}) manages=a.get('manages',[]) for m in manages: mi=h['agents'].get(m,{}) print(f\"- {mi.get('emoji','🤖')} {mi.get('name',m)} ({m})\") " 2>/dev/null) fi ``` Additional instances of the same pattern include: ```bash agent_filter = '$agent_filter' ``` and: ```bash python3 -c " import json with open('$CONFIG_FILE') as f: c = json.load(f) a2a = c.get('tools', {}).get('agentToAgent', {}) allow = a2a.get('allow', []) for a in c.get('agents', {}).get('list', []): if a['id'] not in allow and a['id'] != 'main': allow.append(a['id']) if '$aid' not in allow: allow.append('$aid') ``` ### Technical Analysis Values originating from the `--id`, `--parent`, and `--agent` command-line parameters are expanded directly into Python source passed to `python3 -c`. These values are placed inside Python string literals without escaping. The documentation describes agent IDs as kebab-case, but the script does not enforce that restriction before the values reach the embedded Python programs. A value containing a single quote can terminate the intended Python string. The remaining content can then introduce additional P ...[truncated 2011 chars]
Remediation
View remediation

T09 · Insecure Skill Coding Practices

Warning
Location
SKILL.md:192
Finding

Channel Credentials Exposed Through Command-Line Arguments and Agent Conversation History

Content
View full analysis
--channel telegram --token --yes # Discord $TB --channels --agent --channel discord --token --yes # Feishu $TB --channels --agent --channel feishu --feishu-app-id --feishu-secret --yes ``` Then restart gateway: ```bash openclaw gateway restart ``` ``` The script accepts those secrets directly as command-line values: ```bash --feishu-app-id) B_FEISHU_APPID="$2"; shift 2 ;; --feishu-secret) B_FEISHU_SECRET="$2"; shift 2 ;; --suggest) MODE="suggest"; shift ;; --goal) B_GOAL="$2"; shift 2 ;; --channels) MODE="channels"; shift ;; --agent) B_AGENT="$2"; shift 2 ;; --channel) B_CHANNEL="$2"; shift 2 ;; --token) B_TOKEN="$2"; shift 2 ;; ``` The values are subsequently forwarded to OpenClaw commands: ```bash openclaw config set --json "channels.feishu.accounts.$agent_filter" \ "{\"appId\":\"$feishu_appid\",\"appSecret\":\"$feishu_secret\"}" 2>/dev/null ``` ```bash openclaw channels add --channel "$channel_name" --token "$channel_token" \ --account "$agent_filter" 2>/dev/null ``` ### Technical Analysis The documented AI workflow explicitly asks users to send bot tokens and application secrets to the Agent, after which the Agent inserts them into shell commands. This exposes credentials through multiple channels: - Agent conversation records and platform-side transcripts. - Shell history if a human copies or manually executes the documented commands. - Process argument inspection while `team-builder.sh` or `openclaw` is running. - Automation logs, command traces, or audit systems that record proc ...[truncated 1542 chars]
Remediation
View remediation

T08 · Insecure Dependencies

Warning
Location
README.md:27
Finding

Unpinned Remote Package Execution Through npx Installation Instructions

Content
View full analysis
" note "健康检查: openclaw health" note "查看日志: openclaw logs" note "修复问题: openclaw doctor --fix" blank } ``` ### Technical Analysis The installation path invokes `npx clawhub` without an exact package version or an integrity value. Depending on the local npm cache and `npx` behavior, this can retrieve the current package from a remote registry and execute it. The code executed by this command is therefore mutable after the audited repository has been reviewed. The repository does not bind the installation command to a specific reviewed artifact, checksum, publisher identity, or immutable release. This is a supply-chain weakness rather than evidence that the current `clawhub` package is malicious. Exploitation depends on compromise or replacement of the package, publisher account, registry resolution, or a future package release. ### Attack Path 1. A user follows the documented installation command. 2. `npx` resolves the unversioned `clawhub` package through the configured npm registry. 3. The registry or cache returns a package version that was not part of this audit. 4. `npx` downloads and executes that package with the user's privileges. 5. A compromised or malicious package performs arbitrary actions before or during Skill installation. Potential enabling events include publisher-account compromise, malicious ...[truncated 766 chars]
Remediation
View remediation
install team-builder ``` 2. Publish and document the expected package publisher, exact version, release checksum, and source revision. 3. Prefer an immutable installation artifact verified before execution. For example, download a versioned archive, validate its SHA-256 digest, inspect or extract it, and then run the local installer. 4. Where npm lockfiles are applicable, commit a lockfile with integrity metadata and use deterministic installation commands such as `npm ci`. 5. Avoid recommending bare `npx clawhub`, including in runtime operational tips. 6. Document how users can verify that the installed `SKILL.md` and `scripts/team-builder.sh` match the audited release. 7. Add release signing or provenance attestations so users can validate that the package was built from the stated repository revision. ]]>
Vulnerability Patterns
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • 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
Findings (24)

Missing User Warnings

High
Category
Not specified by scanner
Confidence
97% confidence
Finding

The workflow explicitly tells the agent to construct and execute team-creation commands and restart the gateway in the same response, without a user-facing warning about system modifications. This enables immediate state changes to local configuration and service availability based on a single conversational prompt, increasing the risk of unintended or socially engineered changes.

Content

No source excerpt is available for this finding.

Missing User Warnings

High
Category
Not specified by scanner
Confidence
98% confidence
Finding

The skill asks users to send bot tokens and app secrets in chat and provides no warning that these are sensitive credentials with account-level impact. Secrets disclosed this way may be retained in logs, transcripts, analytics, or memory, enabling compromise of external bots and downstream messaging channels.

Content

No source excerpt is available for this finding.

Missing User Warnings

High
Category
Not specified by scanner
Confidence
98% confidence
Finding

The channel-management section again normalizes requesting and using bot credentials without any explicit sensitivity warning or least-privilege guidance. Repetition in operational guidance makes insecure secret-sharing appear standard and increases the likelihood that users will disclose production credentials into chat-based systems.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
93% confidence
Finding

The README advertises automatic scanning and one-click repair of agent configuration problems but does not warn users that these actions may modify local files, bindings, or team state. In a team-management skill, auto-fix behavior is contextually more dangerous because it likely operates on persistent agent configs and could cause unintended changes, break deployments, or mask destructive behavior behind a convenience feature.

Content

No source excerpt is available for this finding.

Rp1

Medium
Category
MCP Rug Pull
Confidence
70% confidence
Finding

npx commands without a version suffix (e.g. @1.0.0) create a rug-pull risk if the upstream server is compromised and publishes a malicious update.

Content

No source excerpt is available for this finding.

Rp1

Medium
Category
MCP Rug Pull
Confidence
70% confidence
Finding

npx commands without a version suffix (e.g. @1.0.0) create a rug-pull risk if the upstream server is compromised and publishes a malicious update.

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 · README.md (reported line 36)May include surrounding context.

手动安装

bash
mkdir -p ~/.openclaw/skills/team-builder/scripts/
cp scripts/team-builder.sh ~/.openclaw/skills/team-builder/scripts/
cp SKILL.md ~/.openclaw/skills/team-builder/

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
93% confidence
Finding

The README includes a CLI example that passes a bot token directly on the command line without any privacy or secret-handling warning. This is risky because tokens supplied via CLI arguments may be exposed in shell history, process listings, logs, or screenshots, and the skill context increases the danger since channel/binding setup likely grants access to external messaging accounts.

Content

No source excerpt is available for this finding.

Undeclared Tool Scope

Medium
Category
MCP Least Privilege
Confidence
83% confidence
Finding

The skill documents commands that can read environment state and modify local configuration/files, but it declares no explicit tool scope or permission boundaries. That increases the chance an invoking agent can perform broader file or environment access than users expect, especially because the workflow includes write operations, backups, rollback, and gateway restarts.

Content

No source excerpt is available for this finding.

Vague Triggers

Medium
Category
Not specified by scanner
Confidence
93% confidence
Finding

The trigger list includes broad terms like 'channel', '绑定', and common team-related phrases that may match ordinary conversation and invoke a mutating skill unexpectedly. In this context, accidental activation is more dangerous because the skill is designed to add agents, restart services, and request secrets with minimal friction.

Content

No source excerpt is available for this finding.

Autonomous Decision Making

Medium
Category
Excessive Agency
Confidence
85% confidence
Finding

Skill enables autonomous high-impact decisions without human-in-the-loop verification. Critical operations (destructive commands, financial transactions, data deletion) should require explicit user confirmation.

Content

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

md
| `--model` | No | inherit | Model override |
| `--feishu-app-id` | No | - | Feishu bot App ID |
| `--feishu-secret` | No | - | Feishu bot App Secret |
| `--yes` | No | false | Skip confirmation prompts |

### Soul modes

Context-Inappropriate Capability

Medium
Category
Not specified by scanner
Confidence
94% confidence
Finding

The skill instructs the agent to collect Telegram/Discord/Feishu credentials directly in chat and use them to configure external bots, which goes beyond simple team building. Handling third-party secrets materially increases risk of credential exposure, misuse, accidental logging, and unintended control over external messaging accounts.

Content

No source excerpt is available for this finding.

Ssd 3

Medium
Category
Not specified by scanner
Confidence
96% confidence
Finding

The workflow explicitly directs the agent to solicit credentials from the user and later execute commands with them, creating a direct path from conversational disclosure to privileged external integration changes. This is dangerous because chat transcripts are not a safe secret channel, and the agent becomes a broker for sensitive tokens across systems.

Content

No source excerpt is available for this finding.

Description-Behavior Mismatch

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The manifest presents the skill as team management, but the documented behavior also extends into external messaging-channel administration and credential-backed bot binding. This scope expansion is security-relevant because users may invoke the skill for benign org management without realizing it can also alter third-party integrations and consume sensitive secrets.

Content

No source excerpt is available for this finding.

Ssd 3

Medium
Category
Not specified by scanner
Confidence
96% confidence
Finding

The repeated instruction to request channel credentials during channel-configuration reinforces insecure handling patterns and broadens exposure opportunities across multiple platforms. In a skill that can immediately apply those secrets to external services, this materially increases the chance of account takeover or unauthorized bot deployment if credentials are intercepted or mishandled.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
94% confidence
Finding

Rollback in batch mode can delete agents recorded in the manifest, and when --yes or scripted --index is used this occurs without an interactive warning. Because agent deletion is destructive and affects configuration and workspaces, an automated or misrouted invocation could remove agents unexpectedly and cause loss of service or state.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
98% confidence
Finding

The generated SOUL template includes the instruction 永远用中文回复 ('always reply in Chinese'), which imposes a fixed language policy regardless of user preference. This is a natural-language locale constraint and violates the policy unless the skill offers opt-in or clearly justifies the restriction.

Content

No source excerpt is available for this finding.

Description-Behavior Mismatch

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

This team-management skill also manages external channel credentials and bot bindings, including Feishu app secrets and bot tokens. Expanding a team-builder's scope to credentialed channel administration increases blast radius: invoking the skill can alter external integrations, persist secrets into config, and bind agents to messaging endpoints, which is dangerous if triggered by an over-privileged or confused agent.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
87% confidence
Finding

The script stores Feishu appSecret into configuration using openclaw config set, but in --yes or JSON-driven flows this sensitive credential write occurs with no user-facing print, log, comment at point of action, or other disclosure in the execution path. Since the code handles credentials directly, users should be explicitly informed when secrets are being persisted.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
88% confidence
Finding

The batch agent-creation path performs state-changing actions: creating agents, writing config, generating workspace files, updating agent-to-agent permissions, and potentially binding channels, all with little user-facing disclosure in automation mode. In an agentic environment this is risky because a single tool invocation can materially change system topology and trust relationships without a clear approval boundary.

Content

No source excerpt is available for this finding.

Context-Inappropriate Capability

Medium
Category
Not specified by scanner
Confidence
89% confidence
Finding

The health-check and auto-fix paths do more than diagnostics: they enable agentToAgent and expand the allowlist automatically. That changes trust boundaries and permissions under the label of maintenance, which can silently increase inter-agent communication privileges and make unintended lateral action easier after a seemingly harmless check/fix operation.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
81% confidence
Finding

This markdown contains user-facing release notes and trigger/documentation references in Chinese while other entries are in English, with no indication that users may choose their preferred language. The policy category for this audit includes language or locale constraints when they are imposed without opt-in.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
84% confidence
Finding

The natural-language instructions and feature descriptions are written in Chinese throughout the README, which can amount to a language policy constraint if users are not given a choice or informed that the skill is intended for a Chinese-speaking audience. No opt-in, alternative language, or documented locale justification is provided in the file.

Content

No source excerpt is available for this finding.

Intent-Code Divergence

Low
Category
Not specified by scanner
Confidence
98% confidence
Finding

Line L168 says the script binds a newly created agent to all enabled channels, implying complete automatic channel setup. But the subsequent workflow immediately checks for missing channels and asks the user for Telegram/Discord/Feishu credentials, which contradicts the claim of universal automatic binding.

Content

No source excerpt is available for this finding.

Static analysis

No suspicious patterns detected.