T08 · Insecure Dependencies
- Location
skill.md:6- Finding
Unpinned External Package Installation Creates a Supply-Chain Risk
- Content
View full analysis
Vulnerability Details
File Location:
skill.md:6andreadme.md:31-38
Vulnerability Type: Unpinned and unverified third-party dependency installation
Risk Level: MediumVulnerable Code
skill.md:6:text metadata: {"clawdbot":{"emoji":"⚖️","tags":["defense","lawyer","criminal","legal","china","evidence","sentencing","strategy","case-analysis","legal-documents"],"requires":{"bins":["python3"],"env":[],"config":[]},"install":["pip install openclaw-defense-lawyer"],"os":["darwin","linux","win32"]}}readme.md:31-38:bash # Install from source pip install openclaw-defense-lawyer # Or clone repository git clone https://github.com/ZhenRobotics/openclaw-defense-lawyer.git cd openclaw-defense-lawyer pip install -e .Technical Analysis
The Skill directs users or an Agent runtime to install
openclaw-defense-lawyerfrom PyPI without pinning an exact version or validating package hashes. It also offers installation from the mutable default branch of a Git repository without specifying an immutable commit.The audited project contains only documentation and Skill metadata. It does not contain the referenced package implementation, a lockfile, verified package hashes, a dependency manifest, or a pinned repository commit. Consequently, the code ultimately installed and its transitive dependencies are outside the reviewed artifact and can change after this Skill has been audited.
Python package installation can invoke package build or installation behavior. After installation, the package is imported and used to process criminal-case facts, client identities, detention information, evidence, and generated legal documents. If the package, repository, release process, or a transitive dependency is compromised, attacker-controlled code could execute with the permissions of the user running
pipor the application.This finding establishes an insecure dependency acquisition mechanism. ...[truncated 1850 chars]
- Remediation
View remediation
Remediation Suggestions
- Pin the dependency to a reviewed, exact version rather than accepting the latest available release.
- Generate and verify cryptographic hashes for the package and all transitive dependencies, using a hash-locked requirements file and
pip install --require-hashes. - If installation from Git is required, reference a reviewed immutable commit hash rather than a mutable branch or tag.
- Vendor or include the package implementation in the reviewed artifact so its runtime behavior can be audited together with the Skill.
- Maintain a fully resolved dependency lockfile and continuously scan direct and transitive dependencies for malicious releases and known vulnerabilities.
- Install and execute the package in an isolated virtual environment, container, or sandbox under a least-privilege account.
- Restrict filesystem and network access to only what is necessary for local legal analysis.
- Document whether case data is processed locally or transmitted externally, and require explicit authorization before transmitting sensitive legal records.
- Verify package ownership, signed releases, provenance attestations, and release-workflow integrity before approving upgrades.
