T08 · Insecure Dependencies
- Location
- references/setup.md:18
- Finding
- Unpinned npm Packages Are Downloaded, Executed, and Globally Installed<![CDATA[ ## Vulnerability Details **File Location**: `references/setup.md:18-28`, `references/setup.md:36-63`, and `references/setup.md:110-111` **Vulnerability Type**: Supply-chain exposure through unpinned remote packages **Risk Level**: High ### Complete Code Snippet ```bash # Plan a capability gap — free, runs nothing, prints the exact calls to make: npx -y @vaaya/mcp consult "<what you want to do>" # Run one of those calls (bills on success; flags mirror the `use` tool's params): npx -y @vaaya/mcp use --service <s> --action <a> --params '<json>' --max-cost <cents> # Poll an async job (e.g. a video render) — add --wait to block until it's done: npx -y @vaaya/mcp result <job_id> --wait ``` ```bash npx -y @vaaya/mcp install ``` ```bash npx -y @vaaya/mcp install --token <vst_…> ``` ```text Either form is also available as `npx -y vaaya-cli install [--token <vst_…>]`, which is the same installer reached through the `vaaya` command's own package. This runs the published [`@vaaya/mcp`](https://www.npmjs.com/package/@vaaya/mcp) package and does exactly two things: it wires Vaaya into whichever agents it finds (Claude Code, Claude Desktop, Cursor, Codex) by editing their MCP config files (`~/.claude.json`, `~/.cursor/mcp.json`, `~/.codex/config.toml`, Claude Desktop's config), and it runs `npm i -g vaaya-cli` for the `vaaya` command (skip that with `--no-cli`; if the global install fails it says so and carries on). ``` ### Technical Analysis The setup procedure uses `npx -y` without pinning an immutable package version or verifying an integrity digest. Consequently, the package resolved by npm at execution time can differ from the version that existed when the Skill was audited. The `-y` option also suppresses the normal installation confirmation. The downloaded package is not limited to a transient query. It is instructed to modify several agent configuration files and run `npm i -g vaaya-cli`, giving the package code execution under the invoking user's ...[truncated 1770 chars]
- Remediation
- <![CDATA[ ## Remediation Suggestions 1. Pin every invoked package to a reviewed exact version, such as `@vaaya/mcp@X.Y.Z`, rather than resolving the latest release. 2. Publish and verify npm provenance, signatures, and integrity hashes before execution. 3. Lock and audit transitive dependencies and prohibit unexpected lifecycle scripts. 4. Remove `-y` so the user can review what will be installed. 5. Separate temporary CLI use from persistent installation. Do not globally install `vaaya-cli` unless the user explicitly requests it. 6. Display a dry-run diff of every configuration file before modification and require approval for each target application. 7. Apply least privilege by modifying only the configuration selected by the user rather than every detected agent. 8. Prefer a sandboxed or locally vendored reviewed installer where practical. 9. Document uninstall and rollback procedures for the global binary and all modified configuration files. ]]>
