T08 · Insecure Dependencies
- Location
SKILL.md:126- Finding
Unpinned Third-Party Python Dependencies
- Content
View full analysis
Vulnerability Details
File Location:
SKILL.md, lines 126-133
Vulnerability Type: Unpinned and integrity-unverified dependencies
Risk Level: MediumVulnerable Code:
markdown ## Requirements - Python 3.7+ - requests - rich ```bash pip3 install requests richtext ### Technical Analysis The installation command retrieves mutable versions of `requests` and `rich` from the user's configured Python package index. No exact versions, cryptographic hashes, lockfile, or trusted index URL are specified. Python package installation can execute package-controlled build or installation logic. Consequently, a compromised package release, malicious package-index mirror, dependency substitution, or unsafe index configuration could introduce code that was not reviewed with this skill. The named packages are legitimate and there is no evidence that they are currently malicious. The issue is the absence of controls that guarantee reproducible and integrity-verified dependency resolution. ### Attack Path 1. An attacker compromises a dependency release, transitive dependency, or package-index endpoint, or influences the user's pip index configuration. 2. The user follows the documented `pip3 install requests rich` instruction. 3. Pip resolves and downloads the attacker-controlled package version. 4. Malicious package logic executes during installation, import, or subsequent CLI use. 5. The payload operates with the privileges of the account running pip. ### Impact Assessment Successful exploitation could allow arbitrary code execution under the installing user's account. This may expose files, environment variables, application credentials, and network resources accessible to that account. If the installation command is run with elevated privileges, the impact could extend to system-wide modification, although elevated execution is not instructed by the artifact.- Remediation
View remediation
Remediation Suggestions
- Pin every direct and transitive dependency to a reviewed version.
- Provide a lockfile or requirements file containing cryptographic hashes.
- Use an integrity-enforcing installation command such as
pip install --require-hashes -r requirements.txt. - Explicitly document the trusted package index rather than relying on potentially unsafe user or system pip configuration.
- Install dependencies inside a dedicated virtual environment with least-privilege permissions.
- Add automated dependency vulnerability and provenance checks to the release process.
