T08 · Insecure Dependencies
- Location
SKILL.md:11- Finding
Globally Installed Third-Party MCP Server Executes with an API Credential
- Content
View full analysis
Vulnerability Details
File Location:
SKILL.md, lines 11-25
Vulnerability Type: Third-party dependency and supply-chain risk
Risk Level: Mediumyaml install: command: npm args: - install - -g - "pipiads-mcp-server@1.0.3" primaryEnv: PIPIADS_API_KEY emoji: "📊" homepage: https://www.pipiads.com mcpServers: pipiads: command: pipiads-mcp-server env: PIPIADS_API_KEY: "{{PIPIADS_API_KEY}}"Technical Analysis
The skill installs
pipiads-mcp-server@1.0.3globally from the npm registry and subsequently executes its binary withPIPIADS_API_KEYin its environment. Pinning the version reduces uncontrolled version drift, but the project does not provide an integrity hash, lockfile, reviewed source, or other mechanism for independently verifying the installed artifact.npm installation can execute package lifecycle scripts. After installation, the MCP server itself runs as local code under the invoking user's privileges and receives the configured API credential. Consequently, a malicious, compromised, incorrectly sourced, or otherwise unsafe package artifact could execute arbitrary code and access the PipiAds credential.
Global installation also increases scope compared with a project-local, isolated dependency because it places the executable in a shared environment and may affect other sessions or applications using the same command name.
Attack Path
- An attacker compromises the upstream package, its publishing process, a registry delivery path, or otherwise causes an unsafe artifact to be resolved for
pipiads-mcp-server@1.0.3. - The skill runs
npm install -g pipiads-mcp-server@1.0.3. - Malicious package lifecycle code may execute during installation with the privileges of the user performing the installation.
- The installed
pipiads-mcp-serverexecutable is launched as an MCP server. - The process receives
PIPIADS_API_KEYthroug ...[truncated 1149 chars]
- An attacker compromises the upstream package, its publishing process, a registry delivery path, or otherwise causes an unsafe artifact to be resolved for
- Remediation
View remediation
Remediation Suggestions
- Prefer bundling and reviewing the MCP server source as part of the audited distribution rather than downloading executable code during installation.
- Verify npm package provenance and record the expected artifact integrity hash. Use a lockfile or equivalent immutable dependency manifest where supported.
- Install the package into a project-local, isolated environment instead of using
npm install -g. - Disable npm lifecycle scripts with
--ignore-scriptswhen the package does not require them. If scripts are required, audit each script and its transitive dependencies before installation. - Execute the MCP server in a sandbox or container with restricted filesystem, network, process, and environment access.
- Supply a narrowly scoped, revocable API key with billing and rate limits. Do not reuse a credential that grants unrelated account permissions.
- Restrict outbound network access to documented PipiAds endpoints so the server cannot send credentials to arbitrary hosts.
- Monitor API usage for unexpected credit consumption or task changes, rotate the key periodically, and revoke it immediately if compromise is suspected.
- Validate the installed executable's path and integrity before launch to reduce the possibility of command-name collision or replacement by another global package.
