Back to skill

Security audit

Skill Engineer

Security checks for vulnerabilities and agentic risk

Overview

This skill is a disclosed skill-building workflow helper, but it also asks agents to use broad private memory, unpinned external tooling, scheduled follow-up jobs, and repository pushes.

Review this skill before installing. Use it only in a dedicated workspace, avoid enabling broad memory search unless you explicitly need prior-session context, verify any DeepWiki dependency before running it, and do not allow cron jobs, git commits, or remote pushes unless you have reviewed the exact diff and destination.

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 DependenciesIntroduces malicious components through unsafe dependency sources
  • 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 (5)

T05 · Unauthorized Access and Privilege Escalation

Error
Location
SKILL.md:55
Finding
Mandatory Broad Access to Persistent Session History and Private Memory<![CDATA[ ## Vulnerability Details **File Location**: `SKILL.md`, lines 55-104 **Vulnerability Type**: Excessive access to persistent memory and unrelated historical data **Risk Level**: High ### Vulnerable Code ```markdown | Vector memory DB | OpenClaw feature | Semantic search across session history, notes, and memory files | Enable in `openclaw.json` (`memory.enabled: true`) | **Before starting any skill design or update session, verify both are available:** ```bash # Check vector memory (should return results, not empty) # Use the memory_search tool with a known topic from recent sessions ``` ## Memory Search Protocol (MANDATORY) Before searching files manually, always query the vector memory database first. It indexes session history, Obsidian notes, and memory files — and finds cross-document connections that manual search misses. **How to query correctly:** ``` memory_search("your query here", maxResults=5) ``` **Critical rule: try multiple queries before giving up.** ``` ### Technical Analysis The Skill makes persistent-memory access a mandatory prerequisite for design and update operations. That database may contain unrelated session history, private notes, configuration details, organizational information, and prior user data. The core declared operation—designing, reviewing, and testing a target Skill—normally requires only the target artifact directory and requirements supplied for the current task. Searching persistent memory by default violates least privilege because it broadens the readable data scope without demonstrating that the additional information is necessary. Repeatedly rephrasing failed searches further increases the chance that semantically related but unrelated confidential records will be retrieved. Retrieved records may subsequently be incorporated into Designer prompts, subagent context, generated documentation, review reports, or external DeepWiki questions. ### Attack Path 1. A user requests creation, maintenance, or ...[truncated 1134 chars]
Remediation
<![CDATA[ ## Remediation Suggestions 1. Remove persistent-memory access as a mandatory dependency. 2. Default to user-provided requirements and files inside the explicitly selected target directory. 3. Require explicit user authorization before searching session history, notes, or memory. 4. Show the intended search scope and query to the user before execution. 5. Restrict searches to project identifiers or memory namespaces selected by the user. 6. Do not automatically retry with broader or semantically different queries. 7. Treat retrieved memory as sensitive and prevent it from being included in external queries, Git commits, generated public documentation, or subagent prompts unless separately approved. 8. Add provenance labels to retrieved records so reviewers can detect when generated content came from persistent memory. ]]>

T08 · Insecure Dependencies

Error
Location
SKILL.md:55
Finding
Unpinned Third-Party DeepWiki Dependency Is Installed and Executed<![CDATA[ ## Vulnerability Details **File Location**: `SKILL.md`, lines 55-76 and 108-132 **Vulnerability Type**: Unverified third-party executable dependency and external query channel **Risk Level**: High ### Vulnerable Code ```markdown | Dependency | Type | Purpose | Install from | |------------|------|---------|-------------| | `deepwiki` | Skill | Query OpenClaw source for current API behavior | `liaosvcaf/openclaw-skill-deepwiki` | # Check deepwiki ls ~/.openclaw/skills/deepwiki/deepwiki.sh || ls ~/.openclaw/workspace-*/skills/deepwiki/deepwiki.sh If deepwiki is missing, install from `liaosvcaf/openclaw-skill-deepwiki`. ``` ```bash # Query DeepWiki for current behavior ~/.openclaw/skills/deepwiki/deepwiki.sh ask openclaw/openclaw "YOUR QUESTION" ``` ```markdown **ALWAYS query DeepWiki when:** - Designing a skill that uses `sessions_spawn`, tool calls, or OpenClaw-specific APIs - Referencing skill frontmatter fields or loading precedence - Updating an existing skill that has version-tagged sections - The installed OpenClaw version differs from any version tag in the skill - You are unsure whether an API, field, or behavior still exists ``` ### Technical Analysis The Skill instructs the Agent to install and execute a third-party Skill identified only by a mutable repository or package name. No reviewed commit, immutable version, cryptographic checksum, signature, provenance requirement, or approved source policy is specified. The dependency exposes an executable shell entry point, `deepwiki.sh`. Consequently, compromise of the upstream repository, its distribution channel, or the locally installed copy could cause arbitrary commands to run with the same filesystem and network privileges as the invoking Agent. The query mechanism also creates an outbound data channel. Although the documented purpose is to ask questions about OpenClaw behavior, the Skill does not prohibit including proprietary requirements, source excerpts, internal paths, or informa ...[truncated 1224 chars]
Remediation
<![CDATA[ ## Remediation Suggestions 1. Pin the dependency to a reviewed immutable commit or signed release. 2. Publish and verify a cryptographic checksum before installation and execution. 3. Document the exact distribution source, network endpoints, ownership, and data-retention policy. 4. Require explicit user approval before installing or updating the dependency. 5. Execute the integration with minimal filesystem access, restricted environment variables, and constrained network permissions. 6. Sanitize external questions and prohibit inclusion of secrets, private source code, internal URLs, local paths, persistent-memory results, and user data. 7. Provide an offline fallback using locally installed OpenClaw documentation or source. 8. Make DeepWiki optional rather than a mandatory dependency for unrelated design and review tasks. 9. Revalidate the installed executable before each upgrade rather than automatically trusting a mutable local path. ]]>

T06 · System Persistence

Error
Location
SKILL.md:366
Finding
Workflow Registers Scheduled Jobs Without a Defined Cleanup Mechanism<![CDATA[ ## Vulnerability Details **File Location**: `SKILL.md`, lines 366-375 **Vulnerability Type**: Cross-session scheduled-task persistence **Risk Level**: High ### Vulnerable Code ```markdown ### Fallback: Director-Only with Cron Safety Net If `maxSpawnDepth: 2` is not configured, use Director-only mode but add a cron safety net after each subagent spawn: ``` After spawning Designer, register a cron job: "Check if Designer has completed (look for output at /path/to/skill/SKILL.md). If completed and Reviewer not yet started, spawn Reviewer now." (fires 15 minutes after spawn) ``` This mitigates but does not eliminate the announce-to-action gap. ``` ### Technical Analysis The Skill directs the Agent to register a cron job that can reactivate the workflow after the current execution context has changed or ended. The instructions do not define: - The exact one-shot scheduling mechanism - Automatic removal after execution - Cancellation when the user stops the task - A unique task identifier - Ownership and collision handling - An expiration deadline - Validation that the target path still refers to the authorized project - A requirement for explicit user consent A scheduled task can therefore outlive the original Skill run and initiate additional Agent operations later. Checking only for the existence of a predictable output path is also insufficient proof that the original authorized Designer completed the expected work. ### Attack Path 1. A design workflow runs without nested subagent support. 2. The Skill registers the prescribed cron safety-net job. 3. The current session is interrupted, canceled, or completed without deleting the job. 4. The expected path is later created or changed, either legitimately or by another process. 5. The scheduled job observes the path and spawns a Reviewer. 6. The workflow resumes and consumes resources or accesses artifacts without fresh user authorization. ### Impact Assessment The scheduled task can persist b ...[truncated 463 chars]
Remediation
<![CDATA[ ## Remediation Suggestions 1. Remove cron-based continuation and keep orchestration within a bounded active session. 2. If scheduling is unavoidable, require explicit user approval before registration. 3. Use a one-shot scheduler entry that deletes itself regardless of success or failure. 4. Assign an unpredictable task identifier and bind it to the initiating session. 5. Validate an authenticated completion record rather than checking only for file existence. 6. Define an absolute expiration time and a maximum number of executions. 7. Remove the task immediately when the workflow completes, fails, times out, or is canceled. 8. Provide a documented command for listing and canceling all jobs created by the Skill. 9. Prevent a scheduled continuation from committing, pushing, or spawning additional workers without renewed authorization. ]]>

T05 · Unauthorized Access and Privilege Escalation

Error
Location
SKILL.md:458
Finding
Repository-Wide Staging and Automatic Push Can Exfiltrate Unrelated Files<![CDATA[ ## Vulnerability Details **File Location**: `SKILL.md`, lines 458-479 **Vulnerability Type**: Overbroad repository modification and unauthorized network publication **Risk Level**: Critical ### Vulnerable Code ```markdown ### Version Control The orchestrator manages git commits throughout the workflow: **When to commit:** - After Designer produces initial artifacts (iteration 1): `git add . && git commit -m "feat: initial design for <skill-name>"` - After Designer revisions (iteration 2+): `git add . && git commit -m "fix: address review issues (iteration N)"` - After Tester passes and before ship: `git add README.md && git commit -m "docs: add quality scorecard for <skill-name>"` **When to push:** - After final ship (all gates passed): `git push origin main` - Do NOT push intermediate iterations — only ship-ready artifacts **Branch strategy:** - Work in main branch for routine skill development - Use feature branches for experimental or breaking changes ``` ```markdown | **Git push fails** | Exit code ≠ 0 | Retry once. If fails again, report to user: "Cannot push to remote. Check network/permissions." | ``` The behavior conflicts with the declared boundaries in `SKILL.md`, lines 145-150: ```markdown ### What This Skill Does NOT Handle - **Release pipeline** — publishing, versioning, changelogs belong to release processes - **Repository management** — git submodules, repo creation, branch strategy belong to your VCS workflow - **Deployment** — installing skills to agents, configuration management ``` ### Technical Analysis `git add .` stages every unignored modification under the current Git working tree, not only files generated by this Skill. If the repository contains unrelated source changes, private notes, configuration files, build artifacts, or newly created sensitive files, those items can be included in the commit. The workflow then directs the Agent to push directly to `origin main`. It does not require: - User confirmation - Ver ...[truncated 2182 chars]
Remediation
<![CDATA[ ## Remediation Suggestions 1. Remove committing and pushing from the default workflow because repository management is explicitly outside the declared scope. 2. Require explicit, informed user confirmation immediately before every commit and push. 3. Determine and display the repository root and remote URL before proceeding. 4. Refuse automatic publication if the remote owner or destination has not been approved. 5. Replace `git add .` with an explicit allowlist of generated artifact paths. 6. Run `git status --short` and `git diff --cached` and present the complete staged diff for approval. 7. Scan staged content for secrets, credentials, private keys, tokens, internal URLs, and sensitive paths. 8. Use a dedicated feature branch and pull request instead of pushing directly to `main`. 9. Never retry a network push without renewed confirmation. 10. Abort if unrelated changes existed before the Skill started. 11. Record the initial Git status and verify that only expected files changed. 12. Separate release automation into a different, explicitly invoked Skill with narrowly scoped permissions. ]]>

T05 · Unauthorized Access and Privilege Escalation

Warning
Location
SKILL.md:350
Finding
Global Nested-Subagent Configuration Expands Delegation Privileges<![CDATA[ ## Vulnerability Details **File Location**: `SKILL.md`, lines 350-358 **Vulnerability Type**: Global capability expansion beyond task-scoped requirements **Risk Level**: Medium ### Vulnerable Code ```markdown **Required config (add to `openclaw.json` before using this pattern):** ```json { "agents": { "defaults": { "subagents": { "maxSpawnDepth": 2 } } } } ``` ``` Related behavior is described at `SKILL.md`, lines 220-241: ```markdown Director (user-facing, depth 0) └── Orchestrator (pipeline owner, depth 1) ├─ Spawn ──→ Designer (depth 2) ├─ Spawn ──→ Reviewer (depth 2) └─ Spawn ──→ Tester (depth 2) ``` ### Technical Analysis The Skill recommends changing the default OpenClaw configuration to permit depth-two subagent spawning. A default-level setting may apply to agents beyond the current design workflow, thereby expanding delegation capability system-wide rather than granting it only to a dedicated orchestrator. Nested spawning increases the number of execution contexts that can be created and makes permission propagation, resource accounting, and auditability more complex. If another loaded Skill or subagent is compromised, it may take advantage of the increased spawn depth even though the configuration change was introduced only for `skill-engineer`. The Skill specifies timeouts for example workers, but it does not provide controls ensuring that all agents affected by the global default are constrained by those limits. ### Attack Path 1. An operator changes `openclaw.json` as instructed. 2. The default maximum spawn depth becomes two. 3. Another Skill, Agent, or untrusted delegated task runs under the modified defaults. 4. That component creates nested subagents that were previously prohibited. 5. The nested workers consume resources or perform additional file, memory, tool, and network operations within their inherited capabilities. ### Impact Assessment The configuration change may expand subagent creati ...[truncated 576 chars]
Remediation
<![CDATA[ ## Remediation Suggestions 1. Keep the default maximum spawn depth unchanged. 2. Apply depth-two spawning only to a dedicated orchestrator identity or isolated task profile. 3. Require administrator approval before changing shared OpenClaw configuration. 4. Set strict per-agent limits for active children, total workers, execution time, token consumption, tool access, and network access. 5. Ensure nested workers receive only the target artifact directory and minimum required tools. 6. Restore the original configuration automatically when a temporary profile is no longer needed. 7. Log every nested spawn with parent identity, task identifier, granted tools, and timeout. 8. Provide a safe Director-only mode that does not rely on either global privilege expansion or persistent cron jobs. ]]>
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)

Tp4

High
Category
MCP Tool Poisoning
Confidence
98% confidence
Finding
The declared description presents a broad multi-agent system for skill design and quality assurance, involving Designer, Reviewer, and Tester subagents. The actual code is a simple shell utility that validates the presence of expected files in a skill directory. While this could be a small supporting check within a larger skill-maintenance workflow, the supplied code chunk itself does not implement the declared primary purpose and instead has a materially narrower and different function. Therefore, this is a clear description-behavior mismatch.

Tp4

High
Category
MCP Tool Poisoning
Confidence
99% confidence
Finding
The declared description presents a broad multi-agent quality-gated skill engineering capability, including orchestration of Designer, Reviewer, and Tester subagents for designing, reviewing, testing, auditing, and refactoring skills. The supplied code does none of that. It is a narrowly scoped validation utility that counts rubric check rows in a SKILL.md file and verifies the total equals 33. This is not a supporting implementation detail of the declared behavior; it is a materially different and much narrower function. There are no undeclared dangerous permissions, but the primary purpose and capabilities are clearly mismatched.

Tp4

High
Category
MCP Tool Poisoning
Confidence
98% confidence
Finding
The declared description presents a comprehensive skill-engineering system that orchestrates multiple subagents for iterative refinement and quality-gated development of OpenClaw skills. The supplied code does none of that. It is a single-purpose scoring script: it reads rubric markdown files from disk, extracts criterion scores with regex, computes totals/percentages/ratings, and prints JSON (plus optional pretty summaries). While this may support auditing workflows, it is only a narrow reporting utility and not the described designer/reviewer/tester orchestration capability. Therefore the description materially misrepresents the code chunk’s actual primary purpose and capabilities.

Tp4

High
Category
MCP Tool Poisoning
Confidence
99% confidence
Finding
The declared description says this skill orchestrates multiple subagents for iterative skill development and quality-gated review/testing of OpenClaw agent skills. The supplied code does nothing of that sort. It is a narrow shell utility that reads a README file, finds a 'Quality Scorecard' section, parses numeric scores, checks whether their sum matches the stated total, and exits accordingly. This is a materially different primary purpose and capability set from the declared description, so it should be flagged as a mismatch.

Tp4

High
Category
MCP Tool Poisoning
Confidence
99% confidence
Finding
The declared description describes a broad agent skill engineering system with iterative refinement and orchestration of Designer, Reviewer, and Tester subagents. The supplied code instead is a narrow utility script for validating trigger definitions and trigger test coverage in a skill directory. It performs file existence checks, parses YAML-like trigger entries, reads JSON test cases, checks minimum counts, warns about uncovered triggers, and reports pass/fail. This is materially different from the declared primary purpose and lacks the advertised capabilities, so it should be flagged as a mismatch.

Description-Behavior Mismatch

High
Confidence
97% confidence
Finding
The skill explicitly claims repository management and release pipeline work are out of scope, then later instructs the agent to perform git commits, pushes, and branch-strategy decisions. This contradiction is dangerous because it can bypass user expectations and lead an autonomous agent to mutate and publish repository state despite earlier assurances that it would not do so.

Self-Modification

High
Category
Rogue Agent
Content
## Orchestrator Responsibilities

The Orchestrator (depth-1 subagent in Mode B, or main agent in fallback mode) owns the Design→Review→Test loop. It does NOT write skill content or evaluate quality — it only coordinates.

1. **Query DeepWiki** for any OpenClaw-specific topics in the requirements (if Director hasn't already)
2. **Spawn Designer** with requirements, DeepWiki findings, and any prior feedback
Confidence
85% confidence
Finding
Skill modifies its own code, configuration, or behavior at runtime. Self-modification enables an agent to escalate privileges, disable safety constraints, or install persistent backdoors.

Ae1

High
Category
analysis-evasion
Content
A skill is a **directory** containing at minimum a `SKILL.md` file:
Confidence
100% confidence
Finding
Referenced artifact was not completely inspected

Ae1

High
Category
analysis-evasion
Content
A skill is a **directory** containing at minimum a `SKILL.md` file:
Confidence
100% confidence
Finding
Referenced artifact was not completely inspected

Ae1

High
Category
analysis-evasion
Content
A skill is a **directory** containing at minimum a `SKILL.md` file:
Confidence
100% confidence
Finding
Referenced artifact was not completely inspected

Context-Inappropriate Capability

High
Confidence
95% confidence
Finding
Adding GitHub and registry publishing capabilities extends the skill into remote-side effects unrelated to its core design/review/test purpose. In skill context this is more dangerous because users may invoke it expecting local artifact preparation, while the skill is also equipped to create repos or publish packages externally.

Self-Modification

High
Category
Rogue Agent
Content
5. Map data flow between steps
6. Plan for error handling at each step

### Step 4: Write SKILL.md

**A. YAML Frontmatter**
Confidence
85% confidence
Finding
Skill modifies its own code, configuration, or behavior at runtime. Self-modification enables an agent to escalate privileges, disable safety constraints, or install persistent backdoors.

Lp3

Medium
Category
MCP Least Privilege
Confidence
74% confidence
Finding
The skill instructs extensive filesystem inspection, shell command execution, git operations, and subagent orchestration, but it declares no explicit tool scope or allowed-tools boundary. In an agent skill, missing capability constraints increases the chance the skill is invoked with broader-than-necessary authority and can perform unintended local actions during normal use.

Intent-Code Divergence

Medium
Confidence
91% confidence
Finding
The file repeatedly defines review success in terms of 33 checks and a passing threshold of 28/33, but the 'Every shipped skill' scorecard example totals 29/30. This is not mere omission; it provides a concrete output template inconsistent with the actual scoring model described elsewhere, which could mislead implementers and auditors.

Missing User Warnings

Medium
Confidence
91% confidence
Finding
The skill directs `git push origin main` without an explicit user-facing warning or confirmation gate. In an autonomous agent setting, silently pushing to a remote repository can leak sensitive changes, overwrite shared state, or trigger CI/CD workflows, making this materially risky.

Description-Behavior Mismatch

Medium
Confidence
93% confidence
Finding
The Configuration section says 'No persistent configuration required,' yet the skill elsewhere requires vector memory enabled in openclaw.json, DeepWiki installed, and even lists gh and clawhub CLIs as requirements. That is an active contradiction in operational behavior: the skill does rely on environment and configuration prerequisites.

Missing User Warnings

Medium
Confidence
96% confidence
Finding
The rubric explicitly instructs reviewers to execute repository-provided shell scripts, which creates a trust-boundary violation: a reviewer may run untrusted code from the skill package or local installation without prior inspection or sandboxing. In the context of agent skills, where content must be treated as potentially adversarial, this can lead to arbitrary command execution, data exfiltration, or host modification on the review environment.

Vague Triggers

Medium
Confidence
95% confidence
Finding
The trigger list includes several broad, natural-language phrases such as 'review skill', 'test skill', and 'evaluate skill' that can plausibly appear in ordinary discussion, increasing the chance of unintended activation. Because this skill orchestrates lifecycle actions over other skills, accidental invocation could cause unnecessary analysis, workflow hijacking, or confusing agent behavior even without malicious intent.

Vague Triggers

Medium
Confidence
91% confidence
Finding
Several trigger examples in this range are ambiguous about scope, including phrases like "validate skill structure," "build agent skill," and "maintain the skill lifecycle." These can overlap with general consulting or engineering language, increasing the chance of accidental activation, routing confusion, and unintended invocation of a powerful orchestration skill that can review, test, and modify other skills.

Vague Triggers

Medium
Confidence
95% confidence
Finding
The trigger phrase at line 11, "help me design a skill", is broad enough to match ordinary user requests that may not specifically intend to invoke this skill. In an agent-routing context, overly generic triggers can cause misfires, unintended delegation, or interception of requests better handled by other skills, reducing reliability and potentially exposing broader skill capabilities than the user intended.

Missing User Warnings

Low
Confidence
75% confidence
Finding
The cron safety-net guidance introduces persistent background behavior and local file inspection without clearly surfacing those side effects. While lower impact than remote pushes, hidden scheduled checks can surprise users, consume resources, and create unintended monitoring of workspace contents.

Intent-Code Divergence

Low
Confidence
90% confidence
Finding
The rubric's stated review intent includes checking that artifacts contain no hardcoded paths, org names, or private/internal details, yet it documents the internal path `/tmp/openclaw-skill-skill-engineer/scripts/` as the expected script location. That is a direct contradiction between the document's operational guidance and its own stated OPSEC-style standard, not merely an omission.

Static analysis

No suspicious patterns detected.