T08 · Insecure Dependencies
- Location
SKILL.md:83- Finding
Automatic Installation of an Unpinned Third-Party Audit Package
- Content
View full analysis
/dev/null 2>&1 || pip install pip-audit --quiet pip-audit --format=json 2>/dev/null | python3 -c " import json, sys d = json.load(sys.stdin) deps = d.get('dependencies', []) critical = [v for dep in deps for v in dep.get('vulns', []) if v.get('severity', '').lower() == 'critical'] high = [v for dep in deps for v in dep.get('vulns', []) if v.get('severity', '').lower() == 'high'] print(f'Critical: {len(critical)}, High: {len(high)}, Packages checked: {len(deps)}') " 2>/dev/null || echo "pip-audit not available — install: pip install pip-audit" ``` ### Technical Analysis The Skill directs the agent to install `pip-audit` automatically whenever it is absent. The package version is not pinned, package hashes are not verified, and installation is not constrained to an isolated virtual environment. The command also uses the active Python package index configuration, which may point to an untrusted or organization-specific mirror. Python package installation can execute build-system logic when wheels are unavailable or when a malicious distribution is selected. Consequently, this instruction creates a supply-chain code-execution boundary despite the package installation being ancillary to the Skill's core dependency-auditing function. Automatically modifying the host Python environment exceeds the minimum privilege needed. The Skill can instead use the documented OSV API fallback or require a trusted scanner to be installed explicitly by the user. ### Attack Path 1. A dependency-related task activates the Skill's audit phase. 2. `pip show pip-audit` determines that the package is not installed. 3. The agent executes `pip install pip-audit --quiet` against the active package index. 4. A compromised rel ...[truncated 858 chars]- Remediation
View remediation
