Back to skill

Security audit

Workspace Project Standard

Security checks for vulnerabilities and agentic risk

Overview

This skill is mostly a workspace documentation standard, but it tells the agent to immediately move any unapproved root-level file, which can disrupt or lose unrelated workspace data.

Review this before installing if your workspace root contains important files or files managed by other tools. Use it only when you want this exact project layout, and require the agent to list proposed moves and ask before relocating anything.

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

Warning
Location
SKILL.md:55
Finding
Unconditional Workspace-Wide File Relocation Using a Fixed Whitelist## Vulnerability Details **File Location**: `SKILL.md`, lines 55-69 **Vulnerability Type**: Unsafe filesystem mutation **Risk Level**: Medium ### Vulnerable Code ```markdown ## Workspace Root Whitelist Only these may exist in `workspace/` root: **System files:** `AGENTS.md` `SOUL.md` `MEMORY.md` `CREDENTIALS.md` `HEARTBEAT.md` `SESSION-STATE.md` `IDENTITY.md` `USER.md` `CODING-PERSONA.md` `TOOLS.md` `.env` `package.json` `package-lock.json` **System dirs:** `memory/` `projects/` `scripts/` `backups/` `captures/` `config-backups/` `tmp/` `skills/` `node_modules/` `.agents/` `.clawhub/` `.openclaw/` `.pi/` Any file not on this list → move to its project's `tmp/` immediately. ``` ### Technical Analysis The Skill instructs the agent to move every workspace-root file that is absent from a fixed whitelist. The operation is unconditional and does not require user confirmation, establish file ownership, determine whether a file belongs to the active project, or verify that the destination is safe. A static whitelist can become incomplete whenever the platform, another Skill, or the user introduces a legitimate root-level file. The instruction also provides no safe handling for symbolic links, destination-name conflicts, open files, protected files, or rollback after a partial operation. Moreover, the phrase “its project's `tmp/`” does not define a trustworthy method for associating an arbitrary root file with a project. This behavior violates least-change principles for workspace organization. Although it does not grant new operating-system privileges, it directs the agent to use its existing filesystem permissions against files outside the selected project's scope. ### Attack Path 1. A user invokes the Skill to create documentation or organize a project. 2. The agent applies the workspace-root whitelist. 3. A legitimate file introduced by the user, platform, or another tool is not present in the hardcoded list. 4. The ...[truncated 1558 chars]
Remediation
## Remediation Suggestions 1. Restrict organization operations to the project directory explicitly selected by the user. Do not mutate unrelated workspace-root files. 2. Replace automatic relocation with a dry-run that lists each proposed source path, destination path, and reason. 3. Require explicit user confirmation before moving any existing file. 4. Determine and validate project ownership for every candidate file. If ownership is ambiguous, leave the file unchanged and report it. 5. Resolve and canonicalize source and destination paths before acting, and reject paths that escape the intended workspace through traversal or symbolic links. 6. Refuse to overwrite an existing destination. Use collision-safe names or request user guidance. 7. Exclude symbolic links, protected platform files, active configuration files, and files used by other projects unless the user explicitly authorizes them. 8. Record an operation manifest containing original and destination paths, then provide an atomic rollback procedure. 9. Treat the whitelist as advisory validation rather than authorization to move files. 10. Change the final instruction to language such as: “Report unexpected root files and ask the user whether each should be moved; never relocate them automatically.”
Vulnerability Patterns
  • Trigger AbuseOverly Broad Trigger, Shadow Command Trigger, Keyword Baiting Trigger
  • 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 (5)

Natural-Language Policy Violations

Medium
Confidence
90% confidence
Finding
The required sections are specified only in Chinese, which imposes a language constraint on users of the skill. This is a natural-language policy concern because the file does not indicate that users may choose another language or that the Chinese-only requirement is limited to a justified regional context.

Natural-Language Policy Violations

Medium
Confidence
97% confidence
Finding
The entire template, including headings and field labels, is written in Chinese with no indication that language selection is optional or that the skill is intended only for a Chinese-speaking or region-specific context. This can violate language/locale policy requirements because it effectively imposes a specific language on users without opt-in.

Vague Triggers

Medium
Confidence
93% confidence
Finding
The description embeds multiple broad trigger phrases such as 'new project', 'create project', and 'clean up workspace', which are common user requests and may cause the skill to activate in situations beyond the author's intent. Unintended activation can steer agent behavior, alter workspace structure, or create documentation automatically when the user did not explicitly ask for this specific standard, increasing the chance of workflow interference or unsafe file operations.

Natural-Language Policy Violations

Low
Confidence
91% confidence
Finding
The file's headings and instructions are all in Chinese, which imposes a specific language on users of the skill template. The policy allows fixed language only when the skill offers user choice or clearly documents a justified locale-specific scope, neither of which appears here.

Natural-Language Policy Violations

Low
Confidence
72% confidence
Finding
The trigger list mixes English and Chinese phrases, but the manifest does not clarify whether multilingual triggering is optional, user-configurable, or limited to a justified locale-specific context. This can create an implicit language policy behavior without documented user opt-in.

Static analysis

No suspicious patterns detected.