T08 · Insecure Dependencies
Warning
- Location
- README.md:27
- Finding
- Unpinned npm Installer and Mutable Remote Skill Source## Vulnerability Details **File Location**: `README.md`, lines 27-29 **Vulnerability Type**: Supply-chain exposure through unpinned executable and mutable remote source **Risk Level**: Medium ### Vulnerable Code ```bash npx add https://github.com/wpank/ai/tree/main/skills/backend/microservices-patterns ``` ### Technical Analysis The documented installation command invokes `npx` without pinning the `add` package to an exact, reviewed version. Depending on the local npm environment and cache state, `npx` can retrieve and execute that package dynamically. The effective installer implementation can therefore differ from the implementation that was available when this project was audited. The skill is also retrieved from the mutable `main` branch of a remote GitHub repository. No immutable commit identifier, checksum, package integrity value, or signature is specified. A later upstream modification or compromise could consequently alter the content installed by the same documented command. This is a supply-chain weakness rather than evidence that the currently referenced package or repository is malicious. The risk arises because trust is delegated to mutable third-party resources at installation time without integrity verification. ### Attack Path 1. An attacker compromises the npm package used by `npx`, the package publisher account, the referenced GitHub account, or the upstream repository. 2. The attacker publishes a modified installer version or changes content reachable through the repository's `main` branch. 3. A user follows the installation command from `README.md`. 4. `npx` retrieves and executes the unpinned installer, which then processes content from the mutable remote source. 5. Malicious installer code could execute under the user's account, or modified skill instructions could be placed in the user's agent configuration. 6. The resulting access is limited by the privileges of the user running the command, bu ...[truncated 842 chars]
- Remediation
- ## Remediation Suggestions 1. Pin the installer to an exact, reviewed npm package version rather than invoking an unspecified version: ```bash npx --yes add@<reviewed-version> <immutable-source> ``` 2. Confirm that `add` is the intended and trusted installer package. Prefer a purpose-specific installer with documented ownership and provenance. 3. Reference an immutable Git commit instead of the mutable `main` branch. 4. Publish and verify a cryptographic checksum or signed release artifact before installation. 5. Use npm lockfiles and integrity metadata where installation occurs within a managed project. 6. Avoid executing remote installers where a non-executable download-and-review workflow is sufficient. Download the skill at a pinned revision, inspect it, and copy the reviewed files into the target directory. 7. Run installation with an unprivileged account in an isolated environment that does not expose production credentials. 8. Document the expected package digest, repository commit, and installed file list so users can verify provenance and detect upstream changes.
