T03 · Remote Payload Retrieval and Execution
- Location
- SKILL.md:45
- Finding
- Unverified Remote Installer Downloaded and Executed by Bash## Vulnerability Details **File Location**: `SKILL.md`, line 45 **Vulnerability Type**: `T03: Remote Payload Retrieval and Execution` **Risk Level**: Critical **Vulnerable Code**: ```bash bun --version || curl -fsSL https://bun.sh/install | bash ``` ### Technical Analysis If Bun is unavailable, the command downloads the current content served by `https://bun.sh/install` and immediately executes it with Bash. It does not pin a version, validate a checksum or signature, save the script for inspection, or request confirmation before execution. Although the domain appears associated with the Bun project and HTTPS protects the connection in transit, the effective code can change after this Skill has been reviewed. Compromise of the hosting service, distribution infrastructure, domain, or maintainer account could consequently turn this installation command into an arbitrary code-execution channel. Installing Bun may facilitate the documented CLI build process, but granting mutable remote content immediate shell execution exceeds the minimum privileges necessary. Bun can instead be treated as a prerequisite or installed from a pinned and cryptographically verified artifact. ### Attack Path 1. A user or agent follows the setup instructions on a system where `bun` is unavailable. 2. The fallback expression invokes `curl` against the remote installer endpoint. 3. The endpoint or its delivery infrastructure serves compromised or unexpectedly modified shell code. 4. The pipe passes that content directly to Bash without verification or review. 5. The payload executes with all permissions of the account running the setup command. ### Impact Assessment A malicious installer could execute arbitrary commands with the invoking user's privileges. This may allow access to user-readable credentials and API tokens, modification or deletion of user files, alteration of shell configuration, installation of additional software, and network ...[truncated 165 chars]
- Remediation
- ## Remediation Suggestions - Remove the `curl | bash` installation pipeline. - Treat Bun as an explicit prerequisite and direct users to a trusted platform package manager. - If automated installation is essential, pin a specific Bun release and download its release artifact separately. - Verify the artifact against a trusted published checksum or cryptographic signature before executing or installing it. - Fail safely when verification is unavailable or unsuccessful. - Display the source, version, and planned installation action and obtain explicit user confirmation before making system changes. - Run installation with ordinary user privileges and do not recommend `sudo` unless a narrowly defined platform operation requires it.
