Back to skill

Security audit

Smart Workspace

Security checks for vulnerabilities and agentic risk

Overview

This skill is a disclosed workspace organizer, but it automatically scans and changes the workspace with limited confirmation and path-safety guidance.

Install only if you are comfortable with the agent automatically scanning workspace folder names, creating folders, and updating PROJECT-HISTORY.md. Keep the history file under your control, review entries before relying on them, and avoid using this skill in workspaces where unexpected local writes or persisted project metadata would be sensitive.

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:163
Finding

Unvalidated Project Paths Can Escape the Workspace Boundary

Content
View full analysis

Vulnerability Details

File Location: SKILL.md, lines 163-195
Vulnerability Type: Unvalidated path traversal through project-history entries
Risk Level: Medium

The skill reads project metadata from PROJECT-HISTORY.md, selects a matching entry, and directly uses its project path for folder and file operations. The workflow does not require path canonicalization or verification that the resolved destination remains inside the current workspace.

Relevant code segment:

text
Read PROJECT-HISTORY.md
    ↓
Match rules (priority order):
    1. key exact match → Direct use
    2. name/desc contains keyword → Direct use
    3. Chinese keyword mapping hit → Direct use
    4. No match → Auto-create new project
    5. Multiple matches → Use first one, notify user
text
【Existing Project】
    1. Create ./[project]/ folder (if not exists)
    2. Update PROJECT-HISTORY.md: last_used = today
    3. Reply: "Task organized to [project] (last_used: today)"

【New Project】
    1. Create ./[project-name]/ folder
       - If folder exists, auto-add suffix _1, _2, etc.
    2. Append new entry to PROJECT-HISTORY.md
    3. Reply: "Created new project [project-name], files will be organized here"

The history format permits a path field without defining validation requirements:

markdown
## project-key
- name: Project Name / 项目名称
- path: ./project-folder/
- desc: Project description / 项目描述
- created: YYYY-MM-DD
- last_used: YYYY-MM-DD

Technical Analysis

PROJECT-HISTORY.md functions as control data because its path values determine where subsequent operations occur. The skill treats those values as trusted even though the file is writable and persistent.

No instruction requires the agent to:

  • Reject absolute paths.
  • Reject .. traversal components.
  • Resolve the candidate path against a canonical workspace root.
  • Verify that the resolved path is a strict descendant of that root.
  • Detect symbolic-link escapes.
  • Validate malformed o ...[truncated 2011 chars]
Remediation
View remediation

Remediation Suggestions

  1. Treat every history entry as untrusted input and parse it using a strict schema.
  2. Require project paths to be normalized relative paths containing only approved directory-name characters.
  3. Reject absolute paths, empty paths, control characters, URI-like values, and any . or .. traversal component.
  4. Resolve the candidate path against the canonical workspace root before every operation.
  5. Verify that the canonical destination is a strict descendant of the canonical workspace root, using path-component-aware comparison rather than a raw string-prefix check.
  6. Inspect every existing path component for symbolic links and reject any path whose real destination escapes the workspace.
  7. Apply the same checks to generated project names before creating folders.
  8. Refuse invalid history entries and notify the user rather than silently creating or using their paths.
  9. Use an atomic, permission-restricted history update process to reduce tampering and race-condition risks.
  10. Add tests covering ../outside, nested traversal, absolute paths, encoded separators, malformed entries, prefix-confusion paths, and symbolic-link escapes.
Vulnerability Patterns
  • 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 Tool PoisoningHidden Instructions, Unicode Deception, Parameter Description Injection
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
Findings (9)

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
93% confidence
Finding

The README explicitly states that on first load the skill will automatically scan existing workspace folders and generate a history file, but it does not prominently warn users about privacy, metadata disclosure, or unintended filesystem modifications. In context, automatic enumeration of project folders can reveal sensitive project names and structure, and writing PROJECT-HISTORY.md creates persistent records without explicit consent.

Content

No source excerpt is available for this finding.

Vague Triggers

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The trigger examples are broad, natural-language phrases such as general requests to organize files, which makes accidental invocation likely during unrelated conversations. Because this skill performs filesystem-affecting actions automatically and without confirmation, unintended activation could cause unexpected folder creation, task misclassification, or silent updates to project-tracking records.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The skill directs automatic scanning of the workspace and creation of a persistent PROJECT-HISTORY.md file on first load without explicit user confirmation. This creates and modifies data based solely on skill activation, which can expose project names/metadata and cause unintended persistence in environments where filesystem changes should be deliberate.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
96% confidence
Finding

This section instructs the agent to create folders and update project history automatically during normal operation, without a safety gate or confirmation step. Unattended filesystem writes can misclassify tasks, overwrite organizational intent, and leave persistent artifacts from ambiguous prompts or prompt-injection-influenced task text.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
97% confidence
Finding

The natural-language instructions require concise English or pinyin folder names and explicitly say to avoid Chinese folder names. This is a language/locale constraint imposed by the skill, and the file does not offer a user choice or justify the restriction as region-specific.

Content

No source excerpt is available for this finding.

Session Persistence

Medium
Category
Rogue Agent
Confidence
84% confidence
Finding

The skill persistently records task-derived project information in PROJECT-HISTORY.md and updates last_used over time, which is a form of session persistence. While persistence is central to the feature, storing task metadata indefinitely can leak sensitive project context and create a durable memory surface that may later influence routing or be exposed to other processes with workspace access.

Content

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

"已将此任务整理到 data_analyzer/(last_used: 今天)"

text

### Case 2: No Match → Auto Create / 无匹配 → 自动创建

**User / 用户**: "我要开发一个新的推荐算法" / "I want to develop a new recommendation algorithm"

Autonomous Decision Making

Medium
Category
Excessive Agency
Confidence
95% confidence
Finding

The instruction to auto-create folders 'without asking' grants the skill autonomous authority to make persistent workspace changes from interpreted user intent alone. In an agent setting, this raises the risk of unintended modifications from vague prompts, indirect prompt injection, or incorrect keyword matching, especially because the changes are automatic and durable.

Content

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

md
| # | English | 中文 |
|---|---------|------|
| 1 | **Be direct**: If match found, use it directly and notify user | **直接处理**: 如匹配到项目,直接使用并告知用户 |
| 2 | **Auto-create**: If no match, create new folder without asking | **自动创建**: 无匹配时直接创建新文件夹,无需询问 |
| 3 | **Update always**: Always update `last_used` when using existing project | **始终更新**: 使用已有项目时必须更新 last_used |
| 4 | **Record all**: Must update `PROJECT-HISTORY.md` for new projects | **记录新项目**: 创建新项目时必须更新 PROJECT-HISTORY.md |
| 5 | **Bilingual**: Support both Chinese and English keyword matching | **双语兼容**: 同时支持中文关键词和英文key直接匹配 |

Description-Behavior Mismatch

Low
Category
Not specified by scanner
Confidence
75% confidence
Finding

The manifest frames the skill as a lightweight project file/workspace management tool focused on organizing folders, tracking projects, archiving, and cleanup. In the execution flow, the skill is instructed to analyze the user's task, extract keywords, and determine project type, which adds a semantic task-classification function not clearly stated in the manifest description.

Content

No source excerpt is available for this finding.

Intent-Code Divergence

Low
Category
Not specified by scanner
Confidence
67% confidence
Finding

The permission notes explicitly state 'No access' to other agents' files, while the cross-agent compatibility section describes agent-specific workspace paths and automatic path resolution across different agent workspaces. Although it does not explicitly instruct cross-agent access, the documentation creates tension between strict isolation claims and path-handling language that references multiple agent workspaces.

Content

No source excerpt is available for this finding.