T08 · Insecure Dependencies
- Location
skill.json:27- Finding
Unpinned Third-Party npm Package Is Automatically Downloaded and Executed
- Content
View full analysis
Vulnerability Details
File Location:
skill.json:27-37; duplicated in installation guidance atREADME.md:17-29
Vulnerability Type:T08: Insecure Dependencies
Risk Level: HighVulnerable Code
skill.json:27-37:json "command": "npx", "args": [ "-y", "@agentdocs1/mcp-server", "--http" ], "env": { "AGENTDOCS_URL": "${config.agentdocs_url}", "API_KEY": "${config.api_key}", "DEFAULT_PACKS": "logistics" },README.md:17-29:json { "mcpServers": { "uplo-logistics": { "command": "npx", "args": ["-y", "@agentdocs1/mcp-server", "--http"], "env": { "AGENTDOCS_URL": "https://your-instance.uplo.ai", "API_KEY": "your-api-key", "DEFAULT_PACKS": "logistics" } } } }Technical Analysis
The configuration invokes
npx -ywith@agentdocs1/mcp-serverbut does not specify an exact package version or integrity hash. Consequently, startup may retrieve and execute whichever release the package registry resolves at that time. The-yoption suppresses the interactive installation confirmation.This creates a mutable dependency execution channel: the effective executable can change after the Skill has been reviewed. A compromised npm publisher account, malicious package release, registry compromise, or unexpected upstream change could result in arbitrary code execution under the account running the Agent.
The child process also receives
API_KEYandAGENTDOCS_URLthrough its environment. A malicious package version could read and exfiltrate those values. This finding does not establish that the current package is malicious; it identifies the unsafe, unpinned execution model.Attack Path
- An attacker compromises the npm publisher account, package distribution process, or another relevant supply-chain component.
- The attacker publishes a malicious release of `@agentdocs1/ ...[truncated 898 chars]
- Remediation
View remediation
Remediation Suggestions
- Pin
@agentdocs1/mcp-serverto a reviewed, exact version rather than relying on the registry's latest resolution. - Install the dependency through a lockfile-controlled deployment process and verify package integrity hashes.
- Remove automatic
-yinstallation from runtime startup. Install and verify dependencies during a controlled build or provisioning stage. - Monitor the pinned package and its transitive dependencies for known vulnerabilities and publisher changes.
- Run the MCP server in a restricted sandbox or container with minimal filesystem and network permissions.
- Use a narrowly scoped MCP token, rotate it regularly, and ensure it cannot perform administrative operations.
- Restrict outbound network access to explicitly required UPLO endpoints so an unexpected package cannot freely exfiltrate credentials.
- Consider vendoring or internally mirroring a reviewed package artifact and validating its signature or checksum before execution.
- Pin
