T08 · Insecure Dependencies
Error
- Location
- SKILL.md:35
- Finding
- Mutable External Repository Is Retrieved and Installed Without Integrity Verification<![CDATA[ ## Vulnerability Details **File Location**: `SKILL.md:35-37`; `_meta.json:18-20, 39-52` **Vulnerability Type**: Unpinned third-party dependency and unsafe external source installation **Risk Level**: High ### Vulnerable Code `SKILL.md:35-37`: ```bash git clone https://github.com/ZhenRobotics/openclaw-video.git ~/openclaw-video-pro cd ~/openclaw-video-pro npm install ``` `_meta.json:18-20`: ```json "dependencies": { "openclaw-video": "git+https://github.com/ZhenRobotics/openclaw-video.git" }, ``` `_meta.json:39-52`: ```json "install": [ { "id": "project", "kind": "git", "repo": "https://github.com/ZhenRobotics/openclaw-video.git", "target": "~/openclaw-video-pro", "label": "克隆视频生成项目" }, { "id": "deps", "kind": "npm", "package": "安装依赖", "cwd": "~/openclaw-video-pro", "label": "安装项目依赖" } ] ``` ### Technical Analysis The installation process clones the mutable default branch of an external Git repository and subsequently installs its npm dependencies. No reviewed commit SHA, immutable release artifact, checksum, signature, or dependency lockfile is specified. Consequently, the effective code executed by users can change after this Skill package has been audited. In addition, npm installation may execute package lifecycle scripts such as `preinstall`, `install`, and `postinstall`. These scripts run with the privileges of the user performing the installation. The external dependency repository is also different from the repository declared as the Skill's own repository. That relationship is not protected by any technical trust or integrity mechanism. ### Attack Path 1. An attacker compromises the external Git repository, a maintainer account, or one of its transitive npm dependencies. 2. The attacker modifies the default branch or publishes a dependency version containing a malicious lifecycle script. 3. A user follows the documented installation process or the platform processes the installation ...[truncated 850 chars]
- Remediation
- <![CDATA[ ## Remediation Suggestions 1. Pin the external repository to a reviewed commit SHA rather than its default branch. 2. Prefer a signed, immutable release artifact and verify its cryptographic checksum before use. 3. Include a reviewed npm lockfile and use `npm ci` instead of `npm install`. 4. Use `npm ci --ignore-scripts` when lifecycle scripts are unnecessary. If scripts are required, audit and explicitly allow them. 5. Pin and audit all direct and transitive dependencies. 6. Run installation in a sandbox with minimal filesystem access, no unnecessary credentials, and restricted network access. 7. Clearly document why the external repository differs from the Skill repository and define the trusted version. 8. Add automated dependency and integrity checks to the release process. ]]>
