T08 · Insecure Dependencies
- Location
SKILL.md:44- Finding
Unpinned Prisma Package May Be Retrieved and Executed by npx
- Content
View full analysis
Vulnerability Details
File Location:
SKILL.md, line 44
Vulnerability Type: Unpinned third-party package execution
Risk Level: Mediumsh npm install && npx prisma db pushTechnical Analysis
The setup instructions invoke
prismathroughnpxwithout specifying or verifying an exact package version. The reviewed artifact does not include apackage.json, dependency lockfile, vendored Prisma executable, or application source code. Therefore, the dependency version and integrity cannot be validated from the distributed files.If no suitable local Prisma binary is installed,
npxmay resolve, download, and execute the package from the configured npm registry. The effective executable can consequently differ from what was reviewed. Exploitation would require control over, or compromise of, a relevant package release, package-resolution path, npm registry, proxy, or local registry configuration.This is a supply-chain risk rather than evidence that Prisma itself is malicious. No malicious package or embedded payload was identified in the artifact.
Attack Path
- A user configures the project environment as instructed, potentially including API keys and database credentials.
- The user runs
npm install && npx prisma db push. - If the first command succeeds and no trusted local Prisma executable is available,
npxresolves the unpinnedprismapackage using the configured npm registry. - An attacker controlling or compromising the registry, resolution configuration, proxy, or applicable upstream package version supplies malicious package code.
npxexecutes that code with the privileges of the user running the setup command.- The malicious package can access resources available to that user, including project files and environment variables, and may modify local files or initiate network connections.
Impact Assessment
Successful exploitation provides code e ...[truncated 709 chars]
- Remediation
View remediation
Remediation Suggestions
- Include the complete application dependency metadata, including
package.jsonand a reviewed lockfile such aspackage-lock.json. - Declare Prisma as a project dependency or development dependency using an exact, reviewed version rather than an open-ended version range.
- Install dependencies with a lockfile-enforcing command such as:
sh npm ci - Invoke only the locked local executable and prevent runtime downloads where supported, for example:
sh npm exec --offline prisma db push - Configure npm to use a trusted registry and retain lockfile integrity hashes.
- Perform dependency installation in a restricted development container or sandbox with minimal filesystem access and no unnecessary credentials.
- Avoid exposing production API keys or database credentials during dependency installation.
- Add automated dependency and lockfile integrity checks to the release process, and distribute all files required to reproduce the reviewed installation.
- Include the complete application dependency metadata, including
