T08 · Insecure Dependencies
- Location
SKILL.md:19- Finding
Unpinned Third-Party Dependencies Create a Supply-Chain Risk
- Content
View full analysis
Vulnerability Details
File Location:
SKILL.md, lines 19-23
Vulnerability Type: Unpinned and integrity-unverified package installation
Risk Level: Mediumbash pip install --quiet akshare pandasAlternative installation instructions repeat the same unsafe dependency resolution behavior:
bash pip install --user --quiet akshare pandasTechnical Analysis
The installation instructions retrieve the latest available versions of
akshare,pandas, and their transitive dependencies without exact version constraints or cryptographic hashes. This makes installations non-reproducible and prevents pip from verifying that dependencies match artifacts previously reviewed by the project maintainers.If a package release, transitive dependency, package-index account, or configured package source is compromised, following these instructions could install attacker-controlled code. Python packages can execute code during installation through build backends, and dependency code also executes when imported or invoked. The project provides no lock file, hash-verified requirements file, or trusted-index enforcement to reduce this exposure.
No evidence was found that the currently named packages are malicious. The vulnerability is the unsafe dependency acquisition process rather than a confirmed compromise of either package.
Attack Path
- An attacker compromises a dependency release, maintainer account, transitive dependency, or package source used by pip.
- The attacker publishes a malicious version that satisfies the unconstrained installation request.
- A user follows the documented
pip installcommand. - Pip resolves and downloads the attacker-controlled artifact because no approved version or hash is specified.
- Malicious code executes during package build or installation, or later when
scripts/daily_review.pyimports and uses the dependency. - The payload runs with the permissions ...[truncated 731 chars]
- Remediation
View remediation
Remediation Suggestions
- Create a dependency lock or requirements file containing reviewed, exact versions for all direct and transitive dependencies.
- Record approved artifact hashes and install with pip's hash enforcement:
bash python3 -m pip install --require-hashes -r requirements.txt - Generate and review the locked dependency set using a tool such as
pip-tools, and update it through a controlled dependency-review process. - Require an isolated virtual environment rather than recommending user-wide installation:
bash python3 -m venv .venv . .venv/bin/activate python3 -m pip install --require-hashes -r requirements.txt - Configure installation to use an explicitly trusted package index or an organization-controlled artifact mirror.
- Add automated dependency scanning and provenance checks to the release process.
- Replace mutable upgrade guidance such as unrestricted
pip install -U aksharewith instructions to install a newly reviewed and hash-pinned dependency set. - Avoid running package installation with administrator or root privileges.
