T08 · Insecure Dependencies
Warning
- Location
- SKILL.md:40
- Finding
- Unpinned Python Dependency Installation Bypasses System Package Protections## Vulnerability Details **File Location**: `SKILL.md`, line 40 **Vulnerability Type**: Unpinned third-party dependency installed with weakened package-management safeguards **Risk Level**: Medium **Vulnerable Code Snippet**: ```bash pip3 install vosk --user --break-system-packages ``` ### Technical Analysis The setup instructions install the mutable, unpinned `vosk` package and its transitive dependencies from the user's configured Python package index. Because no exact version or cryptographic hashes are specified, the code retrieved during installation can change after the skill has been reviewed. The `--break-system-packages` option explicitly overrides protections intended to prevent `pip` from interfering with an externally managed Python environment. Although `--user` limits installation to the current account in typical configurations, this combination can still introduce incompatible or attacker-controlled packages into the user's Python import path. Package installation and subsequent imports may execute package-controlled Python code. Exploitation therefore depends on compromise of the package, one of its dependencies, the configured package index, or dependency resolution. ### Attack Path 1. An attacker compromises a resolved package or dependency, publishes a malicious future release, or controls a package source configured on the target. 2. A user follows the documented setup command without specifying a reviewed version or hash. 3. `pip` resolves and downloads the attacker's package content. 4. Package-controlled code runs during installation or when the installed module is subsequently imported. 5. The payload executes with the privileges of the user running `pip`. ### Impact Assessment Successful exploitation could provide arbitrary code execution under the installing user's account. This may expose files, credentials, environment variables, and other resources accessible to that account. It could ...[truncated 269 chars]
- Remediation
- ## Remediation Suggestions - Create and activate a dedicated virtual environment instead of modifying an externally managed Python environment. - Remove `--break-system-packages`. - Pin `vosk` and all transitive dependencies to reviewed versions in a lock file. - Require package hashes, such as through `pip install --require-hashes -r requirements.txt`. - Use a trusted, explicitly configured package index and retain reviewed dependency artifacts where practical. - Add dependency vulnerability and provenance checks to the release process. - Document the installation procedure, for example: ```bash python3 -m venv ~/.venvs/local-vosk ~/.venvs/local-vosk/bin/python -m pip install --upgrade pip ~/.venvs/local-vosk/bin/python -m pip install --require-hashes -r requirements.txt ```
