T08 · Insecure Dependencies
- Location
README.md:23- Finding
Unpinned Third-Party Installer Execution Creates Supply-Chain Risk
- Content
View full analysis
Vulnerability Details
File Location:
README.md, line 23
Vulnerability Type: Unpinned third-party package execution
Risk Level: MediumVulnerable Code
bash npx add https://github.com/wpank/ai/tree/main/skills/api/api-developmentTechnical Analysis
The installation instructions invoke
npx addwithout pinning the npm package namedaddto a reviewed version or verifying its integrity. If the package is absent locally,npxcan retrieve and execute it from the configured npm registry.The GitHub source argument also references a mutable repository branch path rather than an immutable commit. The code ultimately processed or installed by this command can therefore change after the Skill has been audited.
This behavior is unnecessary for a documentation-only Skill whose files can be installed through a non-executing copy or verified download operation. There is no evidence in the audited repository that the referenced package or repository is currently malicious; the vulnerability is the unsafe trust and execution model.
Attack Path
- An attacker compromises the npm account or package resolved as
add, influences the configured package registry, or compromises the mutable upstream GitHub repository. - The attacker publishes a modified installer or changes the content referenced by the repository branch.
- A user follows the documented
npx add ...installation command. npxdownloads and executes the unreviewed package with the user's current permissions.- Malicious installer code can read accessible files and environment variables, alter projects or user-owned files, establish network connections, or install additional payloads.
Impact Assessment
Exploitation would execute attacker-controlled code with the privileges of the user running the installation command. Potentially exposed resources include source code, environment variables, development credentials, API to ...[truncated 340 chars]
- An attacker compromises the npm account or package resolved as
- Remediation
View remediation
Remediation Suggestions
- Replace
npx addwith a trusted installation mechanism that does not execute an arbitrary package merely to copy this documentation-only Skill. - If an installer is necessary, pin it to an exact reviewed version rather than resolving the latest registry release.
- Pin the upstream repository content to a full immutable commit hash instead of a mutable branch path.
- Verify downloaded content using a cryptographic digest or trusted package-lock integrity metadata before processing it.
- Prefer downloading reviewed files from a fixed commit and copying them into the destination directory with standard filesystem commands.
- Document the expected files and checksums so users can independently validate the installed content.
- Run installation without elevated privileges and in an environment that does not expose production credentials or unrelated sensitive files.
- Replace
