T08 · Insecure Dependencies
- Location
SKILL.md:156- Finding
Unpinned Third-Party CLI Installation Creates a Supply-Chain Execution Risk
- Content
View full analysis
Vulnerability Details
File Location:
SKILL.md, lines 156-167
Vulnerability Type: Unpinned third-party dependency installation
Risk Level: MediumVulnerable Code
markdown When the skill is already published and needs a version update on ClawHub, use the `clawhub` CLI: **Prerequisites:** - Node.js environment with clawhub package installed: ``` npm install clawhub ``` - ClawHub account with device flow login (headless-friendly): ``` clawhub login --device # Visit the provided URL, enter the code, authorize in browser # Note: login process must stay running in background while user authorizes ```Technical Analysis
The workflow instructs the Agent to install the current registry version of the
clawhubnpm package without specifying an exact version, lockfile, package integrity hash, or verified publisher identity. Consequently, the dependency resolved during execution may differ from the dependency that existed when the Skill was audited.npm packages may define installation lifecycle scripts. If such scripts are enabled, a compromised, malicious, or unexpectedly modified package release could execute code as the operating-system user running the Agent. The package would potentially have access to the Agent workspace, user-readable files, environment variables, and active credentials.
The dependency installation is relevant to optional ClawHub publication, but installing an unrestricted latest version exceeds the minimum necessary trust boundary. The Skill should identify and constrain the exact audited dependency release.
Attack Path
- An attacker compromises the npm package, its maintainer account, or a future package release.
- The attacker publishes a malicious version containing an installation lifecycle script or malicious CLI behavior.
- A user requests publication of a Skill to ClawHub.
- The Agent follows the documented prerequisite and ...[truncated 963 chars]
- Remediation
View remediation
Remediation Suggestions
- Pin the CLI to a reviewed exact version, for example
npm install --save-exact clawhub@X.Y.Z. - Use a committed lockfile and verify the package integrity hash before installation.
- Document the official npm package name, publisher, and expected registry.
- Prefer installation in an isolated environment with access only to the repository intended for publication.
- Disable lifecycle scripts with
--ignore-scriptsunless the audited package demonstrably requires them. - If lifecycle scripts are required, inspect the resolved package contents and scripts before installation.
- Run the CLI with minimal filesystem and environment-variable access.
- Avoid exposing unrelated Git, npm, cloud, or API credentials to the installation process.
- Re-audit and deliberately update the pinned version rather than automatically accepting the latest release.
- Pin the CLI to a reviewed exact version, for example
