T08 · Insecure Dependencies
Warning
- Location
- SKILL.md:5
- Finding
- Execution of an Unverified Third-Party npm Package## Vulnerability Details **File Location**: `SKILL.md:5, 57-63`; equivalent instructions appear in `SKILL-cn.md:5, 57-63` **Vulnerability Type**: T08: Insecure Dependencies **Risk Level**: Medium **Complete Code Snippet**: ```yaml metadata: {"clawdbot":{"emoji":"🤖","requires":{"bins":["npm","npx"]},"install":"npm install -g @dlazy/cli@1.2.3","installAlternative":"npx @dlazy/cli@1.2.3","homepage":"https://github.com/dlazy-ai/cli","source":"https://github.com/dlazy-ai/cli","author":"dlazyai","license":"see-repo","npm":"https://www.npmjs.com/package/@dlazy/cli","configLocation":"~/.dlazy/config.json","apiEndpoints":["api.dlazy.com","files.dlazy.com"]},"openclaw":{"systemPrompt":"When invoking this skill, use dlazy seedream-5.0 -h for help."}} ``` ```bash npx @dlazy/cli@1.2.3 <command> ``` ```bash npm install -g @dlazy/cli@1.2.3 ``` ### Technical Analysis The Skill instructs users or agents to install or directly execute the external npm package `@dlazy/cli`. Although the dependency is pinned to version `1.2.3`, the project does not include the package implementation, a trusted artifact digest, a lockfile with integrity metadata, or another mechanism that cryptographically binds execution to code reviewed as part of this audit. Both `npm install -g` and `npx` may execute package lifecycle scripts during installation. The installed CLI subsequently runs with the privileges of the invoking user and is entrusted with the user's dLazy API key, prompts, selected local files, and output paths. The global installation option also persists executable third-party code outside the audited Skill directory. No evidence in the reviewed files demonstrates that `@dlazy/cli@1.2.3` is malicious. The finding concerns the unaudited supply-chain trust boundary and the absence of artifact integrity verification. ### Attack Path 1. An attacker compromises the npm publisher account, registry artifact, or another component of the packa ...[truncated 1699 chars]
- Remediation
- ## Remediation Suggestions 1. Vendor the required CLI implementation into a controlled repository and perform a source-code and build-pipeline review before distribution. 2. Publish and verify a trusted cryptographic digest for the exact npm tarball before installation or execution. 3. Use a project-local dependency with a committed lockfile containing registry integrity metadata rather than a global installation. 4. Disable npm lifecycle scripts where compatible, such as with `--ignore-scripts`, and explicitly review any scripts required for operation. 5. Prefer a reproducible build and signed release artifacts with documented provenance. 6. Run the CLI in a sandbox or restricted environment with access limited to required network destinations and explicitly selected input/output files. 7. Avoid exposing unrelated environment variables or filesystem locations to the CLI. 8. Store the API key with restrictive file permissions, use a narrowly scoped credential where supported, and provide clear rotation and revocation procedures. 9. Apply the same hardened installation instructions to both `SKILL.md` and `SKILL-cn.md` so the two versions remain security-equivalent.
