T01 · Skill Instruction Hijacking
- Location
SKILL.md:17- Finding
Global File-Operation Hijacking Through Mandatory Automatic Relocation
- Content
View full analysis
Vulnerability Details
File Location:
SKILL.md, lines 17–27
Vulnerability Type: Mandatory global instruction override causing unauthorized workspace mutation
Risk Level: MediumVulnerable Code
markdown ## Mandate: Automatic Organization You MUST follow the PARA structure for ALL file operations. Never leave new files in the root directory (`/root/clawd/`) unless they are core identity files (AGENTS.md, MEMORY.md, etc.). 1. **New Project Files?** Create a subfolder in `1-Projects/`. 2. **Long-term reference or data?** Put it in `3-Resources/`. 3. **Finished work?** Move it to `4-Archives/`. 4. **System/Config updates?** Keep them in `2-Areas/`. ## Workflow 1. **Identify**: Determine which category a file or directory belongs to. 2. **Move**: Use `mv` to place it in the correct PARA folder. 3. **Maintain**: Periodically review Projects and move finished ones to Archives.Technical Analysis
The Skill uses a mandatory instruction applying the PARA policy to all file operations, rather than limiting it to explicit organization requests. Once loaded, this directive can alter how the Agent handles unrelated file-management tasks and instruct it to move files automatically based on subjective categorization.
The use of
mvis not accompanied by requirements for user authorization, source and destination validation, collision detection, non-overwriting behavior, backups, transactional rollback, or protection of active and sensitive files. The narrow exception for unspecified “core identity files” does not adequately protect configuration files, hidden files, active project artifacts, symbolic links, or files required at fixed paths.The behavior does not grant privileges beyond those already held by the Agent. However, it directs the Agent to exercise its existing filesystem privileges over the entire
/root/clawd/workspace, which exceeds the scope needed for an opt-in organizationa ...[truncated 1614 chars]- Remediation
View remediation
Remediation Suggestions
- Replace the global
MUSTdirective with an opt-in rule that operates only when the user explicitly requests PARA organization. - Restrict operations to a user-approved directory instead of automatically controlling every file operation under
/root/clawd/. - Generate a dry-run plan listing each source path, proposed destination, and categorization reason before making changes.
- Require explicit user confirmation before moving files, particularly for batch operations, existing files, system configuration, hidden files, or active project artifacts.
- Validate and canonicalize source and destination paths, reject traversal outside the approved workspace, and handle symbolic links safely.
- Require collision-safe movement, such as refusing to overwrite an existing destination unless the user separately approves it.
- Define protected-file rules covering identity files, configuration, hidden files, active artifacts, and any files whose paths are referenced by other resources.
- Record every move in an audit log and provide a tested rollback procedure that restores the original paths.
- Disable autonomous “periodic” maintenance unless the user explicitly initiates and approves a review.
- Replace the global
