T08 · Insecure Dependencies
Warning
- Location
- SKILL.md:23
- Finding
- Unpinned Dependency Installation in a System-Wide OpenClaw Directory## Vulnerability Details **File Location**: `SKILL.md`, lines 23-25 **Vulnerability Type**: `T08: Insecure Dependencies` **Risk Level**: Medium ### Vulnerable Code ```bash cd /usr/local/lib/node_modules/openclaw pnpm add @matrix-org/matrix-sdk-crypto-nodejs pnpm rebuild @matrix-org/matrix-sdk-crypto-nodejs ``` ### Technical Analysis The repair procedure installs a third-party package without specifying an exact version, verifying an integrity hash, requiring a reviewed lockfile, or validating the registry source. The package is installed directly into a system-wide OpenClaw installation. Package installation and rebuild operations may execute package lifecycle or native build scripts. Consequently, the effective code executed by this procedure can change after the skill has been reviewed. A compromised registry account, malicious package release, registry substitution, or unexpectedly incompatible update could introduce arbitrary code into the OpenClaw environment. ### Attack Path 1. An attacker compromises the package, its publisher account, or the package registry resolution path. 2. The attacker publishes a malicious version or causes the package name to resolve to an unsafe source. 3. An administrator follows the documented repair procedure. 4. `pnpm add` selects the mutable registry version because no exact version is specified. 5. Installation or rebuild scripts execute with the privileges of the administrator running the command. 6. The malicious component gains access to the OpenClaw installation and data available to that account. ### Impact Assessment Exploitation could modify the system-wide OpenClaw installation, execute package lifecycle code, read configuration and credentials accessible to the invoking account, or compromise the gateway process. The exact privilege level depends on the account used to run the package manager; running the instructions with elevated privileges would significantly in ...[truncated 18 chars]
- Remediation
- ## Remediation Suggestions - Pin the dependency to a reviewed exact version rather than relying on the latest registry-selected release. - Use a committed and reviewed lockfile containing integrity metadata. - Explicitly configure and verify the trusted package registry. - Verify package signatures, provenance, and published checksums where available. - Disable package lifecycle scripts during installation unless they are strictly required and audited. - Test dependency updates in an isolated staging environment before modifying a system-wide installation. - Run package-management operations with the least privileges necessary.
