T08 · Insecure Dependencies
- Location
SKILL.md:37- Finding
Unpinned npm Package Execution in a Payment-Credential Workflow
- Content
View full analysis
Vulnerability Details
File Location:
SKILL.md:37-55
Vulnerability Type:T08: Insecure Dependencies
Risk Level: MediumVulnerable Code
markdown Install with `npm install -g @stripe/link-cli`. Or run directly with `npx @stripe/link-cli`. ## Running commands Link CLI can run as an **MCP server** or as a **standalone CLI**. **MCP:** Add the following to your MCP client config (`.mcp.json`, etc.) ```json { "mcpServers": { "link": { "command": "npx", "args": ["@stripe/link-cli", "--mcp"] } } }Run the MCP server directly with
npx @stripe/link-cli@latest --mcp.text ### Technical Analysis The Skill instructs the Agent to install or execute `@stripe/link-cli` without pinning an exact, previously reviewed version or verifying package integrity. The explicit use of `@latest` guarantees that the effective executable payload can change after this Skill has been audited. The package name is scoped and presented as Stripe software, which lowers ordinary typo-squatting risk, but it does not protect against a compromised npm publisher account, malicious upstream release, registry compromise, or unsafe future dependency update. Global installation also increases exposure by placing mutable third-party executable code into the broader system environment. This is especially sensitive because the CLI handles Link authentication state, payment methods, shipping addresses, temporary card credentials, and Shared Payment Tokens. ### Attack Path 1. An attacker compromises the package publisher, release process, registry account, or a transitive dependency. 2. The attacker publishes a malicious version under `@stripe/link-cli`. 3. The Agent follows the Skill and executes `npx @stripe/link-cli`, `npx @stripe/link-cli@latest`, or globally installs the package. 4. npm retrieves and executes the changed package without requiring the Skill itself to be modified. 5. The malicious package accesses data available to the process, ...[truncated 1063 chars]- Remediation
View remediation
Remediation Suggestions
- Pin
@stripe/link-clito an exact version that has been reviewed instead of using an unversioned reference or@latest. - Remove the recommendation to execute
npx @stripe/link-cli@latest. - Use a lockfile and verify npm package integrity hashes before execution.
- Prefer a project-local installation over
npm install -gto limit system-wide effects. - Disable or carefully review lifecycle scripts where operationally possible.
- Separate dependency installation from payment execution so that updates require an explicit review and approval step.
- Run the CLI in a sandbox with narrowly scoped filesystem and network permissions.
- Restrict runtime tool access to the pinned
link-cliexecutable rather than broadly allowingnpm:*andnpx:*. - Document a controlled upgrade process that includes source provenance, checksum verification, and security review.
- Pin
