T08 · Insecure Dependencies
Warning
- Location
- SKILL.md:16
- Finding
- Unpinned Third-Party Packages Are Installed and Executed## Vulnerability Details **File Location**: `SKILL.md`, lines 16–23 **Vulnerability Type**: Unpinned and automatically executed third-party dependencies **Risk Level**: Medium **Code Snippet**: ```bash npm install -g @wavespeed/cli wavespeed login # opens https://wavespeed.ai/accesskey and stores the key wavespeed status # confirms you are signed in ``` ```markdown 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`). It shares the CLI's stored login. ``` ### Technical Analysis The skill instructs users or agents to install `@wavespeed/cli` globally and to download and execute `@wavespeed/mcp` through `npx -y`. Neither dependency is pinned to a reviewed version or verified with an integrity hash. Package installation can execute npm lifecycle scripts, while `npx -y` automatically resolves, downloads, and runs the package without an interactive confirmation. The code executed by these commands can therefore change after the skill has been audited. A compromised publisher account, malicious package release, or transitive dependency compromise could introduce attacker-controlled code. The global installation also creates a persistent command in the user's environment. Although no malicious persistence mechanism is present in the reviewed skill itself, the installation increases the consequences of a supply-chain compromise because the resulting executable may remain available after the skill run. ### Attack Path 1. An attacker compromises the publisher account, package release process, or dependency chain for `@wavespeed/cli` or `@wavespeed/mcp`. 2. The attacker publishes a malicious version under the same package name. 3. A user or agent follows the documented setup and runs the unversioned `npm ...[truncated 1207 chars]
- Remediation
- ## Remediation Suggestions 1. Pin each package to an exact, reviewed version rather than resolving the latest available release: ```bash npm install --global @wavespeed/cli@<reviewed-version> npx --yes @wavespeed/mcp@<reviewed-version> ``` 2. Prefer a project-local installation governed by a committed lockfile over global installation. 3. Use npm integrity verification, trusted provenance, and package-signing controls where available. 4. Review package contents and lifecycle scripts before approving a version for use. 5. Avoid automatic `npx -y` execution. Install the reviewed dependency explicitly and invoke its local binary. 6. Run the tools in a restricted environment with only the files and environment variables required for the video-generation task. 7. Establish a controlled dependency-update process that repeats security review before changing pinned versions. 8. Document the expected publisher, repository, package version, and checksum so users can verify that they obtained the approved artifact.
