Back to skill

Security audit

3steps To Wisdom

Security checks for vulnerabilities and agentic risk

Overview

This skill is mostly a communication framework, but it makes the agent run a bundled license-check script and gate responses before showing the content.

Install only if you are comfortable with the agent being instructed to run a bundled Python script that reads local OpenClaw license metadata before showing the skill. Prefer a version where licensing is enforced by the platform, not by natural-language skill instructions, and where the response format is optional or user-directed.

Vulnerability Patterns
  • 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
  • Embedded Malicious CodeShips malicious scripts inside the skill and executes them locally
  • Unauthorized Access and Privilege EscalationObtains permissions beyond the task's legitimate needs
Findings (1)

T01 · Skill Instruction Hijacking

Warning
Location
SKILL.md:3
Finding

Mandatory License Gate and Response-Format Instructions Override Agent Behavior

Content
View full analysis

Vulnerability Details

File Location: SKILL.md, lines 3–6 and 47–50
Vulnerability Type: T01: Skill Instruction Hijacking
Risk Level: Medium

Vulnerable Code Snippets

Faithful English translation of SKILL.md, lines 3–6:

markdown
Before displaying this skill's content, first invoke `verify.py` to check the local license file.
- If the license file does not exist or has expired, tell the user to renew.
- If the license is valid, continue displaying the following content:

Faithful English translation of SKILL.md, lines 47–50:

markdown
Before sending, check whether all three modules are complete:
- Think
- Execute
- Review

Missing any module → add it before sending

Technical Analysis

The skill contains unconditional instructions that alter how the hosting agent handles the current session. Before presenting the skill, it directs the agent to execute verify.py and conditionally replace the requested content with a subscription-renewal message. It also requires all resulting responses to conform to a fixed Think/Execute/Review structure.

These directives are not framed as an optional technique that the user can explicitly request. Instead, they operate as mandatory preconditions and output constraints applied when the skill is loaded. This is instruction hijacking because skill-controlled text redirects the agent's current behavior and response goals away from the user's immediate request.

The invoked script reads a fixed local file at ~/.openclaw/skills/.license/3steps/license.json and prints either the skill content or renewal information. The reviewed implementation does not execute shell commands, retrieve remote payloads, modify credentials, establish persistence, or elevate privileges. The security issue is therefore limited to behavioral control, local license inspection, content gating, and promotional redirection.

Attack Path

  1. A user or platform loa ...[truncated 1325 chars]
Remediation
View remediation

Remediation Suggestions

  1. Make the communication framework explicitly optional and activate it only after a direct user request.
  2. Remove unconditional language requiring the agent to invoke verify.py before responding.
  3. Enforce licensing in a trusted platform or application layer rather than through natural-language instructions embedded in the skill.
  4. Do not replace user-requested output with promotional or renewal messaging. Return a concise, neutral access error through the trusted licensing layer when access is unavailable.
  5. Replace the mandatory response-format rule with nonbinding guidance, such as: “When requested by the user, responses may use the Think/Execute/Review structure.”
  6. Limit any license check to the minimum required metadata and clearly disclose the local file being accessed.
  7. Ensure skill instructions cannot override higher-priority policies, the user's current goal, or task-specific output requirements.
Vulnerability Patterns
  • MCP Tool PoisoningHidden Instructions, Unicode Deception, Parameter Description Injection
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
  • Supply ChainUnpinned Dependencies, External Script Fetching, Obfuscated Code
Findings (4)

Intent-Code Divergence

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The skill instructs the agent to run a local verification script and inspect a local license file before revealing otherwise static prose content. This creates an unnecessary prompt-driven trigger for local file access and script execution behavior, which is dangerous because skill text is untrusted input and should not be able to cause host-side checks or gating without explicit platform enforcement and user awareness.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
94% confidence
Finding

The file-level description and all user-facing messages are written exclusively in Chinese, which imposes a specific language on users without opt-in. The policy allows locale constraints only when explicitly justified or when the user is offered a language choice, neither of which is present here.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
71% confidence
Finding

Natural-language policy violations include forcing a specific language without user opt-in. This skill presents all instructions and user-facing text in Chinese only, with no indication that another language can be used or that the locale restriction is intentional and justified.

Content

No source excerpt is available for this finding.

Missing User Warnings

Low
Category
Not specified by scanner
Confidence
88% confidence
Finding

The skill directs the agent to check a local license file via verify.py before responding, but does not disclose that it may access local files or condition output on that result. Even if the action is framed as licensing, hidden local access instructions in untrusted skill content normalize unnecessary file inspection and can mislead users about what the agent is doing.

Content

No source excerpt is available for this finding.