T08 · Insecure Dependencies
- Location
SKILL.md:64- Finding
Unpinned pdfplumber Dependency in Skill Instructions
- Content
View full analysis
Vulnerability Details
File Location:
SKILL.md, lines 64-69
Vulnerability Type: Unpinned third-party Python dependency
Risk Level: Mediummarkdown ## Dependencies Install once if missing: ```bash python -m pip install --user pdfplumbertext ### Technical Analysis The installation command does not specify an audited version, validate package hashes, use a lockfile, or require an isolated virtual environment. Package resolution therefore depends on the state of the configured Python package index at installation time and may select a newly published or compromised `pdfplumber` release or transitive dependency. The `--user` option installs the package under the invoking user's account. It does not grant administrative privileges, but package build hooks and subsequently imported package code can execute with that user's permissions. The extraction script imports `pdfplumber` and uses it to process potentially sensitive legal documents, making the integrity of the dependency particularly important. ### Attack Path 1. An attacker compromises a resolved dependency release, its distribution account, or the package source configured in the user's pip environment. 2. The user follows the documented `python -m pip install --user pdfplumber` instruction. 3. Pip resolves and installs the attacker-controlled release because no version or cryptographic hash is enforced. 4. Malicious code executes during an applicable source-build process or when the extraction script imports and invokes the installed package. 5. The code operates with the invoking user's permissions and may access the PDFs, extracted legal content, output files, environment variables, and other resources available to that user. This path depends on package-index, publisher, dependency, or local pip-configuration compromise; the audited project itself does not contain a malicious dependency payload. ### Impact Assessment Successful ex ...[truncated 383 chars]- Remediation
View remediation
Remediation Suggestions
- Pin
pdfplumberand every transitive dependency to audited versions in a dependency lockfile. - Require cryptographic hashes, for example with
python -m pip install --require-hashes -r requirements.txt. - Generate and review the lockfile from a trusted package index, and update dependencies through a controlled review process.
- Install dependencies in a dedicated virtual environment rather than the user-wide package directory.
- Configure pip to use an explicitly trusted index and disable unexpected additional indexes.
- Run PDF extraction in a sandbox or container with access restricted to required input PDFs and the designated output directory.
- Add automated dependency vulnerability and provenance checks to release validation.
- Pin
