T08 · Insecure Dependencies
- Location
SKILL.md:18- Finding
Unpinned Third-Party Package Installation and Execution
- Content
View full analysis
Vulnerability Details
File Location:
SKILL.md, lines 18-25
Vulnerability Type: Unpinned and automatically executed npm dependencies
Risk Level: MediumVulnerable Code
bash npm install -g @wavespeed/cli wavespeed login # opens https://wavespeed.ai/accesskey and stores the key wavespeed status # confirms you are signed intext Prefer MCP tools over shell commands? The same platform is exposed by [`@wavespeed/mcp`](https://github.com/WaveSpeedAI/mcp-server) (`npx -y @wavespeed/mcp`; tools `search_models`, `get_model_schema`, `get_price`, `upload_file`, `run_model`, `get_prediction`).Technical Analysis
The instructions install
@wavespeed/cliwithout an exact version, lockfile, or package-integrity verification. They also invokenpx -y @wavespeed/mcp, which automatically downloads the currently resolved package release, approves installation without user confirmation, and executes its code.Both package references are mutable because no version is pinned. Consequently, the code executed by users may differ from the version that was available when the Skill was reviewed. npm package installation can execute lifecycle scripts, while an MCP package invoked through
npxruns its application entry point. Either mechanism can execute arbitrary code with the permissions of the invoking user.This finding does not establish that the named packages are currently malicious. The vulnerability is the unsafe dependency acquisition and execution pattern, which creates a supply-chain attack surface.
Attack Path
- An attacker compromises the publisher account, package release process, package registry entry, or a transitive dependency associated with one of the referenced packages.
- The attacker publishes a malicious release that becomes the version selected by npm's default resolution behavior.
- A user follows the Skill instructions and runs either `npm install -g ...[truncated 1210 chars]
- Remediation
View remediation
Remediation Suggestions
- Pin each dependency to an exact, reviewed version, for example
@wavespeed/cli@X.Y.Zand@wavespeed/mcp@X.Y.Z. - Replace automatic
npx -yexecution with a locally declared dependency installed from a committed lockfile. - Use
npm ciwith a reviewedpackage-lock.jsonso dependency resolution is reproducible. - Verify package provenance and integrity through npm integrity metadata, trusted publisher information, signatures, or published checksums before execution.
- Avoid global installation where possible. Install the CLI in a dedicated project or isolated environment with minimal filesystem and credential access.
- Review package lifecycle scripts and dependency changes before upgrading pinned versions.
- Do not run package installation or MCP execution with administrator or root privileges.
- For automated environments, constrain network access, filesystem access, and available environment variables while installing or running the packages.
- Pin each dependency to an exact, reviewed version, for example
