T03 · Remote Payload Retrieval and Execution
Error
- Location
- install.sh:39
- Finding
- Remote Script Execution Recommended Through curl-to-shell Installation<![CDATA[ ## Vulnerability Details **File Location**: `install.sh:39-42` **Vulnerability Type**: Remote payload retrieval and execution **Risk Level**: Critical ### Vulnerable Code ```bash # uv if ! command -v uv &>/dev/null; then fail "uv not found. Install it first:\n brew install uv (macOS)\n curl -LsSf https://astral.sh/uv/install.sh | sh (Linux)" fi ``` ### Technical Analysis The installer directs users to download a mutable remote shell script and immediately execute it through a pipeline: ```bash curl -LsSf https://astral.sh/uv/install.sh | sh ``` This design does not pin a release, verify a cryptographic checksum or signature, or give the user an opportunity to inspect the retrieved file. The effective code executed by the user can therefore change after this Skill has been reviewed. The command is presented as an instruction rather than executed automatically by `install.sh`. Nevertheless, users following the installer’s prescribed recovery procedure will execute code controlled by the remote endpoint. The repository does not contain evidence that could guarantee the integrity of all future responses from that endpoint. ### Attack Path 1. A user runs `install.sh` without `uv` installed. 2. The installer exits and displays the curl-to-shell command. 3. The user follows the displayed instruction. 4. An attacker who has compromised the remote endpoint, its hosting infrastructure, or a relevant trust dependency serves modified shell code. 5. `sh` executes the response immediately under the installing user’s account. ### Impact Assessment Successful exploitation provides arbitrary code execution with the privileges of the user performing installation. This can expose local files, OpenClaw credentials, Xiaohongshu session cookies, API keys, and any other resources available to that account. The remote payload could also install persistence or modify the installed Skill without further confirmation. ]]>
- Remediation
- <![CDATA[ ## Remediation Suggestions - Remove all curl-to-shell and PowerShell download-to-execution instructions. - Recommend a trusted operating-system package manager where available. - Otherwise require users to download a versioned release artifact separately. - Pin the expected uv release instead of retrieving the latest mutable installer. - Publish and verify a SHA-256 or stronger digest before execution. - Prefer signature verification using a documented, pinned signing key. - Separate download, verification, inspection, and execution into distinct commands. - Update `xhs-toolkit/install_deps.py` as well, because it repeats similar unsafe installation guidance. ]]>
