T08 · Insecure Dependencies
- Location
SKILL.md:48- Finding
Unpinned Third-Party Packages Are Installed and Executed
- Content
View full analysis
Vulnerability Details
File Location:
SKILL.md:48-52andSKILL.md:170-174
Vulnerability Type: Supply-chain exposure through unpinned dependencies
Risk Level: HighVulnerable Code
bash # Ensure mcp SDK is installed pip show mcp > /dev/null 2>&1 || pip install mcp python /path/to/skill-dir/mcp_inspector.py "<MCP command>" --output /tmp/mcp-inspector-output.jsonbash which npx && npx skills --version 2>/dev/nullbash npx skills add <skill-path> -g -yTechnical Analysis
The workflow installs
mcpwithout an exact version, integrity hash, lockfile, or explicitly trusted package index. It also invokes the generically namedskillsnpm package throughnpxwithout pinning a reviewed version.Running
npx skills --versionis not a safe local availability check: depending on npm configuration and cache state,npxcan retrieve and execute the latest package from the configured registry. Both Python and npm packages can execute package-controlled code during installation or invocation.Consequently, the code that runs is not fixed by the audited project and can change after review. Although there is no evidence that the current dependencies are malicious, the dependency-loading process creates a supply-chain execution channel.
Attack Path
- An attacker compromises the relevant registry package, publishing account, registry configuration, or network dependency resolution path.
- The user invokes the skill on a system where
mcpis absent or wherenpxresolves the unpinnedskillspackage. pip install mcpdownloads and installs the attacker-influenced release, ornpx skills --versiondownloads and executes attacker-controlled npm code.- Installation hooks or package runtime code executes with the privileges of the agent process.
- The malicious dependency can access files, credentials, environment variables, an ...[truncated 566 chars]
- Remediation
View remediation
Remediation Suggestions
- Pin every dependency to an exact, reviewed version, including both
mcpand the npmskillspackage. - For Python dependencies, use a locked requirements file with cryptographic hashes and install with
pip install --require-hashes. - For npm dependencies, use a lockfile and invoke a locally installed, pinned binary rather than an unqualified
npxpackage. - Specify and validate trusted package registries instead of inheriting arbitrary user or environment registry configuration.
- Do not use
npx skills --versionas an availability probe. Check for an already installed executable without allowing automatic package download. - Obtain explicit user approval before any package installation or global registration.
- Perform installation in an isolated virtual environment or restricted container with minimal filesystem and credential access.
- Record the exact package version and integrity digest in generated audit output so users can verify what was executed.
- Pin every dependency to an exact, reviewed version, including both
