T03 · Remote Payload Retrieval and Execution
Error
- Location
- SKILL.md:63
- Finding
- Mutable Remote Installation Scripts Executed Directly by a Shell## Vulnerability Details **File Locations**: - `SKILL.md:63` - `SKILL.md:68` - `README.md:30` - `README.md:35` - `README-CN.md:29` - `README-CN.md:34` **Vulnerability Type**: Remote payload retrieval and immediate execution **Risk Level**: Critical **Vulnerable Code**: ```bash # Shell installer curl -fsSL https://raw.githubusercontent.com/laiye-ai/adp-cli/main/scripts/adp-init.sh | bash ``` ```powershell # PowerShell installer irm https://raw.githubusercontent.com/laiye-ai/adp-cli/main/scripts/adp-init.ps1 | iex ``` ### Technical Analysis These installation commands retrieve scripts from the mutable `main` branch of an external GitHub repository and pass the responses directly to `bash` or PowerShell's `Invoke-Expression`. The downloaded content is not displayed for review, pinned to an immutable commit, checked against a cryptographic digest, or authenticated with a vendor signature. Although the repository name is consistent with the advertised vendor, this project contains neither the installer source nor a checksum or signature that would allow the reviewed artifact to establish what code will run. The effective payload can therefore change after this Skill has been audited. The commands also create a time-of-check/time-of-use trust problem: even if the remote script is benign at one point, compromise of the repository, publisher account, release process, or another relevant delivery component could cause subsequent installations to execute attacker-controlled code. `curl -f` and HTTPS protect against some transport failures but do not establish artifact immutability or publisher-controlled code signing. Direct shell execution exceeds the minimum privilege necessary for the declared document-extraction functionality. Installing a CLI may be necessary, but executing an unverified mutable response is not. The script inherits all privileges and environmental access of the user who launches it; if invoked with elevated privileges, the payload receives t ...[truncated 1539 chars]
- Remediation
- ## Remediation Suggestions 1. Remove all direct `curl | bash` and `irm | iex` installation instructions. 2. Publish versioned installation artifacts through immutable releases rather than a mutable branch. 3. Instruct users to download the installer to disk without executing it: ```bash curl -fL -o adp-init.sh https://example.invalid/releases/download/vX.Y.Z/adp-init.sh ``` 4. Publish a SHA-256 digest over a separate authenticated channel and require verification before execution: ```bash echo '<expected-sha256> adp-init.sh' | sha256sum --check - ``` 5. Sign release artifacts with a documented vendor signing key and require signature verification. A checksum hosted beside a compromised artifact is insufficient by itself. 6. Pin documentation to a specific release version or immutable commit rather than `main`. 7. Advise users to inspect the downloaded script and execute it explicitly only after verification. 8. Ensure the installer does not require administrator privileges unless a specific installation step genuinely needs them. Prefer installation into a user-owned directory. 9. Apply equivalent download, signature, and version-pinning controls to the PowerShell installer. 10. Document all filesystem changes, network requests, and executable locations used by the installer.
