T08 · Insecure Dependencies
Warning
- Location
- SKILL.md:5
- Finding
- Unpinned Third-Party Dependency Creates a Supply-Chain Risk## Vulnerability Details **File Location**: `SKILL.md`, lines 1-6 and 27-30 **Vulnerability Type**: `T08: Insecure Dependencies` **Risk Level**: Medium **Vulnerable code:** ```yaml --- name: agent-metrics version: 1.0.3 description: Observability and metrics for AI agents - track calls, errors, latency metadata: {"openclaw": {"emoji": "📊", "category": "utility", "requires": {"bins": ["python"], "pip": ["psutil"]}, "homepage": "https://github.com"}} --- ``` ```powershell # Install Python dependency pip install psutil ``` ### Technical Analysis The Skill declares and instructs users to install `psutil` without pinning an audited version or verifying a cryptographic hash. Consequently, dependency resolution selects whatever release satisfies the unconstrained package name at installation time. The installed code can therefore differ from the dependency that was present when the Skill was reviewed. This is a supply-chain weakness rather than evidence that the current `psutil` package is malicious. Exploitation would require compromise of the package's distribution account, the package index, or the dependency resolution path. If such a compromise occurred, malicious package code could run during installation or when `metrics.py` imports `psutil`. ### Attack Path 1. An attacker compromises the dependency publisher, package-index distribution process, or another relevant dependency resolution channel. 2. The attacker publishes a malicious or backdoored release under the expected `psutil` package name. 3. A user follows the documented `pip install psutil` command, which resolves the uncontrolled release because no version or hash is specified. 4. The malicious package executes code during installation or when `metrics.py` imports `psutil`. 5. That code operates with the privileges and environmental access of the user running the installation or Skill. ### Impact Assessment Successful exploitation could pe ...[truncated 442 chars]
- Remediation
- ## Remediation Suggestions 1. Pin `psutil` to a specifically reviewed version in the Skill metadata and installation documentation. 2. Provide a lock file or requirements file containing cryptographic hashes, and require hash verification during installation: ```text psutil==<reviewed-version> --hash=sha256:<verified-hash> ``` ```bash python -m pip install --require-hashes -r requirements.txt ``` 3. Generate hashes from artifacts obtained through a trusted process and review dependency updates before changing the pinned version. 4. Prefer a controlled package mirror or repository with integrity validation and restricted publishing controls. 5. Run installation and the Skill using a dedicated, least-privileged environment rather than an administrator or root account. 6. Incorporate automated dependency vulnerability and provenance checks into the release process.
