T08 · Insecure Dependencies
Warning
- Location
- README.md:25
- Finding
- Unpinned Third-Party Code Execution During Installation## Vulnerability Details **File Locations**: - `README.md:25-32` - `SKILL.md:21-23` **Vulnerability Type**: Unpinned and mutable third-party dependencies executed through `npx` **Risk Level**: Medium ### Vulnerable Code `README.md:25-32`: ```bash npx add https://github.com/wpank/ai/tree/main/skills/meta/workflow-patterns ``` ```bash npx clawhub@latest install workflow-patterns ``` `SKILL.md:21-23`: ```bash npx clawhub@latest install workflow-patterns ``` ### Technical Analysis The documented installation commands instruct users to execute third-party content using `npx`. If a requested package is not already available locally, `npx` can retrieve and execute it, including its command-line entry point and potentially package lifecycle scripts. The `clawhub@latest` dependency uses a mutable version selector rather than an audited, exact version. The GitHub-based command similarly references remote repository content without pinning it to a reviewed commit hash or verifying its integrity. Consequently, the code executed when a user follows these instructions can differ from the code available when this project was audited. This does not establish that either current upstream source is malicious. The vulnerability is the lack of controls preventing a compromised registry account, package release, repository, branch, or transitive dependency from supplying altered executable content. ### Attack Path 1. An attacker compromises the package publisher, package registry account, upstream repository, mutable release channel, or a dependency used by the installer. 2. The attacker publishes malicious code under the version resolved by `@latest` or changes the remotely referenced repository content. 3. A user follows one of the documented `npx` installation commands. 4. `npx` downloads the altered package or installer from the external source. 5. The downloaded CLI code or package lif ...[truncated 1052 chars]
- Remediation
- ## Remediation Suggestions 1. Replace `clawhub@latest` with an exact, reviewed package version: ```bash npx clawhub@<reviewed-exact-version> install workflow-patterns ``` 2. Pin GitHub-hosted content to an immutable, reviewed commit hash rather than a mutable branch or repository path. 3. Publish and verify cryptographic checksums or signed release artifacts before installation. 4. Prefer a download, verification, and review workflow over immediately executing remotely resolved content. 5. Use lockfiles and package-manager integrity metadata for all direct and transitive dependencies where supported. 6. Document that installation should be performed without administrative privileges and in an isolated development environment. 7. Add an automated release process that verifies dependency provenance, signatures, integrity hashes, and the exact source revision associated with each documented installation command.
