T08 · Insecure Dependencies
Warning
- Location
- SKILL.md:81
- Finding
- Unpinned Global Installation of a Third-Party CLI Package## Vulnerability Details **File Location**: `SKILL.md:81-86`; repeated at `SKILL.md:106-111, 401, 415` and `README.md:30, 38, 53` **Vulnerability Type**: Unpinned third-party dependency installed globally **Risk Level**: Medium **Vulnerable Code**: ```markdown If `storacha` is not found, install it: ```bash npm install -g @storacha/cli ``` ``` ### Technical Analysis The skill instructs the agent to install the latest available version of `@storacha/cli` from the npm registry. It does not specify an exact reviewed version, verify package integrity or provenance, use a lockfile, or request approval before performing a global installation. A global npm installation can execute package installation logic with the privileges of the account running the agent. The effective package contents can also change after this skill has been audited because npm resolves the command to the registry version current at execution time. The package name is consistent with the declared Storacha service, and the audited project contains no evidence that the current package is malicious. The risk arises from the unpinned and globally mutable dependency channel. ### Attack Path 1. An attacker compromises the npm package, a maintainer account, or the associated publication process. 2. The attacker publishes a malicious release under the expected `@storacha/cli` package name. 3. The skill detects that `storacha` is unavailable and executes `npm install -g @storacha/cli`. 4. npm retrieves the newly published package rather than a previously reviewed version. 5. Malicious package code or lifecycle scripts execute with the privileges of the agent user. 6. The compromised package can subsequently intercept files uploaded through the CLI or access authorization material available to that user. ### Impact Assessment Successful exploitation could execute arbitrary code as the account running npm, modify globally installed Node.js packages o ...[truncated 347 chars]
- Remediation
- ## Remediation Suggestions - Pin the CLI to an exact reviewed version, for example `@storacha/cli@X.Y.Z`. - Record and verify the expected package integrity hash and npm provenance before installation. - Prefer a project-local dependency with a lockfile over a global installation. - Require explicit user or administrator approval before installing software. - Run installation and the CLI under a dedicated, unprivileged account. - Disable npm lifecycle scripts with `--ignore-scripts` if the reviewed CLI remains functional without them. - Maintain an allowlist of approved package names, versions, publishers, and integrity values. - Update every repeated installation instruction in `SKILL.md` and `README.md` so users are not directed back to the unsafe command.
