T05 · Unauthorized Access and Privilege Escalation
- Location
SKILL.md:5- Finding
Excessive and Inconsistent Tool Permissions
- Content
View full analysis
Vulnerability Details
File Location:
SKILL.md, lines 5 and 18–21
Vulnerability Type: Excessive filesystem and command-execution privileges
Risk Level: MediumVulnerable Code
yaml allowed-tools: read execyaml tools: - exec - read - writeTechnical Analysis
The skill performs text analysis and rewriting, which does not inherently require general-purpose command execution or filesystem access. Nevertheless, it requests
exec,read, andwritecapabilities.These permissions violate the principle of least privilege:
execmay allow commands to run with the privileges of the hosting agent.readmay expose local files unrelated to the text-rewriting task.writemay allow local files to be created or modified.- The declarations are inconsistent:
writeis listed undertoolsbut omitted fromallowed-tools, creating ambiguity about the skill's effective permissions.
The document also recommends running a network diagnostic command at line 233. Network troubleshooting is not necessary for a tool described as a pure Markdown-based text rewriter and unnecessarily broadens its operational scope.
No malicious command, credential-access instruction, destructive operation, persistence mechanism, or exfiltration behavior was identified. The risk arises from unnecessary capabilities that could be misused if the agent processes prompt-injected or otherwise attacker-controlled content.
Attack Path
- A user or external source supplies attacker-controlled text for rewriting.
- The text contains prompt-injection instructions intended to influence the tool-enabled agent.
- Because the skill declares filesystem and command-execution capabilities, the manipulated agent may invoke
read,write, orexecfor actions unrelated to rewriting. - Subject to the host agent's sandbox and approval controls, the attacker could cause local data access, file ...[truncated 702 chars]
- Remediation
View remediation
Remediation Suggestions
- Remove
exec,read, andwritebecause ordinary text rewriting requires no external tools. - Remove the network diagnostic instruction at line 233.
- Make
allowed-toolsandtoolsconsistent so that the effective permission set is unambiguous. - If file-based input is required, allow access only to files explicitly selected by the user and restrict operations to the smallest necessary directory.
- If output must be saved, require explicit user confirmation and use a narrowly scoped write operation rather than unrestricted filesystem access.
- If command execution is retained for a documented requirement, enforce a fixed command allowlist, reject user-controlled command arguments, disable shell interpretation, and run commands in a restricted sandbox.
- Treat all text submitted for rewriting as untrusted data and explicitly prohibit instructions inside that text from initiating tool calls.
- Remove
