T08 · Insecure Dependencies
Error
- Location
- SKILL.md:54
- Finding
- Unpinned npm Package Is Executed from a Mutable Remote Source## Vulnerability Details **File Location**: `SKILL.md:54-60` **Vulnerability Type**: Unpinned third-party dependency execution **Risk Level**: High ### Vulnerable Code Snippet ```markdown ## Installation ```bash npx @nordsym/apiclaw ``` Audit first: [GitHub](https://github.com/nordsym/apiclaw) | [npm](https://npmjs.com/package/@nordsym/apiclaw) ``` ### Technical Analysis The installation instructions use `npx` to download and execute `@nordsym/apiclaw` without specifying an exact version or verifying a cryptographic integrity value. Consequently, the code executed by this command can change after the skill documentation has been reviewed. The audited project contains only `SKILL.md` and `SECURITY.md`; it does not include the npm package's executable source. The behavior of the remotely retrieved package therefore cannot be verified from the supplied artifact. If the npm publisher account, package distribution pipeline, or a future package release is compromised, running the documented command could execute attacker-controlled package code. ### Attack Path 1. An attacker compromises the npm publisher account, release pipeline, or package contents for `@nordsym/apiclaw`. 2. The attacker publishes a malicious version under the legitimate package name. 3. A user or agent follows the documented installation command. 4. `npx` resolves and downloads the mutable package release. 5. Package entry points or lifecycle behavior execute with the privileges of the user invoking `npx`. 6. The malicious package may read accessible files and environment variables, make network requests, alter user-owned files, or execute additional commands. ### Impact Assessment Successful exploitation permits arbitrary code execution with the privileges of the invoking user. The affected scope may include user-readable files, environment variables, provider credentials under `~/.secrets/`, source repositories, and any network or filesyst ...[truncated 146 chars]
- Remediation
- ## Remediation Suggestions - Pin the installation command to an exact, independently audited package version, for example `npx @nordsym/apiclaw@1.2.3`. - Publish and verify package integrity hashes or signed provenance before execution. - Vendor or include the executable source in the reviewed artifact so runtime behavior can be audited. - Use a lockfile and a trusted package registry configuration where the package is installed as a project dependency. - Disable dependency lifecycle scripts where compatible with the package's operation. - Run the package in a sandbox with minimum filesystem, environment-variable, credential, and network access. - Re-audit every version update rather than relying on a mutable unversioned command.
