T08 · Insecure Dependencies
- Location
SKILL.md:69- Finding
Unpinned Global Installation of a Third-Party CLI Package
- Content
View full analysis
Vulnerability Details
File Location:
SKILL.md, line 69
Vulnerability Type: Unpinned third-party dependency installed globally
Risk Level: MediumVulnerable Code Snippet:
markdown 1. **RunComfy CLI** — `npm i -g @runcomfy/cli`Technical Analysis
The installation command retrieves the latest available version of
@runcomfy/clifrom the configured npm registry. It does not specify an exact version, lock the resolved dependency tree, or verify package integrity against a documented checksum.Because npm packages may execute lifecycle scripts during installation, the effective code executed by this command can change after the Skill has been reviewed. The global installation option also places the package into the user's global npm environment, increasing its reach beyond the project directory. This creates a supply-chain risk if the package, its publishing account, one of its transitive dependencies, or the configured registry is compromised.
The audit did not establish that the current package is malicious. The vulnerability is the unsafe, mutable dependency-installation procedure.
Attack Path
- An attacker compromises the npm package, a maintainer account, a transitive dependency, or the registry resolution path.
- The attacker publishes a malicious version that becomes the version selected by the unpinned installation command.
- A user follows the documented prerequisite and runs
npm i -g @runcomfy/cli. - npm downloads the attacker-controlled package and may execute its installation lifecycle scripts with the installing user's privileges.
- The malicious package can persist in the user's global npm installation and execute again when the
runcomfycommand is invoked. - If accessible to that user, the malicious code could read
RUNCOMFY_TOKENor~/.config/runcomfy/token.json, access other user-readable files, modify user-writable resources, or submit unauthorized API reque ...[truncated 739 chars]
- Remediation
View remediation
Remediation Suggestions
-
Pin the CLI to an exact, reviewed version, for example:
bash npm install --global @runcomfy/cli@X.Y.Z -
Document the expected package provenance and integrity value, and verify the downloaded package before installation.
-
Prefer a project-local dependency with a committed lockfile over a global installation so the resolved dependency graph remains reproducible.
-
Review the pinned package and its transitive dependencies for lifecycle scripts and known vulnerabilities.
-
Where compatible with the package, disable lifecycle scripts during installation:
bash npm install --global --ignore-scripts @runcomfy/cli@X.Y.Z -
Do not run the installation with administrative privileges unless strictly necessary.
-
Execute the CLI in a restricted environment with access only to required media, output directories, network destinations, and credentials.
-
Use a narrowly scoped, revocable RunComfy token and rotate it if package compromise is suspected.
-
