T08 · Insecure Dependencies
- Location
SKILL.md:8- Finding
Unpinned Global npm Package Installation
- Content
View full analysis
Vulnerability Details
File Location:
SKILL.md, lines 8-11
Vulnerability Type: Unpinned third-party dependency installed globally
Risk Level: MediumVulnerable Code
bash ## Install ```bash npm install -g @deepgram/clitext ### Technical Analysis The documented installation command retrieves the current version of `@deepgram/cli` from the configured npm registry without pinning a reviewed version or verifying package integrity. Consequently, the code installed by this instruction can change after the Skill has been audited. npm installation may execute package lifecycle scripts with the invoking user's permissions. The global installation flag (`-g`) also expands the package's presence and potential impact beyond an isolated project environment. Although the package name is consistent with the Skill's stated Deepgram functionality and the audited file contains no direct evidence that the package is malicious, this installation pattern creates a supply-chain exposure. ### Attack Path 1. An attacker compromises the upstream package, a maintainer account, the configured npm registry, or a future package release. 2. The attacker publishes a modified release containing a malicious lifecycle script or executable payload. 3. A user follows the Skill's unpinned `npm install -g` instruction. 4. npm retrieves the mutable current release rather than a previously reviewed version. 5. Malicious lifecycle code may execute during installation, or malicious CLI code may execute when the user subsequently invokes `deepgram`. 6. The payload operates with the permissions of the user running npm and can access resources available to that account. ### Impact Assessment Successful exploitation could permit arbitrary code execution with the installing user's privileges. Depending on that user's permissions, exposed resources may include local files, environment variables, the locally stored Deepgram API cred ...[truncated 261 chars]- Remediation
View remediation
Remediation Suggestions
- Pin
@deepgram/clito an explicitly reviewed version rather than installing the mutable latest release. - Prefer a project-local dependency governed by a committed lockfile over a global installation.
- Verify the package's registry provenance, publisher identity, signatures or attestations where available, and expected integrity metadata before adoption.
- Review package lifecycle scripts and release changes before updating the pinned version.
- Install and execute the CLI using a least-privileged account; do not instruct users to run npm with
sudoor elevated privileges. - Consider an isolated environment or container with narrowly scoped filesystem and credential access.
- Document where the Deepgram API key is stored and require restrictive file permissions and a narrowly scoped, revocable credential.
- Pin
