T08 · Insecure Dependencies
Warning
- Location
- SKILL.md:21
- Finding
- Unpinned Third-Party Package Execution Through npx## Vulnerability Details **File Location**: `SKILL.md`, lines 21–24 **Vulnerability Type**: Unpinned third-party dependency execution **Risk Level**: Medium **Complete Code Snippet**: ```markdown ## Usage ```bash npx openclaw skill run agent-git-oracle --path ./your-repo ``` ``` ### Technical Analysis The documented command invokes `openclaw` through `npx` without specifying an exact package version. If the package is not already installed locally, `npx` may resolve, download, and execute the package from the configured npm registry. The project provides no lockfile, integrity hash, trusted-registry restriction, or other provenance control for this dependency. Therefore, the code ultimately executed by users may differ from the code available when this Skill was audited. This creates a supply-chain risk: compromise of the package, its publication account, its transitive dependencies, or the configured registry could cause attacker-controlled code to run when users follow the documented usage instructions. ### Attack Path 1. An attacker compromises or replaces the `openclaw` package, a relevant transitive dependency, or the registry infrastructure used by the victim. 2. The attacker publishes a malicious package version that includes hostile lifecycle or runtime behavior. 3. A user follows the documented command: ```bash npx openclaw skill run agent-git-oracle --path ./your-repo ``` 4. Because no exact version is pinned, `npx` resolves the package according to the user's environment and registry configuration. 5. The downloaded package or its dependencies execute with the privileges of the invoking user. 6. The malicious code can access resources available to that user, including the repository supplied through `--path`. ### Impact Assessment Successful exploitation could permit arbitrary code execution with the invoking user's privileges. Within that permission boundary, an attacker could read or ...[truncated 584 chars]
- Remediation
- ## Remediation Suggestions 1. Pin `openclaw` to an exact, reviewed version rather than relying on registry resolution of the current version. 2. Install the dependency locally using a committed lockfile that records exact dependency versions and integrity hashes. 3. Invoke the reviewed local dependency with `npx --no-install` so execution fails instead of downloading an absent package. 4. Configure an explicitly trusted npm registry and enforce package provenance or signature verification where supported. 5. Audit the selected package version and its transitive dependencies before use, and apply controlled dependency updates only after review. 6. Run repository-analysis tooling in a sandbox or container with read-only repository access, minimal environment variables, no unnecessary credentials, and restricted network access. 7. Document the expected package publisher, exact version, integrity information, and verification procedure in the Skill instructions.
