T08 · Insecure Dependencies
Warning
- Location
- SKILL.md:81
- Finding
- Unpinned Third-Party Package Is Downloaded and Executed During Installation## Vulnerability Details **File Location**: `SKILL.md:81` **Vulnerability Type**: Supply-chain exposure through an unpinned executable dependency **Risk Level**: Medium ### Vulnerable Code ```bash npx skills add zhaoxinghua09-cell/agent-skills -g ``` ### Technical Analysis The documented installation command invokes `npx` without specifying an exact version or integrity value for the `skills` package. If the package is not already available locally, `npx` can download it from the configured npm registry and execute its entry point. Consequently, the code executed by this command is not fixed to the version reviewed with this project. A compromised package, compromised maintainer account, malicious future release, registry redirection, or unsafe npm configuration could cause different code to execute when a user follows the installation instructions. The `-g` option also requests global installation, increasing the scope of filesystem changes and potentially affecting other Agent environments for the same user. ### Attack Path 1. An attacker compromises the npm package, its publisher account, the configured registry, or a subsequently resolved release. 2. The attacker publishes a package version containing a malicious installation hook or executable entry point. 3. A user follows the documented `npx skills add ... -g` installation command. 4. `npx` resolves and downloads the attacker-controlled package version because no version or integrity constraint is present. 5. The malicious package executes with the permissions of the invoking user and can alter the global skill installation. This path requires compromise or malicious modification of the externally resolved package or package-distribution channel; the audited repository itself does not contain the remote payload. ### Impact Assessment Successful exploitation could provide arbitrary code execution with the invoking user's privileges. The resulting code coul ...[truncated 381 chars]
- Remediation
- ## Remediation Suggestions 1. Pin the executable package to a specific, audited version, for example: ```bash npx --yes skills@<audited-version> add zhaoxinghua09-cell/agent-skills -g ``` 2. Verify the pinned package's provenance and published integrity metadata before recommending it. 3. Prefer a lockfile, immutable artifact digest, or signed release where the installation mechanism supports one. 4. Avoid global installation by default. Document a user-local or isolated installation method unless global state is strictly necessary. 5. Pin the source skill repository to an immutable commit or signed release rather than relying on a mutable branch. 6. Document that users should not run the installer with administrator or root privileges. 7. Periodically reassess the pinned package and update it only after reviewing the new version.
