T05 · Unauthorized Access and Privilege Escalation
- Location
SKILL.md:25- Finding
Excessive Tool Permissions Violate Least Privilege
- Content
View full analysis
Vulnerability Details
File Location:
SKILL.md, lines 25–30; supporting declarations at lines 214–216 and privilege guidance at line 228
Vulnerability Type: Excessive command-execution and file-write capabilities
Risk Level: MediumVulnerable Code
yaml tools: - read - exec - write - glob - grepTechnical Analysis
The skill's stated purpose is to explain source code through diagrams and analogies. That function can ordinarily be completed using user-supplied content or narrowly scoped, read-only access. Nevertheless, the manifest grants general
execandwritecapabilities alongside read and search tools.The document also claims command-execution and file-writing functionality at lines 214–216 and recommends elevated execution when permissions are insufficient at line 228. No enforceable command allowlist, workspace path restriction, sandbox policy, privilege boundary, or explicit user-confirmation requirement is defined.
Because this is a documentation-only skill, the reviewed package does not itself contain an executable payload. Exploitation therefore depends on an Agent honoring these declared capabilities and allowing untrusted input to influence tool calls.
Attack Path
- A user supplies attacker-controlled source code, repository content, filenames, or embedded instructions for explanation.
- The skill-enabled Agent processes that untrusted content while possessing
execandwritepermissions. - Crafted content persuades or causes the Agent to invoke a command or modify a file instead of limiting itself to code explanation.
- The command executes or the file is changed with the Agent process's current privileges.
- If the operator follows the elevated-permission guidance, the resulting effect may extend beyond the user workspace and affect privileged system resources.
Impact Assessment
Successful exploitation could permit command execution and file m ...[truncated 583 chars]
- Remediation
View remediation
Remediation Suggestions
- Remove
execandwritefrom the declared tools because they are not necessary for code explanation. - Retain only narrowly scoped read and search capabilities, restricted to the user-approved project directory.
- Remove guidance recommending execution with administrator or root privileges.
- If code execution is genuinely required, use an isolated sandbox with:
- A fixed command allowlist.
- No network access by default.
- Workspace-only filesystem access.
- Read-only mounts wherever possible.
- CPU, memory, process, and execution-time limits.
- A non-privileged disposable operating-system account.
- Require explicit user confirmation before every command execution or file modification, displaying the exact command and affected paths.
- Treat source files and repository documentation as untrusted data and prohibit instructions embedded in them from authorizing tool calls.
- Align the documented feature set with actual behavior so a code-explanation skill does not advertise unrelated file-writing, API-integration, or system-command capabilities.
- Remove
