T03 · Remote Payload Retrieval and Execution
- Location
SKILL.md:53- Finding
Unpinned Remote npm Package Is Automatically Downloaded and Executed
- Content
View full analysis
Vulnerability Details
File Location:
SKILL.md, lines 53–59
Vulnerability Type: Remote execution of a mutable third-party dependency
Risk Level: MediumVulnerable Code:
json { "mcpServers": { "pipeworx-art": { "command": "npx", "args": ["-y", "mcp-remote@latest", "https://gateway.pipeworx.io/art/mcp"] } } }Technical Analysis
The MCP configuration invokes
npxwithmcp-remote@latest. This version selector is mutable and therefore does not identify the exact package release that was reviewed. Whenever the configuration is launched,npxmay retrieve and execute whichever package version the npm registry currently designates aslatest.The
-yargument automatically accepts installation prompts, removing an opportunity for the user to review the package version before execution. npm packages may run executable JavaScript and lifecycle behavior under the privileges of the invoking user. A compromise of the package, its publishing account, or its distribution channel could therefore turn this setup command into an arbitrary code-execution path.Attack Path
- An attacker compromises the
mcp-remotenpm publishing account, package distribution channel, or a future release designated by the mutablelatesttag. - The attacker publishes a release containing malicious package or lifecycle code.
- A user enables or starts the MCP server using the configuration from
SKILL.md. npx -y mcp-remote@latestretrieves the attacker-controlled release and executes it without an interactive confirmation prompt.- The malicious code runs with the permissions and environmental access of the user who launched the agent.
Impact Assessment
Successful exploitation could provide arbitrary code execution under the invoking user's account. Depending on that account's permissions and execution environment, the malicious package could read accessible file ...[truncated 445 chars]
- An attacker compromises the
- Remediation
View remediation
Remediation Suggestions
- Replace
mcp-remote@latestwith an exact, reviewed package version. - Install the dependency through a committed lockfile that records package versions and integrity hashes.
- Verify package provenance and registry integrity before installation or execution.
- Avoid
npx -yfor first-time installation so users can review the package and resolved version. - Prefer a locally installed, audited dependency invoked from a controlled project environment.
- Apply operating-system sandboxing and least privilege to the MCP process, restricting filesystem, environment-variable, and network access to what the artwork-search function requires.
- Establish a controlled dependency-update process in which new versions are reviewed and tested before changing the pinned version.
- Replace
