T05 · Unauthorized Access and Privilege Escalation
- Location
SKILL.md:16- Finding
Overprivileged and Ambiguous Tool Permissions
- Content
View full analysis
Vulnerability Details
File Location:
SKILL.md, lines 16-23
Vulnerability Type: Excessive filesystem and command-execution permissions
Risk Level: MediumVulnerable Code
yaml tools: - - read - exec homepage: https://skillhub.cn pricing_tier: L3 pricing_model: per_use suggested_price: 29.9 tools: ["read", "write", "exec"]Technical Analysis
The Skill declares general-purpose
read,write, andexeccapabilities even though its stated functionality is limited to selecting a DeepSeek model and sending HTTPS requests to the DeepSeek API. Arbitrary filesystem write access is not required for this workflow, and unrestricted filesystem read access is broader than necessary. General command execution is also significantly more powerful than a constrained HTTP client.The
toolsproperty is defined twice using different structures. Depending on how the Agent platform parses duplicate YAML keys, either declaration may override the other or produce inconsistent permission behavior. Under the broader interpretation, the Skill receives read, write, and command-execution access.No instruction in the audited file directly attempts to exploit these permissions. Nevertheless, exposing them violates least-privilege principles and increases the consequences of malicious user input, prompt injection, or compromised remote model output.
The documented transmission of the API key in an Authorization header and user prompts in the request body to
https://api.deepseek.com/v1/chat/completionsis necessary for the declared remote-model functionality. It is not, by itself, evidence of covert exfiltration.Attack Path
- An Agent loads the Skill and grants the declared
read,write, andexectools. - The user submits attacker-controlled content, or an external model response contains instructions interpreted by the Agent as actionable.
- The injected instructions induce the Agent to i ...[truncated 906 chars]
- An Agent loads the Skill and grants the declared
- Remediation
View remediation
Remediation Suggestions
- Remove the duplicate
toolsdeclarations and retain one unambiguous, schema-valid declaration. - Remove
write, because the documented workflow does not require filesystem modification. - Remove general filesystem
readunless a specific, documented local input must be accessed. If reading is necessary, restrict it to explicitly approved paths. - Replace unrestricted
execwith a dedicated HTTPS request tool restricted to:- HTTPS only;
- Hostname
api.deepseek.com; - The required API path;
- Expected HTTP methods and content types.
- If
execis unavoidable, allow only a fixed command template without shell interpolation and reject user-controlled command arguments. - Require explicit user approval before transmitting prompts that may contain secrets or confidential data.
- Ensure API keys are retrieved from a scoped secret store or environment variable and are never included in logs, model-visible prompt content, callback payloads, or error messages.
- Remove the unused
callback_urlparameter or enforce an explicit destination allowlist before implementing callback delivery.
- Remove the duplicate
