T08 · Insecure Dependencies
- Location
SKILL.md:19- Finding
Mutable npm Package Execution Through an Unpinned Installation Command
- Content
View full analysis
Vulnerability Details
File Location:
SKILL.md, line 19
Vulnerability Type: Unpinned third-party package execution
Risk Level: MediumVulnerable Code
bash npx clawhub@latest install clean-codeTechnical Analysis
The installation instructions invoke
npxwith the mutable@latesttag.npxmay download and execute package code, including package lifecycle behavior, under the privileges of the user running the command.Because
@latestdoes not identify an immutable, audited version, the package executed in the future may differ from the package available during this audit. The command also provides no integrity checksum or other mechanism for verifying that the downloaded package is the expected artifact.Exploitation requires the user to run the documented installation command and an attacker to gain control over, replace, or compromise the relevant upstream package or publishing account.
Attack Path
- An attacker compromises the upstream package, package publisher, release process, or registry account.
- The attacker publishes a malicious version and assigns it to the
latestdistribution tag. - A user follows the documented command.
npxretrieves the attacker-controlled package version.- Malicious package or lifecycle code executes with the installing user's privileges.
Impact Assessment
Successful exploitation could permit arbitrary code execution with the privileges of the user running
npx. Depending on that user's permissions and environment, the malicious package could access project files, source code, user-readable credentials, environment variables, and other resources available to the process. The potential scope is the local user account and any systems or services reachable using that account's credentials.This project does not itself contain the malicious payload; the risk arises from executing mutable third-party content during installation.
- Remediation
View remediation
Remediation Suggestions
- Replace
@latestwith an exact, reviewed package version. - Verify the selected package version and publisher before documenting it.
- Use package-manager integrity verification and a lockfile where supported.
- Prefer installation methods that do not automatically execute unreviewed lifecycle scripts.
- Document the expected artifact checksum or signature and require verification before execution.
- Periodically re-audit the pinned release before updating the documented version.
- Replace
