T03 · Remote Payload Retrieval and Execution
Warning
- Location
- SKILL.md:43
- Finding
- Execution of Unpinned Code Retrieved from a Remote Repository## Vulnerability Details **File Location**: `SKILL.md`, lines 43-47 **Vulnerability Type**: Remote payload retrieval and execution **Risk Level**: Medium ```bash git clone https://github.com/dyz2102/xiabb.git /tmp/xiabb-build cd /tmp/xiabb-build # Review install.sh and native/main.swift before running cat install.sh bash install.sh ``` ### Technical Analysis The build instructions clone the mutable default branch of a remote GitHub repository and then direct the user to execute its `install.sh` script. The repository is not pinned to a reviewed commit, immutable release tag, or cryptographically verified source archive. Consequently, the code executed by the user may differ from the code that existed when this Skill was audited. Displaying the script with `cat` does not provide a reliable security boundary. A user may not fully inspect the script or its transitive behavior, and the script can retrieve and execute additional mutable content. Although the repository is fetched over HTTPS, transport security does not protect against compromise of the upstream repository, maintainer account, or release process. ### Attack Path 1. An attacker compromises the upstream repository, a maintainer account, or the repository's default branch. 2. The attacker modifies `install.sh`, or another resource invoked by it, to contain malicious commands. 3. A user follows the documented build-from-source procedure and clones the mutable default branch. 4. The user runs `bash install.sh` as instructed. 5. The attacker-controlled commands execute with the privileges and environment of the invoking user. ### Impact Assessment Successful exploitation permits arbitrary command execution in the invoking user's security context. The payload could read or alter files accessible to that user, access environment variables such as `GEMINI_API_KEY` if present, make network requests, install user-level persistence, or download further payloads. ...[truncated 252 chars]
- Remediation
- ## Remediation Suggestions - Pin the source to a specific reviewed commit hash rather than cloning the mutable default branch. - Publish the expected commit identifier or archive SHA-256 checksum in `SKILL.md` and require verification before execution. - Prefer downloading a source archive from an immutable release and validating its checksum and release signature. - If a Git tag is used, require a signed tag and verify its signature; a tag name alone may be moved. - Replace the generic installation script with explicit, reviewable build commands where practical. - Audit `install.sh`, `native/main.swift`, and every script or remote resource they invoke before recommending execution. - Fail closed if the checked-out commit, checksum, or signature does not match the documented trusted value.
