T08 · Insecure Dependencies
Warning
- Location
- SKILL.md:4
- Finding
- Unpinned Executable Dependency Installed from a Mutable Git Branch## Vulnerability Details **File Location**: `SKILL.md`, lines 4 and 30–31 **Vulnerability Type**: Unpinned third-party Git dependency **Risk Level**: Medium The skill metadata and setup instructions install the `lk-print` executable directly from a Git repository without specifying an immutable commit, signed release, version constraint, or integrity digest. **Vulnerable code at line 4:** ```yaml metadata: {"openclaw":{"emoji":"🖨️","primaryEnv":"ApiKey","requires":{"bins":["lk-print"]},"install":[{"id":"uv","kind":"uv","package":"git+https://github.com/liankenet/ai-lk-print-box.git","bins":["lk-print"],"label":"Install lk-print (uv)"}]}} ``` **Vulnerable code at lines 30–31:** ```bash # Global installation (registers lk-print in PATH) uv tool install git+https://github.com/liankenet/ai-lk-print-box.git ``` ### Technical Analysis A Git URL with no commit hash or immutable release reference resolves to the repository's mutable default branch. Consequently, the code installed by users can differ from the code that was originally reviewed. Because `uv tool install` installs an executable into the user's environment, package build hooks or runtime code can execute with that user's privileges. The CLI is subsequently entrusted with an API key, device identifier, device key, local documents submitted for printing, scan results, and remote printer/scanner controls. A compromised upstream repository or malicious update could therefore replace legitimate CLI behavior with attacker-controlled logic. No evidence demonstrates that the current upstream package is malicious. The vulnerability is the absence of dependency immutability and integrity verification, which creates a supply-chain attack opportunity. ### Attack Path 1. An attacker compromises the upstream repository, a maintainer account, or the mutable default branch. 2. The attacker adds malicious package installation or CLI runtime code. 3. A user or agent follows ...[truncated 1138 chars]
- Remediation
- ## Remediation Suggestions 1. Pin the dependency to a reviewed immutable commit: ```bash uv tool install "git+https://github.com/liankenet/ai-lk-print-box.git@<reviewed-commit-sha>" ``` 2. Prefer a versioned, signed release from a trusted package registry rather than installing from a mutable Git branch. 3. Record and verify the expected artifact hash or lockfile integrity metadata before installation. 4. Enable signed commits or release signatures and verify them as part of the installation process. 5. Review dependency updates before changing the pinned revision, and use automated dependency and provenance scanning. 6. Run the CLI with least privilege and restrict its access to only the documents required for each operation. 7. Supply credentials through a protected secret mechanism, avoid exposing them in process arguments or logs, and rotate them if upstream compromise is suspected.
