T08 · Insecure Dependencies
Warning
- Location
- README.md:77
- Finding
- Unpinned Third-Party Package Execution During Installation## Vulnerability Details **File Location**: `README.md`, lines 77–81 **Vulnerability Type**: Unpinned package execution and software supply-chain exposure **Risk Level**: Medium ### Vulnerable Code ```bash ### Via skills.sh ```bash npx skills add David0Ming/skill-compressor ``` ``` ### Technical Analysis The documented installation method invokes the third-party `skills` package through `npx` without specifying a package version or verifying its integrity. If the package is not already available locally, `npx` can retrieve its current release from the configured package registry and execute it with the user's privileges. Because neither a fixed version nor an integrity hash is provided, the code executed by this command may change after the Skill has been audited. A compromised package publisher account, registry compromise, or malicious future release could consequently turn the installation command into an arbitrary-code execution vector. The project itself contains no confirmed malicious scripts or executable payload. The risk originates specifically from recommending execution of mutable, externally supplied dependency code. ### Attack Path 1. An attacker compromises the upstream `skills` package, its publisher account, or its distribution channel. 2. The attacker publishes a malicious version under the package name resolved by `npx`. 3. A user follows the README and runs: ```bash npx skills add David0Ming/skill-compressor ``` 4. `npx` downloads the mutable package release from the configured registry. 5. The malicious package executes locally with the privileges and environment of the user who launched the command. 6. The payload may access any files, credentials, environment variables, or network resources available to that user. ### Impact Assessment Successful exploitation permits arbitrary command execution under the installing user's account. The accessible scope may include user-owned files, source repositories, SSH or API credent ...[truncated 395 chars]
- Remediation
- ## Remediation Suggestions 1. Pin the installer package to a specifically reviewed version: ```bash npx skills@<reviewed-version> add David0Ming/skill-compressor ``` 2. Verify the selected package version against a published integrity hash, signed release, or trusted lockfile before execution. 3. Avoid automatic acceptance of an unknown replacement package; consider using `npx --no-install` when the reviewed package has already been installed locally. 4. Prefer the manual installation method, but pin the repository to a reviewed commit or signed release rather than implicitly trusting the current branch: ```bash git clone https://github.com/David0Ming/skill-compressor.git cd skill-compressor git checkout <reviewed-commit-or-signed-tag> ``` 5. Document the expected package source, exact version, checksum, and verification procedure. 6. Re-audit dependency updates before changing the pinned version.
