T08 · Insecure Dependencies
- Location
skill.json:27- Finding
Unpinned MCP Package Is Automatically Downloaded and Executed
- Content
View full analysis
Vulnerability Details
File Location:
skill.json:27-32; installation instructions are also documented inREADME.md:20-23
Vulnerability Type:T08: Insecure Dependencies
Risk Level: HighVulnerable Code
From
skill.json:27-32:json "command": "npx", "args": [ "-y", "@agentdocs1/mcp-server", "--http" ],Corresponding configuration from
README.md:20-23:json "command": "npx", "args": ["-y", "@agentdocs1/mcp-server", "--http"],Technical Analysis
The skill starts the external
@agentdocs1/mcp-serverpackage throughnpx -ywithout specifying an exact version or package integrity value. If the package is not already available in the local npm cache,npxcan retrieve it from the configured npm registry. The-yoption suppresses the normal installation confirmation and permits the downloaded package to execute automatically.Because no immutable version is pinned, the effective code executed by the skill can change after this skill package has been reviewed. A compromised maintainer account, malicious package release, registry compromise, or unexpected upstream update could therefore introduce arbitrary code into the MCP server startup path.
The launched process receives the configured
API_KEYand the UPLO service endpoint through environment variables. It consequently operates in a security-sensitive context with access to credentials and potentially confidential organizational environmental records.Attack Path
- An attacker compromises the npm package, its publisher account, or the relevant package-distribution channel.
- The attacker publishes a malicious release under the existing
@agentdocs1/mcp-serverpackage name. - A user installs or starts this skill on a system where the malicious release is selected by the unpinned
npxinvocation. - The
-yoption allows the package to be downloaded and executed without an interactive appro ...[truncated 1190 chars]
- Remediation
View remediation
Remediation Suggestions
- Pin the dependency to a reviewed, exact version, for example
@agentdocs1/mcp-server@X.Y.Z, rather than resolving an unspecified release. - Install the dependency during a controlled build or deployment phase instead of downloading it automatically whenever the skill starts.
- Use a lockfile and verify npm integrity metadata or an independently maintained checksum before execution.
- Remove
-ywhere interactive installation is appropriate, so unexpected package retrieval is not silently approved. - Restrict package installation to an approved registry and enforce dependency allowlisting or provenance verification.
- Run the MCP server in a sandbox or isolated container with minimal filesystem and network permissions.
- Supply a narrowly scoped, short-lived API token that grants only the environmental operations required by this skill.
- Prevent the MCP child process from inheriting unrelated environment variables and credentials.
- Monitor and audit package-version changes, MCP authentication activity, and unusually broad knowledge exports.
- Update the
README.mdexample to use the same pinned and verified dependency configuration so users do not reproduce the unsafe invocation.
- Pin the dependency to a reviewed, exact version, for example
