T05 · Unauthorized Access and Privilege Escalation
- Location
skill.md:5- Finding
Excessive Arbitrary Command-Execution Permission
- Content
View full analysis
Vulnerability Details
File Location:
skill.md, line 5
Vulnerability Type: Excessive privilege and violation of least privilege
Risk Level: MediumVulnerable Code
yaml allowed-tools: [read, write, edit, pdf, exec, web_search, tavily_search, tavily_extract]Technical Analysis
The Skill declares access to the unrestricted
exectool even though its documented purpose is limited to reading academic papers, generating critiques, editing text, processing PDFs, and optionally searching for literature. None of the documented features establishes a legitimate requirement for arbitrary operating-system command execution.Granting
execexpands the Skill's authority beyond its functional requirements and violates the principle of least privilege. If attacker-controlled manuscript content or contextual instructions influence tool selection, the agent could be induced to execute commands unrelated to paper analysis. The audit found no command-execution payload or explicit malicious instruction in the Skill itself; the risk arises from the unnecessarily broad permission.Attack Path
- The Skill is loaded with the
exectool enabled. - An attacker supplies a manuscript or other analyzed content containing instructions crafted to influence the agent.
- The agent treats those untrusted instructions as actionable and invokes
exec. - The command runs with the operating-system privileges of the agent process.
- Depending on the runtime sandbox and account permissions, the command may read or modify local files, start processes, or interact with accessible system resources.
This path requires both successful manipulation of the agent and a runtime that permits the declared
execcapability.Impact Assessment
Successful exploitation could provide command execution within the security context of the agent process. The accessible scope may include files, processes, environment variables, and network resources available to th ...[truncated 174 chars]
- The Skill is loaded with the
- Remediation
View remediation
Remediation Suggestions
- Remove
execfrom the allowed tool list:
yaml allowed-tools: [read, write, edit, pdf, web_search, tavily_search, tavily_extract]-
If document conversion genuinely requires an external process, replace unrestricted command execution with a narrowly scoped conversion tool that:
- Allows only approved binaries and fixed operations.
- Passes arguments without shell interpretation.
- Rejects metacharacters and untrusted executable paths.
- Restricts input and output to a dedicated workspace.
- Runs under a low-privilege account in a sandbox.
- Disables network access unless explicitly required.
- Enforces resource and execution-time limits.
- Records tool invocations for security review.
-
Treat manuscript contents as untrusted data and explicitly prohibit instructions embedded in analyzed documents from controlling tools.
-
Retain optional web-search behavior behind explicit user authorization, as described by the Skill, and constrain searches to the minimum data required.
- Remove
