T08 · Insecure Dependencies
Warning
- Location
- README.md:17
- Finding
- Unpinned npm Package Execution During Installation## Vulnerability Details **File Location**: `README.md:17-23` **Vulnerability Type**: Unpinned third-party package execution **Risk Level**: Medium **Vulnerable Code:** ```markdown ## Installation ```bash npx clawdhub install ascii-art-generator ``` Or manually install by copying the skill folder to your Clawdbot skills directory. ``` ### Technical Analysis The documented installation command invokes `clawdhub` through `npx` without specifying an exact package version, integrity hash, lockfile, or trusted package source. If the package is not already available locally, `npx` can retrieve it from the configured npm registry and execute its CLI code. Consequently, the code executed during installation is not fully represented by the audited project. Its behavior can change after this project has been reviewed. A compromised publisher account, malicious package release, registry compromise, dependency compromise, or unexpected upstream update could cause arbitrary code to run when a user follows the installation instructions. This finding concerns the unpinned installer dependency. No malicious behavior was identified in the Python scripts shipped in the audited project. ### Attack Path 1. An attacker compromises the npm package, its publisher account, one of its executable dependencies, or the registry resolution path. 2. The attacker publishes or serves a malicious version under the package name `clawdhub`. 3. A user follows the README and runs `npx clawdhub install ascii-art-generator`. 4. `npx` resolves and downloads the unpinned package version from the configured registry. 5. The downloaded package or its dependency code executes with the privileges of the user running the command. 6. The malicious code can access resources available to that user and may alter the installation process or install additional payloads. ### Impact Assessment Successful exploitation could provide arbitrary code execution w ...[truncated 436 chars]
- Remediation
- ## Remediation Suggestions 1. Pin the installer to a specifically reviewed version, for example: ```bash npx --yes clawdhub@<audited-version> install ascii-art-generator ``` 2. Document the expected npm registry, publisher identity, package version, and verification procedure. 3. Verify package integrity using a trusted lockfile, registry integrity metadata, signed provenance, or a published checksum where supported. 4. Prefer a separately installed and administratively approved CLI. If the tool must already be installed, use a mode that prevents network retrieval, such as: ```bash npx --no-install clawdhub install ascii-art-generator ``` 5. Retain the documented manual installation option and provide checksum or signature verification for the Skill archive. 6. Run installation with an unprivileged account in an isolated environment, and avoid exposing unnecessary secrets or credentials to the installer process. 7. Periodically review the pinned package and its transitive dependencies before updating the documented version.
