T08 · Insecure Dependencies
- Location
Skill.md:13- Finding
Unpinned Third-Party npm Packages Are Installed and Executed
- Content
View full analysis
Vulnerability Details
File Location:
Skill.md, lines 13, 277, and 329
Vulnerability Type: Unpinned third-party dependency installation and execution
Risk Level: MediumVulnerable Code
bash # Skill.md:13 which prismer || npm install -g @prismer/sdkmarkdown <!-- Skill.md:277 --> | **MCP Server** | `npx -y @prismer/mcp-server` (33 tools) |markdown <!-- Skill.md:329 --> | MCP Server | `@prismer/mcp-server` | `npx -y @prismer/mcp-server` (33 tools) |Technical Analysis
The documented commands resolve npm packages without pinning exact, previously reviewed versions or requiring integrity and provenance verification.
npm install -g @prismer/sdkinstalls the currently resolved package globally and may execute npm lifecycle scripts with the invoking user's privileges. The global installation also modifies the user's persistent tooling environment.npx -y @prismer/mcp-serveris more direct: it automatically accepts installation, downloads the currently resolved package release, and executes its entry point. Because no version is pinned, the code executed by users may differ from the code that was previously audited. The documented MCP server exposes 33 tools, potentially increasing the resources available to a compromised process.This is a supply-chain weakness rather than evidence that the named packages are currently malicious. Exploitation would require package-publisher compromise, registry compromise, publication of a malicious release, or another dependency-resolution attack.
Attack Path
- An attacker compromises the npm publisher account, package distribution process, registry path, or a transitive dependency.
- The attacker publishes a malicious release under
@prismer/sdkor@prismer/mcp-server. - A user or agent follows
Skill.mdand runs the unpinned installation ornpx -ycommand. - npm resolves the attacker-controlled release becau ...[truncated 1081 chars]
- Remediation
View remediation
Remediation Suggestions
- Pin every package to an exact reviewed version, for example
@prismer/sdk@X.Y.Zand@prismer/mcp-server@X.Y.Z; do not use ranges or implicitlatestresolution. - Replace
npx -ywith a locally declared, lockfile-pinned dependency. Execute the local binary only after dependency review and installation. - Avoid global installation. Prefer a project-local installation in a dedicated directory or isolated environment.
- Commit and enforce an npm lockfile with integrity hashes. Use
npm ciin automated environments so dependency resolution cannot drift silently. - Verify package provenance, publisher identity, registry source, signatures or attestations, and expected integrity before execution.
- Review direct and transitive dependencies and monitor them for publisher changes, unexpected releases, known vulnerabilities, and suspicious lifecycle scripts.
- Require explicit user approval before downloading or executing packages. Do not automatically approve package installation in privileged agent workflows.
- Run the MCP server with least privilege in a sandbox or container. Restrict filesystem access, environment variables, credentials, network egress, and exposed tools to those strictly required.
- Document trusted package versions and a controlled upgrade procedure that includes source review, integrity verification, testing, and rollback.
- Pin every package to an exact reviewed version, for example
