T05 · Unauthorized Access and Privilege Escalation
- Location
SKILL.md:31- Finding
Excessive Filesystem and Command-Execution Permissions
- Content
View full analysis
Vulnerability Details
File Location:
SKILL.md, lines 31–34
Vulnerability Type: Violation of least privilege through unnecessary tool permissions
Risk Level: MediumVulnerable Code
yaml tools: - read - exec - writeTechnical Analysis
The Skill declares unrestricted reading, writing, and command-execution capabilities even though its stated purpose is limited to generating titles, descriptions, tags, and narration scripts through an LLM. Those content-generation functions do not inherently require filesystem access or operating-system command execution.
The requested capabilities substantially increase the Skill's authority:
readmay permit access to local files available to the Agent.writemay permit modification or creation of files.execmay permit execution of operating-system commands under the Agent process's account.
The document later advertises generic file processing and command execution, but the package contains no implementation that demonstrates a legitimate need for these privileges. This breaks the principle of least privilege and increases the consequences of malicious user input, prompt injection in processed content, or future modifications to the Skill instructions.
Attack Path
- A host loads the Skill and grants the tools declared in its metadata.
- An attacker supplies crafted task input or content containing instructions that induce the Agent to perform actions unrelated to Bilibili text generation.
- The Agent invokes
readto access local data,writeto alter files, orexecto run commands. - The resulting access occurs with the filesystem permissions and operating-system privileges of the Agent process.
This path depends on the host granting the declared tools and the Agent being induced to misuse them; the audited file does not contain an autonomous exploitation payload.
Impact Assessment
Successful exploitati ...[truncated 361 chars]
- Remediation
View remediation
Remediation Suggestions
- Remove
read,write, andexecfrom the declared tools because the documented text-generation workflow does not require them. - Use no external tools when the host LLM can generate the requested content directly.
- If a future implementation requires a tool, grant only the narrowest capability needed. Restrict filesystem operations to a dedicated workspace and use an allowlisted command interface instead of a general shell.
- Require explicit user confirmation before any filesystem modification or command execution.
- Enforce host-side sandboxing, path restrictions, command allowlists, execution timeouts, and output-size limits.
- Add tests verifying that ordinary title, description, tag, and script generation never invokes filesystem or execution tools.
- Remove
