T08 · Insecure Dependencies
- Location
SKILL.md:299- Finding
Unpinned Third-Party Package Is Downloaded and Executed Automatically
- Content
View full analysis
Vulnerability Details
File Location:
SKILL.md:299-304
Vulnerability Type: Unsafe third-party dependency execution
Risk Level: HighVulnerable code snippet:
bash ## MCP server claude mcp add twitterapi-io -- npx -y twitterapi-io-mcpTechnical Analysis
The documented command invokes
npxwith the-yoption, which suppresses confirmation and automatically downloads and executes the package resolved under the nametwitterapi-io-mcp. No exact package version or integrity digest is specified.Consequently, the code executed by users is not immutable relative to the audited skill. A future package release, compromised publisher account, registry compromise, or malicious package replacement could cause this command to retrieve and execute code that was not present during the audit. The package executes with the permissions of the user running the command and may inherit the process environment and access locally available files.
This is a supply-chain vulnerability rather than evidence that the package is currently malicious.
Attack Path
- An attacker compromises the npm publisher account, package repository, release workflow, or another component capable of publishing a package version.
- The attacker publishes a malicious version of
twitterapi-io-mcp. - A user follows the skill documentation and runs the unpinned
npx -y twitterapi-io-mcpcommand. npxresolves and downloads the attacker-controlled version without an interactive approval step.- The malicious package executes with the invoking user's privileges.
- The payload can access resources available to that user and process, potentially including API credentials, project files, configuration files, and environment variables.
Impact Assessment
Successful exploitation can result in arbitrary local code execution with the privileges of the invoking user. The accessible scope may include the user's files, d ...[truncated 311 chars]
- Remediation
View remediation
Remediation Suggestions
- Pin the package to an exact reviewed version, for example
twitterapi-io-mcp@X.Y.Z, rather than resolving the latest available release. - Publish and verify an integrity digest or signed provenance record for the reviewed package artifact.
- Remove automatic confirmation where practical so users can inspect the package and resolved version before execution.
- Recommend installation from a lockfile-backed project with integrity metadata instead of ad hoc
npxexecution. - Review the package contents and lifecycle scripts before recommending a new version.
- Run the MCP process under a dedicated, least-privilege account or sandbox with restricted filesystem, environment, and network access.
- Document a trusted version-update process so dependency upgrades receive security review before the pinned version changes.
- Pin the package to an exact reviewed version, for example
