Back to skill

Security audit

simulated-upload-helper

Security checks for vulnerabilities and agentic risk

Overview

This skill is a real publishing helper presented with simulated-upload wording, and it can publish one or multiple skills without requiring confirmation.

Review this before installing if you use real ClawHub publishing credentials. Treat its trigger phrases as live release operations, not simulations; verify the target skill list, registry, and publish script yourself before running it, and avoid batch mode unless you intentionally want all changed skills published.

Vulnerability Patterns
  • 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
  • Embedded Malicious CodeShips malicious scripts inside the skill and executes them locally
Findings (1)

T09 · Insecure Skill Coding Practices

Error
Location
SKILL.md:17
Finding

Unsafe Shell Argument Handling and Untrusted Relative Script Execution

Content
View full analysis

Vulnerability Details

File Location: SKILL.md, lines 17-22
Vulnerability Type: Command injection and unsafe executable resolution
Risk Level: High

Vulnerable Code Snippet

sh
./publish-skills.sh --root ".cursor/skills"
./publish-skills.sh --root ".cursor/skills" --skill "<skill-directory-name>"

The surrounding instructions direct the agent to select batch or single-Skill publishing based on user input and substitute the requested Skill directory name into the second command.

Technical Analysis

The Skill instructs an agent to insert a user-controlled Skill directory name into a shell command without requiring strict input validation or execution through a shell-free argument-array API. Double quotes do not prevent every form of shell evaluation. For example, command substitutions such as $(command) can still be evaluated when a generated command string is passed to a shell.

The command also invokes ./publish-skills.sh through a path relative to the current working directory. No instruction requires the agent to resolve the expected repository root, reject symbolic links, verify file ownership, or authenticate the script. Consequently, the executed file is whichever object occupies that path in the agent's current directory.

Exploitation is conditional on the agent constructing and executing these instructions as a shell command string or operating in a repository containing an attacker-controlled publishing script.

Attack Path

User-input injection path:

  1. An attacker requests publication of a Skill whose supplied directory name contains shell substitution syntax or other shell-significant content.
  2. The agent replaces the directory-name placeholder with that input.
  3. The agent submits the resulting command string to a shell.
  4. The shell evaluates the embedded syntax before or while invoking the publishing script.
  5. The attacker's command executes with the same ...[truncated 1360 chars]
Remediation
View remediation

Remediation Suggestions

  1. Validate the requested Skill directory name against a strict allowlist, such as ^[A-Za-z0-9._-]+$, and reject path separators, traversal components, whitespace, control characters, and shell metacharacters.
  2. Resolve the requested directory beneath a trusted Skills root and verify that the canonical path remains inside that root.
  3. Invoke the publishing script with an argument-array API rather than constructing a shell command string. Do not use sh -c, bash -c, eval, or equivalent shell interpretation.
  4. Resolve publish-skills.sh from a trusted absolute repository root instead of the current working directory.
  5. Before execution, verify that the publishing script is a regular file, is not a symbolic link, has trusted ownership and permissions, and matches an approved version or integrity hash.
  6. Review the publishing script before execution and run it with the minimum filesystem, credential, and network permissions required.
  7. Avoid exposing CLAWHUB_TOKEN to unrelated subprocesses. Pass credentials only to the validated publishing process and redact them from command output and error logs.
  8. Require explicit confirmation before batch publication or publication to a non-default registry.
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 (5)

Ae1

High
Category
analysis-evasion
Confidence
100% confidence
Finding

Referenced artifact was not completely inspected

Content

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

md
- 严禁创建新的 skill 目录或 `SKILL.md` 文件。

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
94% confidence
Finding

The description explicitly says to directly trigger an existing publish flow when the user asks for a simulated upload, but it does not require a warning, dry run, or confirmation before executing a release operation. This is dangerous because 'simulated' language may mislead users into expecting a no-op while the skill actually performs a real publication step.

Content

No source excerpt is available for this finding.

Vague Triggers

Medium
Category
Not specified by scanner
Confidence
96% confidence
Finding

The trigger phrases are broad enough to match routine user requests such as 'upload skill' or 'publish skills', which can cause the agent to enter a release workflow without clear confirmation. In this skill's context, that is risky because the resulting action invokes a publish script that may affect local or multiple skills.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
96% confidence
Finding

The batch mode publishes based on detected changes and can affect multiple skills, yet the instructions do not require enumerating targets or obtaining approval before execution. In this context, the lack of guardrails increases the chance of unintended mass publication, especially when no skill name is specified.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
78% confidence
Finding

The natural-language content, including the trigger phrases and usage instructions, is entirely Chinese and assumes Chinese input such as 模拟上传 without stating that the skill is intentionally region-specific or offering alternative language usage. Under the policy, forcing a specific language without user opt-in can be a locale-policy issue.

Content

No source excerpt is available for this finding.