T08 · Insecure Dependencies
- Location
SKILL.md:38- Finding
Unpinned Python Dependencies Installed at Runtime
- Content
View full analysis
Vulnerability Details
File Location:
SKILL.md:38
Vulnerability Type: Unpinned runtime dependency installation
Risk Level: MediumVulnerable Code Snippet
bash pip install ebooklib beautifulsoup4Technical Analysis
The skill instructs the agent to install
ebooklibandbeautifulsoup4at runtime without specifying exact versions, package hashes, a lock file, or an explicitly trusted package index. Consequently, the installed artifacts are resolved dynamically and may differ from those available when the skill was audited.Runtime package installation expands the effective behavior of this documentation-only skill to include third-party installation and package code execution. A compromised upstream release, dependency, package index, or package-resolution configuration could introduce attacker-controlled code. Installation hooks and imported package code may execute with the privileges of the user running the agent.
Attack Path
- An attacker compromises a requested package, one of its transitive dependencies, or the package source used by
pip. - The attacker publishes a malicious version that still satisfies the unbounded dependency request.
- The skill receives an EPUB file and directs the agent to install the missing packages.
pipresolves and installs the attacker-controlled release.- Malicious installation hooks or package code execute under the agent user's account.
- The payload can access resources available to that account, including project files, input books, generated summaries, environment variables, and writable local paths.
Impact Assessment
Successful exploitation could provide arbitrary code execution with the privileges of the account running the agent. The scope is limited by that account's operating-system permissions and sandbox restrictions, but may include reading or modifying local files, accessing sensitive environment variables, altering g ...[truncated 175 chars]
- An attacker compromises a requested package, one of its transitive dependencies, or the package source used by
- Remediation
View remediation
Remediation Suggestions
- Pin every direct and transitive dependency to reviewed versions in a lock file.
- Require package hashes, such as with
pip install --require-hashes -r requirements.txt. - Use an explicitly configured and trusted package index or an internally controlled package mirror.
- Prefer preinstalled dependencies from a reviewed environment instead of performing installation during skill execution.
- Disable source builds and installation scripts where operationally possible.
- Run document conversion in a sandbox with minimal filesystem access, no unnecessary credentials, and restricted network access.
- Add dependency scanning and scheduled review of pinned versions.
