T05 · Unauthorized Access and Privilege Escalation
- Location
SKILL.md:33- Finding
Unnecessary Shell Execution and Filesystem Write Permissions
- Content
View full analysis
Vulnerability Details
File Location:
SKILL.md:33-36
Vulnerability Type: Violation of least privilege through unnecessary tool permissions
Risk Level: MediumVulnerable Code
yaml tools: - read - exec - writeTechnical Analysis
The skill declares access to the
execandwritetools even though its documented purpose is limited to read-only Discord queries. Its described workflow only requires ClawLink integration discovery and Discord API query operations.Shell execution and filesystem modification are substantially more privileged than the skill's legitimate functionality requires. Their availability expands the consequences of prompt injection, malicious user input, untrusted integration output, or erroneous agent behavior. This is a least-privilege violation rather than evidence that the current skill deliberately executes commands or modifies files.
Attack Path
- An agent loads the skill and grants all tools declared in its metadata, including
execandwrite. - The agent processes attacker-controlled input or untrusted content returned by an external integration.
- The content manipulates the agent into invoking one of the unnecessarily available privileged tools.
- The
exectool runs a local command, or thewritetool creates or modifies a local file. - The resulting effect occurs with the operating-system permissions and filesystem access of the agent process.
No command payload or direct invocation of these tools was found in the audited file. Exploitation therefore depends on a separate instruction-manipulation or tool-misuse condition.
Impact Assessment
Successful exploitation could allow command execution and file modification within the privileges of the hosting agent process. Depending on the environment, this could affect project files, accessible configuration, local data, or other resources available to that process.
The affected scope is broader than the skill's stated read- ...[truncated 215 chars]
- An agent loads the skill and grants all tools declared in its metadata, including
- Remediation
View remediation
Remediation Suggestions
- Remove the unnecessary
execandwriteentries from the skill metadata. - Grant only the narrowly scoped ClawLink and Discord read-only tools needed for documented operations.
- Enforce an explicit allowlist for tools such as integration discovery, authorization inspection, user lookup, guild lookup, invite resolution, gateway lookup, and public-key retrieval.
- If filesystem writes later become necessary, document the exact use case and restrict writes to a dedicated directory with minimal permissions.
- If command execution later becomes necessary, expose a narrowly scoped operation instead of a general-purpose shell and validate all arguments against a strict allowlist.
- Treat user input and external integration responses as untrusted data, and prevent either from authorizing tool use or overriding tool restrictions.
- Add an automated manifest check that rejects privileged tool declarations not exercised by and justified in the documented workflow.
- Remove the unnecessary
