T08 · Insecure Dependencies
Warning
- Location
- SKILL.md:12
- Finding
- Unpinned Executable Third-Party Dependency## Vulnerability Details **File Location**: `SKILL.md`, lines 12-15 **Vulnerability Type**: Unpinned third-party package installation **Risk Level**: Medium ```yaml install: - kind: node package: nansen-cli bins: [nansen] ``` ### Technical Analysis The skill installs the executable Node package `nansen-cli` without specifying an exact version or integrity hash. Consequently, the package registry can resolve the dependency to a release that was not examined during this audit. Node package installation may also execute package lifecycle scripts with the privileges of the user installing the skill. This creates a supply-chain risk: compromise of the package, its maintainer account, the configured registry, or a future package release could introduce malicious code without requiring changes to this repository. ### Attack Path 1. An attacker compromises the `nansen-cli` package, its publisher account, or the package registry resolution path. 2. The attacker publishes or serves a malicious package release. 3. A user installs this skill, and the unversioned dependency resolves to the malicious release. 4. Malicious package code executes during installation through lifecycle scripts or later when the skill invokes the `nansen` executable. 5. The code operates with the installing or invoking user's privileges and may attempt to access environment variables, including `NANSEN_API_KEY`, as well as files and resources available to that user. ### Impact Assessment Successful exploitation could permit arbitrary code execution under the local user's account. The resulting scope could include theft of the Nansen API credential, access to user-readable files, unauthorized network activity, and modification of files writable by that user. This configuration does not itself provide elevated system privileges; impact is bounded by the privileges and isolation controls of the installation or execution environment.
- Remediation
- ## Remediation Suggestions - Pin `nansen-cli` to an exact, reviewed version rather than allowing mutable registry resolution. - Verify the package with an integrity digest or a trusted lockfile where supported by the skill installation framework. - Confirm package provenance, publisher identity, and release signatures before updating the pinned version. - Use a trusted package registry and enforce registry allowlisting where possible. - Disable Node lifecycle scripts during installation when they are not required. - Perform installation and execution in a sandbox or container with minimal filesystem and network permissions. - Expose `NANSEN_API_KEY` only to the runtime command that requires it, rather than to dependency installation processes. - Review and test every dependency update before changing the pinned version.
