T08 · Insecure Dependencies
- Location
SKILL.md:25- Finding
Unpinned Third-Party Dependency Installation
- Content
View full analysis
Vulnerability Details
File Location:
SKILL.md:25-29;references/config.md:65-68
Vulnerability Type: Unpinned dependency and insufficient package integrity controls
Risk Level: MediumVulnerable Code
SKILL.md:25-29:bash pip install oss2references/config.md:65-68:bash pip install oss2Technical Analysis
The installation instructions retrieve the latest available
oss2package without specifying a reviewed version or verifying an integrity hash. Consequently, the installed code can change independently of this project's reviewed contents.If the package distribution channel, package publisher account, or a future release is compromised, installation can execute attacker-controlled package code. Python package installation may execute build-system components, while malicious runtime code could execute when
oss2is imported byscripts/oss-upload.py.Attack Path
- An attacker compromises the upstream package, publisher account, or another relevant dependency-distribution component.
- A user follows the documented
pip install oss2command. pipresolves and installs the attacker-controlled or compromised release because no version or hash is enforced.- Malicious code executes during installation or when the upload script imports
oss2. - The code can access the user's process privileges, local files available to that user, and OSS credentials exported into the environment.
Impact Assessment
Successful exploitation could provide arbitrary code execution with the privileges of the user running
pipor the upload script. The exposed scope may include local files, the four configured OSS environment variables, and OSS operations permitted by the associated AccessKey policy.- Remediation
View remediation
Remediation Suggestions
- Pin
oss2to a specifically reviewed version in a dependency manifest. - Generate and commit a lock file that includes transitive dependency versions.
- Require verified package hashes, for example through
pip install --require-hashes -r requirements.txt. - Install packages only from an explicitly configured, trusted package index.
- Periodically scan pinned packages for known vulnerabilities and update them through a controlled review process.
- Run dependency installation and the upload utility under a minimally privileged account.
- Avoid exposing broad OSS credentials to package installation processes; use temporary, narrowly scoped credentials where possible.
- Pin
