T05 · Unauthorized Access and Privilege Escalation
- Location
SKILL.md:47- Finding
Unnecessary Command Execution and Filesystem Permissions
- Content
View full analysis
Vulnerability Details
File Location:
SKILL.md, lines 47–50
Vulnerability Type: Excessive tool permissions violating least privilege
Risk Level: MediumVulnerable Code
yaml tools: - read - exec - writeThe excessive permission declaration is contradicted by the skill's own runtime documentation at line 328:
text - **Classification**: MD (pure Markdown instructions, no exec command-line capability required)The error-handling guidance at line 336 nevertheless recommends shell execution:
text | Network error | Connection timed out or unreachable | Execute the ping command to test network connectivity, check firewall and proxy settings, then execute the ping command again and refer to domestic alternatives |Technical Analysis
The skill's stated purpose is to generate social-media captions through an agent's built-in language model. Its dependency documentation states that no external captioning or image-recognition API is called and that command-line execution is unnecessary. Consequently, granting
exec,write, and potentiallyreadis not justified by the legitimate workflow.If the host grants capabilities according to this manifest, the skill obtains a shell-execution channel and filesystem access that are unrelated to caption generation. The
pingguidance creates a concrete path by which the unnecessaryexeccapability may be invoked. Although the reviewed file contains no directly malicious command, this permission configuration increases the damage that crafted user input, instruction confusion, or a later unauthorized modification could cause.Attack Path
- An agent platform loads
SKILL.mdand grants the declaredread,exec, andwritetools. - A user supplies crafted content or a request that induces the agent to interpret troubleshooting or caption-related input as an instruction to use those tools.
- The agent invokes `ex ...[truncated 1024 chars]
- An agent platform loads
- Remediation
View remediation
Remediation Suggestions
- Remove
execandwritefrom the declared tool list. - Remove
readunless the host demonstrably requires it to load the skill itself; caption generation does not require arbitrary file access. - Remove the
pingcommand recommendation at line 336 and replace it with non-executable guidance, especially because the skill claims not to use external services. - Explicitly state that the skill must not execute commands or read or modify local files.
- Restrict activation to photo-caption requests rather than the broad marketing, writing, title-optimization, and general content-creation trigger at lines 187–189.
- Enforce host-side capability controls independently of the manifest, including sandboxing, command allowlists, workspace-scoped filesystem access, and user confirmation for sensitive operations.
- Add a validation check that rejects tool declarations not required by the documented workflow.
- Remove
