T08 · Insecure Dependencies
Warning
- Location
- SKILL.md:14
- Finding
- Unpinned Third-Party CLI Packages Installed Globally## Vulnerability Details **File Location**: `SKILL.md`, lines 14–17 **Vulnerability Type**: Unpinned third-party dependencies and unsafe global installation **Risk Level**: Medium ### Vulnerable Code ```bash npm install -g mineru-open-api # or via Go (macOS/Linux): go install github.com/opendatalab/MinerU-Ecosystem/cli/mineru-open-api@latest ``` ### Technical Analysis Both installation commands resolve mutable third-party package versions at installation time. The npm command omits a version specifier, while the Go command explicitly requests `@latest`. The project provides no lockfile, cryptographic checksum, signature, or immutable source reference with which to verify the installed implementation. The packages are installed globally, exposing the resulting executable through the user's command search path. Package installation may also execute upstream installation logic with the privileges of the invoking user. Consequently, a compromised package registry account, source repository, release artifact, maintainer account, or transitive dependency could introduce code that was not present during this audit. This finding concerns supply-chain integrity. The reviewed file does not itself contain malicious code, and there is no evidence that the named upstream project is currently compromised. ### Attack Path 1. An attacker compromises an upstream maintainer, package registry account, repository, release pipeline, or transitive dependency. 2. The attacker publishes a malicious release that becomes the latest available version. 3. A user or automated agent follows the documented installation instructions. 4. npm or Go resolves and downloads the attacker-controlled release because no reviewed immutable version is specified. 5. Installation-time code or the subsequently invoked `mineru-open-api` executable runs under the installing user's account. 6. The malicious package may access files, environment variables, credentials, and network resources available t ...[truncated 642 chars]
- Remediation
- ## Remediation Suggestions 1. Pin both installation methods to specific, reviewed versions instead of resolving the latest release: ```bash npm install -g mineru-open-api@<reviewed-version> go install github.com/opendatalab/MinerU-Ecosystem/cli/mineru-open-api@vX.Y.Z ``` 2. Publish expected checksums or signature-verification instructions for the approved release artifacts. 3. Prefer project-local or isolated installation over global installation where operationally possible. 4. Review the pinned package, its installation hooks, and its transitive dependencies before approval. 5. Use automated dependency monitoring, but update versions only after security review and integrity verification. 6. Run document processing with least privilege and restrict access to unrelated files, credentials, and network resources. 7. Clarify whether DOCX content is transmitted to external services and document applicable retention and privacy controls before sensitive documents are processed.
