T08 · Insecure Dependencies
- Location
SKILL.md:25- Finding
Dependency installation lacks cryptographic artifact verification
- Content
View full analysis
Vulnerability Details
File Location:
SKILL.md:25-29; related dependency declarations inrequirements.txt:1-2
Vulnerability Type: Unverified third-party dependency installation
Risk Level: MediumVulnerable Code
bash python3 -m pip install -r {baseDir}/requirements.txtThe referenced requirements file contains:
text numpy==2.2.6 opencv-python-headless==4.10.0.84Technical Analysis
The installation instructions retrieve and install third-party Python packages through pip. Although the versions are pinned, the requirements file does not specify cryptographic hashes, and the instructions do not require a trusted package index.
Version pinning provides reproducibility at the package-version level but does not authenticate the downloaded artifacts. The effective source is influenced by pip configuration, environment variables, command-line defaults, and configured package indexes. A compromised index, malicious mirror, manipulated local pip configuration, or substituted distribution artifact could therefore supply code different from the artifact reviewed by the Skill author.
Python package installation and subsequent imports execute package-controlled code with the privileges of the user running the Skill.
Attack Path
- A user or host follows the installation command documented in
SKILL.md. - pip resolves the pinned packages using the host's configured package index or mirror.
- An attacker controls or compromises that index, mirror, pip configuration, or the returned package artifact.
- pip downloads an unauthenticated malicious artifact matching the requested package name and version.
- Package-controlled code executes during installation or when the Skill imports NumPy or OpenCV.
Impact Assessment
Successful exploitation provides code execution with the privileges of the account performing the installation or running the Skill. The resulting code cou ...[truncated 401 chars]
- A user or host follows the installation command documented in
- Remediation
View remediation
Remediation Suggestions
-
Generate a fully hash-locked requirements file containing SHA-256 hashes for every accepted wheel.
-
Require hash verification during installation:
bash python3 -m pip install --require-hashes -r {baseDir}/requirements.txt -
Document and enforce the expected trusted package index, for example with a controlled
--index-url. -
Prefer binary wheels from a verified internal mirror and reject source distributions where practical.
-
Install dependencies into a dedicated virtual environment rather than a shared or privileged Python environment.
-
Periodically update and regenerate the lock file through a controlled dependency-review process.
-
