T08 · Insecure Dependencies
- Location
- SKILL.md:146
- Finding
- Unpinned Installation of a Privileged Third-Party CLI<![CDATA[ ## Vulnerability Details **File Location**: `SKILL.md`, lines 146-153 **Vulnerability Type**: Unpinned and integrity-unverified package installation **Risk Level**: Medium ### Vulnerable Code ```markdown ## Dependencies Python packages (install once): ```shell pip install --upgrade zijizhang-cli ``` ⚠️ Requirement: `zijizhang-cli` version must be `0.0.28` or later ``` ### Technical Analysis The Skill instructs users or Agents to install the latest available version of `zijizhang-cli` using `pip install --upgrade`. It does not pin an exact audited version, verify a package hash, use a lockfile, or otherwise authenticate the installed artifact. A minimum-version requirement does not ensure that the package being installed is the version reviewed with this Skill. Because the CLI handles authentication state, company records, employee data, invoices, banking documents, payroll, and tax operations, it occupies a highly trusted position. If the package distribution account, registry release process, or another part of the dependency supply chain were compromised, this instruction could install modified code without warning. ### Attack Path 1. An attacker compromises the package publisher, release process, or package-distribution channel for `zijizhang-cli`. 2. The attacker publishes a malicious version satisfying the documented minimum version. 3. A user or Agent follows the Skill instructions and runs: ```shell pip install --upgrade zijizhang-cli ``` 4. `pip` resolves and installs the attacker-controlled release without checking an expected digest. 5. The malicious CLI executes during later account or financial operations. 6. It can access information supplied to the CLI, abuse locally stored authentication state, alter requests, or perform unauthorized actions with the user's existing account privileges. ### Impact Assessment Successful exploitation would execute dependency code with the operating-system privileges of the user runnin ...[truncated 495 chars]
- Remediation
- <![CDATA[ ## Remediation Suggestions 1. Replace the open-ended upgrade command with an exact, reviewed version: ```shell python -m pip install 'zijizhang-cli==0.0.28' ``` 2. Publish and verify cryptographic hashes: ```shell python -m pip install --require-hashes -r requirements.txt ``` 3. Maintain a reviewed lockfile or requirements file containing the exact version and expected wheel hash. 4. Document the expected package index and package publisher identity. 5. Avoid automatically upgrading to newly published versions before they have been reviewed. 6. Prefer an isolated virtual environment rather than modifying a shared Python installation. 7. Re-review the CLI whenever the pinned dependency is updated. ]]>
