T08 · Insecure Dependencies
Warning
- Location
- README.md:20
- Finding
- Unpinned npm Package Execution Through npx## Vulnerability Details **File Location**: `README.md`, line 20 **Vulnerability Type**: Supply-chain risk from executing an unpinned package release **Risk Level**: Medium **Vulnerable Code Snippet**: ```bash npx clawfi@latest install clawfi ``` ### Technical Analysis The documented installation command instructs users to execute the release currently associated with the npm `latest` tag. This tag is mutable and does not identify a specific, previously reviewed package version. The audited project contains only `README.md` and `skill.md`; it does not include the npm package manifest, lockfile, integrity hash, or installer implementation needed to verify the claim that the package only copies the Skill document. Consequently, the code ultimately executed by `npx` lies outside the reviewed artifact and may change after this audit. This does not establish that the current npm package is malicious. It creates a supply-chain vulnerability because compromise of the publisher account, package registry, release pipeline, or a future release could convert the documented installation process into arbitrary local code execution. ### Attack Path 1. An attacker compromises the npm publisher account, package release process, or another component controlling the `clawfi` package. 2. The attacker publishes a malicious package version and assigns it to the `latest` distribution tag. 3. A user follows the README and runs `npx clawfi@latest install clawfi`. 4. `npx` retrieves and executes the attacker-controlled package code. 5. The malicious installer executes with the permissions of the invoking user and may access or alter resources available to that account. ### Impact Assessment Successful exploitation could provide arbitrary code execution under the installing user's account. Depending on that account's permissions and environment, an attacker could read or modify user files, access locally available credentials and agent conf ...[truncated 792 chars]
- Remediation
- ## Remediation Suggestions 1. Replace `@latest` with an explicitly reviewed and immutable package version. 2. Provide the complete installer source and package manifest in the audited repository so its behavior can be reviewed. 3. Publish and document npm integrity information or cryptographic release signatures, and require verification before execution. 4. Pin dependencies and commit an appropriate lockfile for the installer implementation. 5. Avoid elevated execution and instruct users not to run the installer with `sudo` or an administrator account. 6. Where practical, offer a non-executable installation method that copies a reviewed `skill.md` directly into the appropriate directory. 7. Protect package publication with phishing-resistant multi-factor authentication, restricted release tokens, provenance attestations, and controlled CI-based publishing.
