T08 · Insecure Dependencies
- Location
SKILL.md:38- Finding
Unpinned Third-Party Package Installation and Execution
- Content
View full analysis
Vulnerability Details
File Location:
SKILL.md, lines 38–40
Vulnerability Type: Unpinned and automatically executed npm dependency
Risk Level: MediumVulnerable code:
bash # 1. Install (one of — see runcomfy-cli skill for details) npm i -g @runcomfy/cli # global install npx -y @runcomfy/cli --version # zero-installTechnical Analysis
The documented installation commands resolve
@runcomfy/cliwithout specifying an exact, previously audited version. Consequently, the package and its transitive dependencies may change after the Skill itself has been reviewed.The
npx -ycommand automatically approves package retrieval and execution. The global installation alternative may also run npm lifecycle scripts and places the package in a persistent, broadly accessible installation location. If the package publisher, npm account, registry distribution process, or a transitive dependency is compromised, following these instructions could execute attacker-controlled code with the permissions of the invoking user.The use of a scoped npm package reduces accidental typo-squatting exposure, but it does not protect against compromised releases, maintainer-account takeover, malicious dependency updates, or mutable package tags.
Attack Path
- An attacker compromises the
@runcomfy/clipublishing account, release pipeline, or one of its transitive dependencies. - The attacker publishes a malicious package version that is selected by npm because the commands do not pin an exact version.
- A user or agent follows the instructions in
SKILL.md. npm i -gornpx -ydownloads the malicious version and executes package code or lifecycle scripts.- The payload runs with the invoking user's permissions.
- The payload may access credentials available to that process, including
RUNCOMFY_TOKENor the documented token file at `~/.config/runcomfy/ ...[truncated 790 chars]
- An attacker compromises the
- Remediation
View remediation
Remediation Suggestions
- Pin
@runcomfy/clito an exact, reviewed version rather than resolving the latest available release:bash npm install --save-exact @runcomfy/cli@X.Y.Z npx --no-install runcomfy --version - Prefer a project-local, lockfile-backed installation over a global installation. Commit and review
package-lock.json, and usenpm cito enforce the locked dependency graph. - Avoid
npx -yfor packages that are not already installed and verified. Require explicit operator approval before downloading or executing new package versions. - Verify npm package provenance, publisher identity, registry source, integrity hashes, and release signatures where available.
- Review transitive dependencies and use automated dependency scanning before updating the pinned version.
- Consider disabling lifecycle scripts during installation with
--ignore-scriptsif the CLI functions correctly without them. If lifecycle scripts are required, document and review each expected script. - Run the CLI with least privilege in an isolated environment, expose only the required token and files, and avoid invoking npm as an administrator or root user.
- Pin
