T08 · Insecure Dependencies
Warning
- Location
- README.md:24
- Finding
- Unpinned npx Installer Creates a Mutable Supply-Chain Execution Path## Vulnerability Details **File Location**: `README.md:24` **Vulnerability Type**: Unpinned third-party installer and mutable source reference **Risk Level**: Medium **Vulnerable Code Snippet**: ```bash npx add https://github.com/wpank/ai/tree/main/skills/tools/finishing-branch ``` ### Technical Analysis The installation command invokes `npx add` without pinning the `add` npm package to a reviewed version. Depending on the local npm environment, `npx` can download and execute the package resolved under that name. The command also references the mutable `main` branch of a remote GitHub repository rather than a specific reviewed commit. Consequently, the effective installation code and installed content can change after this project has been audited. No checksum, signature, package lock, or commit identifier is used to verify the retrieved components. This is an insecure dependency and installation pattern. The audited repository does not itself contain evidence that the current remote package or repository is malicious, but the documented command establishes a supply-chain execution path that could become malicious following compromise or unauthorized modification of either source. ### Attack Path 1. An attacker compromises, takes control of, or maliciously updates the npm package resolved as `add`, or modifies the referenced GitHub repository's `main` branch. 2. The attacker adds malicious installation or lifecycle behavior to the affected component. 3. A user follows the documented installation command. 4. `npx` resolves and potentially executes the unpinned npm package, while the installer retrieves content from the mutable remote branch. 5. The malicious code executes with the operating-system privileges and environment access of the user running the installation. ### Impact Assessment Successful exploitation could execute arbitrary commands with the installing user's privileges. Depending on that user's environ ...[truncated 374 chars]
- Remediation
- ## Remediation Suggestions - Replace the generic `npx add` invocation with a trusted installer pinned to an exact, reviewed version. - Pin the remote project to an immutable commit hash rather than the `main` branch. - Publish and verify a cryptographic checksum or signature for the installed content. - Disable or avoid package lifecycle scripts where they are unnecessary. - Prefer a transparent installation procedure that downloads or copies reviewed files without executing an unrelated npm package. - Document the exact expected commit and verification command so users can validate the source before installation.
