T08 · Insecure Dependencies
- Location
SKILL.md:35- Finding
Unpinned Third-Party Dependencies Installed Without Integrity Verification
- Content
View full analysis
Vulnerability Details
File Location:
SKILL.md:35
Vulnerability Type: Supply-chain risk from unpinned dependencies
Risk Level: MediumVulnerable Code Snippet:
bash pip install pytesseract PillowTechnical Analysis
The documented installation command retrieves the latest package versions matching their names from the Python package index configured in the user's environment. It does not pin reviewed versions, verify cryptographic hashes, or require a trusted package source.
The minimum-version constraints in
_meta.jsondo not provide reproducible dependency resolution:json "pytesseract": ">=0.3.0", "Pillow": ">=8.0.0"Consequently, the code installed by users can change after this Skill has been reviewed. If an allowed dependency, its transitive dependencies, or the configured package repository is compromised, attacker-controlled code may be installed. Package installation and subsequent imports can execute that code in the user's environment.
Attack Path
- An attacker compromises a permitted package release, one of its transitive dependencies, or the package index configured for
pip. - A user follows the installation instructions and runs
pip install pytesseract Pillow. - Because no exact versions or hashes are required,
pipresolves and downloads the compromised package. - Attacker-controlled package code executes during installation, import, or later OCR operations.
- The malicious code operates with the privileges of the account or environment that installed and runs the Skill.
Impact Assessment
Successful exploitation could allow arbitrary code execution with the installing or invoking user's privileges. Depending on that account's permissions, the attacker could read or modify accessible files, steal environment variables or credentials, alter the Python environment, and compromise OCR input or output. If installation is performed with ...[truncated 309 chars]
- An attacker compromises a permitted package release, one of its transitive dependencies, or the package index configured for
- Remediation
View remediation
Remediation Suggestions
-
Create a reviewed lock file or requirements file containing exact versions for direct and transitive dependencies.
-
Record cryptographic hashes and require verification during installation, for example:
bash python3 -m pip install --require-hashes -r requirements.txt -
Replace open-ended constraints such as
>=0.3.0with versions synchronized with the reviewed lock file. -
Configure and document an approved HTTPS package index or an internally controlled dependency mirror.
-
Perform dependency vulnerability and provenance checks before updating locked versions.
-
Install dependencies inside an isolated virtual environment under a non-privileged account, and explicitly discourage using
sudo pip. -
Establish a controlled update process in which dependency changes are reviewed, scanned, tested, and assigned new hashes before release.
-
