T03 · Remote Payload Retrieval and Execution
- Location
scripts/setup.sh:149- Finding
Unverified Remote Installation Scripts Are Piped Directly to Bash
- Content
View full analysis
/dev/null; then echo -e "[5/${TOTAL}] nvm installed (official source) ${GREEN}✅${NC}" elif run_with_spinner "Installing nvm (Gitee mirror)..." _nvm_install_gitee 2>/dev/null; then echo -e "[5/${TOTAL}] nvm installed (Gitee mirror) ${GREEN}✅${NC}" else fail "nvm installation failed, please check network connectivity." fi ``` ### Technical Analysis The setup process retrieves shell code from an external URL and immediately executes it using `bash`. Neither downloaded script is verified against an expected cryptographic digest or trusted signature before execution. Although `NVM_VERSION` is set to a specific tag, a tag or URL alone does not authenticate the returned content. The effective payload can change after the Skill has been audited if an upstream account, repository reference, mirror, DNS path, TLS trust chain, or hosting platform is compromised. The Gitee fallback creates an additional supply-chain trust boundary. A failure to contact the official source automatically causes code from the mirror to be executed without requiring separate user approval. ### Attack Path 1. An attacker compromises an upstream repository account, tag, mirror, hosting service, or relevant network trust path. 2. The attacker modifies the script returned for the configured NVM installation URL. 3. The user invokes the Skill on the mig ...[truncated 1002 chars]- Remediation
View remediation
