Back to skill

Security audit

ClawBrain Pro

Security checks for vulnerabilities and agentic risk

Overview

This skill is not clearly malicious, but it routes users to a third-party model and memory service while enabling broad automation, persistent memory, shell dispatch, and dependency installation guidance without enough scoping or consent controls.

Install only if you are comfortable sending prompts, possible memory content, and diagnostic metadata to the ClawBrain/factorhub service. Use a scoped API key, avoid sensitive conversations unless retention controls are clear, and do not allow benchmark, doctor, or retry flows to run shell commands or install dependencies without reviewing the exact action first.

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 (2)

T09 · Insecure Skill Coding Practices

Error
Location
skills/benchmark/SKILL.md:5
Finding

Unrestricted General-Purpose Shell Dispatch

Content
View full analysis

Vulnerability Details

File Location: skills/benchmark/SKILL.md:5-7 and skills/doctor/SKILL.md:5-7
Vulnerability Type: Unrestricted command execution configuration
Risk Level: High

Vulnerable Code

skills/benchmark/SKILL.md:1-8:

yaml
---
name: clawbrain-pro-benchmark
description: Tests OpenClaw across 205 realistic scenarios and compares its performance with the ClawBrain v1.0 orchestration engine
user-invocable: true
command-dispatch: tool
command-tool: exec
metadata: {"openclaw": {"emoji": "📊", "requires": {"bins": ["curl"]}}}
---

skills/doctor/SKILL.md:1-8:

yaml
---
name: clawbrain-pro-doctor
description: Diagnoses OpenClaw configuration and runtime health
user-invocable: true
command-dispatch: tool
command-tool: exec
metadata: {"openclaw": {"emoji": "🩺", "requires": {"bins": ["curl"]}}}
---

Technical Analysis

Both user-invocable skills dispatch directly to the general-purpose exec tool. Neither file specifies a fixed executable, bundled diagnostic script, command allowlist, argument schema, validation procedure, or shell metacharacter filtering.

This violates least-functionality principles: benchmark and health-check operations only require a small, predetermined set of read-only commands, but the configuration exposes a general shell execution interface. If OpenClaw forwards invocation text or generated arguments to exec, crafted input could alter the intended command through shell metacharacters, command substitution, pipes, redirection, or additional arguments.

The package does not include implementation code proving exactly how the framework constructs the final command. Exploitability therefore depends on OpenClaw's command-dispatch semantics and any validation performed outside this package. Nevertheless, exposing exec without a constrained command definition creates a dangerous execution boundary.

Attack Path

  1. An attack ...[truncated 1069 chars]
Remediation
View remediation

Remediation Suggestions

  1. Remove command-dispatch: tool and command-tool: exec if these skills are intended only to provide documentation.
  2. Replace general-purpose execution with a bundled, reviewed script that performs only the required read-only checks.
  3. Invoke executables directly through an argument-array API rather than through a shell.
  4. Define an explicit command and argument allowlist; reject unknown options and positional arguments.
  5. Do not accept shell metacharacters, redirection operators, command substitution, or arbitrary environment-variable assignments.
  6. Run diagnostics under a dedicated low-privilege account with restricted filesystem and network access.
  7. Avoid exposing environment secrets to the diagnostic process.
  8. Add tests proving that inputs containing ;, |, &&, backticks, $(), newlines, and redirection cannot alter command execution.
  9. Apply the same correction to skills/doctor/SKILL.md:5-7.

T08 · Insecure Dependencies

Error
Location
skills/smart-retry/SKILL.md:28
Finding

Automatic Installation and Execution of Unverified Dependencies

Content
View full analysis

Vulnerability Details

File Location: skills/smart-retry/SKILL.md:28-35
Vulnerability Type: Unsafe dependency acquisition and execution policy
Risk Level: High

Vulnerable Code

The relevant instructions state:

markdown
### Level One: Intelligent Retry
**File not found** → Use the `ls` command to locate the correct filename, then retry

**Command unavailable** → Try an alternative command (`python` → `python3`, `pip` → `pip3`)

**Missing dependency** → Install it first, then execute

**Insufficient permissions** → Do not force execution; inform the user which permissions are required

Technical Analysis

The retry policy directs the Agent to install missing dependencies and then execute the task. It does not require explicit user authorization, restrict permitted package registries, pin package names and versions, validate integrity hashes, inspect installation scripts, or use an isolated environment.

Automated package-name selection is particularly dangerous because package managers commonly execute lifecycle hooks or installation code. An attacker can reference a nonexistent, typo-squatted, dependency-confusion, or otherwise malicious package in a task. The Agent may interpret the resulting import or command error as a missing dependency, install the attacker's package, and subsequently execute it.

The instruction is guidance rather than an included installer implementation, so exploitation requires an Agent that follows the skill's retry directions and possesses package-installation or command-execution capability.

Attack Path

  1. An attacker submits a task containing code or commands that reference an attacker-controlled or deliberately misspelled package name.
  2. Initial execution fails because the named dependency is unavailable locally.
  3. The smart-retry instructions classify the failure as a missing dependency.
  4. The Agent invokes a package manager and retrieves the packag ...[truncated 987 chars]
Remediation
View remediation

Remediation Suggestions

  1. Replace automatic installation with a proposal-and-approval workflow that identifies the exact package, version, source, and reason before installation.
  2. Permit installation only from explicitly allowlisted registries and trusted namespaces.
  3. Pin exact versions and verify package integrity through lockfiles, cryptographic hashes, or signed provenance.
  4. Reject inferred package names unless they are mapped through a reviewed dependency manifest.
  5. Detect common typosquatting and dependency-confusion conditions, including unexpected public packages that overlap with internal names.
  6. Disable or sandbox package installation hooks where supported.
  7. Install dependencies in a disposable, network-restricted, unprivileged virtual environment or container.
  8. Separate installation from execution and scan newly acquired components before importing or launching them.
  9. Record dependency installation decisions and surface them clearly to the user.
  10. Never use elevated privileges or global installation as an automatic recovery action.
Vulnerability Patterns
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Trigger AbuseOverly Broad Trigger, Shadow Command Trigger, Keyword Baiting Trigger
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
  • Supply ChainUnpinned Dependencies, External Script Fetching, Obfuscated Code
Findings (21)

Missing User Warnings

High
Category
Not specified by scanner
Confidence
95% confidence
Finding

The skill advertises automatic extraction of structured memory, identity updates, source-linked conversation retention, and daily background consolidation without any visible consent flow, retention limits, or privacy warning. This creates a real privacy and safety risk because users may unknowingly have sensitive personal or organizational data persistently profiled, linked, and reused across sessions.

Content

No source excerpt is available for this finding.

Missing User Warnings

High
Category
Not specified by scanner
Confidence
98% confidence
Finding

The metadata/description advertises automatic long-term memory but does not warn users that conversation data may be retained across sessions and viewed or managed through an external dashboard/service. This creates a meaningful privacy and data-governance risk because users may disclose sensitive personal or business information without realizing it is being persistently stored outside the immediate chat context.

Content

No source excerpt is available for this finding.

Vague Triggers

Medium
Category
Not specified by scanner
Confidence
94% confidence
Finding

The skill advertises broad, ambiguous triggers such as handling vague requests and automatically planning/executing multi-step tasks without defining clear activation boundaries or requiring explicit user confirmation. In an agent context, this can cause unintended autonomous actions, tool use, or overreach beyond what the user actually requested, increasing the chance of unsafe side effects.

Content

No source excerpt is available for this finding.

External Transmission

Medium
Category
Data Exfiltration
Confidence
88% confidence
Finding

The skill instructs users to configure a third-party API endpoint (api.factorhub.cn) and supply an API key, which enables external transmission of prompts and potentially sensitive user data to infrastructure outside the default environment. In a skill claiming memory, long-context handling, and cross-session preference retention, the data exposure risk is elevated because users may send personal, project, or confidential information to an external service.

Content

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

md
"models": {
    "providers": {
      "clawbrain": {
        "baseUrl": "https://api.factorhub.cn/v1",
        "apiKey": "你的 API Key",
        "api": "openai-completions",
        "models": [

Vague Triggers

Medium
Category
Not specified by scanner
Confidence
94% confidence
Finding

The trigger phrases are generic enough that ordinary user requests like '跑一下 benchmark' or '测试一下模型效果' could invoke this skill unintentionally. Because the skill dispatches to an exec tool and describes broad real-world testing across file, terminal, and messaging scenarios, accidental activation could cause unintended actions or system-state changes.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
94% confidence
Finding

The skill markets benchmark coverage across file operations, messaging, terminal control, and multi-step tasks, but provides no warning that running the benchmark may read/write files, send messages, fetch web content, or modify system state. In context, this omission is more dangerous because the skill is user-invocable and uses the exec command tool, increasing the chance that a user launches impactful actions without informed consent.

Content

No source excerpt is available for this finding.

Vague Triggers

Medium
Category
Not specified by scanner
Confidence
89% confidence
Finding

The description uses broad promotional language ('一键让 OpenClaw 更准更稳') without clearly constraining when the skill should activate. In agent ecosystems, ambiguous invocation text can cause the skill to match ordinary requests unexpectedly, leading to unintended routing to this skill and application of its behavior or external provider configuration.

Content

No source excerpt is available for this finding.

Vague Triggers

Medium
Category
Not specified by scanner
Confidence
86% confidence
Finding

The heading/body repeats marketing-style activation wording ('一键让你的 OpenClaw 更准、更稳、越用越懂你') that is not tied to a specific task. This increases the chance the skill is auto-selected for unrelated conversations because the language overlaps with common user goals like wanting better answers or more stable performance.

Content

No source excerpt is available for this finding.

External Transmission

Medium
Category
Data Exfiltration
Confidence
74% confidence
Finding

The skill instructs users to configure an external API endpoint at api.factorhub.cn, which means conversation content and prompts may be transmitted to a third-party service. External transmission is expected for an LLM provider, but it remains a security-relevant issue because the skill does not include any trust, data handling, or jurisdiction/privacy disclosure for that endpoint.

Content

Scanner excerpt · skills/clawbrain-boost/SKILL.md (reported line 69)May include surrounding context.

md
"models": {
    "providers": {
      "clawbrain": {
        "baseUrl": "https://api.factorhub.cn/v1",
        "apiKey": "你的 API Key",
        "api": "openai-completions",
        "models": [

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
93% confidence
Finding

The natural-language content presents the skill entirely in Chinese, including the description and invocation examples, without offering a language choice or documenting that the skill is intended only for a Chinese-speaking context. This can violate language or locale policy when a specific language is imposed without user opt-in.

Content

No source excerpt is available for this finding.

Vague Triggers

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The invocation guidance says users can say “诊断一下” or “检查配置”, which are generic phrases that could easily appear in ordinary troubleshooting conversation. The file does not provide scope limits, exclusions, or negative examples to clarify when these phrases should activate this specific skill versus general assistant behavior.

Content

No source excerpt is available for this finding.

External Transmission

Medium
Category
Data Exfiltration
Confidence
90% confidence
Finding

This command sends an authenticated request to an external service endpoint using a bearer token, which creates a real data transmission path outside the local environment. Even if intended for health checks, it can disclose operational metadata and encourages users to use sensitive credentials in manual commands without any safety guidance.

Content

Scanner excerpt · skills/doctor/SKILL.md (reported line 84)May include surrounding context.

bash
# 检查后端模型健康状态
curl https://api.factorhub.cn/v1/health/backends -H "Authorization: Bearer YOUR_KEY"

# 检查知识图谱状态
curl https://api.factorhub.cn/v1/graph/stats -H "Authorization: Bearer YOUR_KEY"

External Transmission

Medium
Category
Data Exfiltration
Confidence
90% confidence
Finding

This endpoint queries knowledge graph statistics over an authenticated external connection, potentially exposing internal memory/graph structure and deployment metadata to a third-party service. In the context of a diagnostic skill focused on memory and graph health, the data may be more sensitive than a generic status check.

Content

Scanner excerpt · skills/doctor/SKILL.md (reported line 87)May include surrounding context.

md
curl https://api.factorhub.cn/v1/health/backends -H "Authorization: Bearer YOUR_KEY"

# 检查知识图谱状态
curl https://api.factorhub.cn/v1/graph/stats -H "Authorization: Bearer YOUR_KEY"

# 检查模型列表和能力
curl https://api.factorhub.cn/v1/models -H "Authorization: Bearer YOUR_KEY"

External Transmission

Medium
Category
Data Exfiltration
Confidence
88% confidence
Finding

Requesting model lists and capabilities from an external service with bearer authentication can reveal system configuration and available backend capabilities. While not inherently malicious, embedding such commands in the skill without caution normalizes external authenticated calls and can leak sensitive operational details.

Content

Scanner excerpt · skills/doctor/SKILL.md (reported line 90)May include surrounding context.

curl https://api.factorhub.cn/v1/graph/stats -H "Authorization: Bearer YOUR_KEY"

检查模型列表和能力

curl https://api.factorhub.cn/v1/models -H "Authorization: Bearer YOUR_KEY"

text

接入 ClawBrain:https://clawbrain.dev/dashboard

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
80% confidence
Finding

Substantive user-facing content is presented in Chinese, including the description and usage guidance, while the file does not state that the skill is region-specific or offer a language choice. This can violate language/locale policy when a skill imposes a specific language without user opt-in.

Content

No source excerpt is available for this finding.

Vague Triggers

Medium
Category
Not specified by scanner
Confidence
93% confidence
Finding

The activation examples are broad, generic recall phrases and the skill is marked auto-effective ('安装后自动生效'), which can cause the system to invoke long-term memory handling in ordinary conversation without clear, informed user consent. In a memory skill, ambiguous triggering increases the chance that sensitive conversation content is retrieved, stored, or surfaced unexpectedly.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
78% confidence
Finding

The manifest description and all user-facing instructions are written only in Chinese, with no indication that users may choose another language or that the skill is region-specific. This can constitute a language/locale policy issue when the skill implicitly enforces one language without user opt-in.

Content

No source excerpt is available for this finding.

Vague Triggers

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The trigger phrases are broad, natural-language patterns that can easily appear in ordinary conversation, so the skill may invoke recall when the user did not explicitly intend a memory lookup. In a memory-retrieval context, unintended activation can expose prior conversation content or influence responses with stale or sensitive history, making this a real security/privacy concern rather than a purely UX issue.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
87% confidence
Finding

The manifest description and the body of the skill are entirely in Chinese, including user-facing guidance such as the activation description and operational explanations. There is no indication that the skill is region-specific or that users may opt into another language, which creates a natural-language locale policy concern.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
81% confidence
Finding

The entire skill description and instructions are presented only in Chinese, with no indication that users may choose another language or locale. Under the language/locale policy, a skill should not implicitly force a specific language unless the constraint is documented and justified or the user is given a choice.

Content

No source excerpt is available for this finding.

Missing User Warnings

Low
Category
Not specified by scanner
Confidence
91% confidence
Finding

The skill includes authenticated curl commands to a third-party domain using a bearer token placeholder, but does not warn users about credential handling, endpoint trust, or possible exposure of environment, model, or graph metadata. In a diagnostic skill, users may be encouraged to paste real tokens into shell history or run commands against external infrastructure without understanding the sensitivity of the returned data.

Content

No source excerpt is available for this finding.

Static analysis

No suspicious patterns detected.