T03 · Remote Payload Retrieval and Execution
- Location
SKILL.md:35- Finding
Execution of an Unpinned Remote Installation Script
- Content
View full analysis
Vulnerability Details
File Location:
SKILL.md:35-39; duplicated inreferences/02-setup.md:7-13
Vulnerability Type: Remote payload retrieval and execution
Risk Level: CriticalComplete Code Snippet:
bash curl -fsSL https://raw.githubusercontent.com/DingTalk-Real-AI/dingtalk-workspace-cli/main/scripts/install.sh -o /tmp/dws-install.sh sh /tmp/dws-install.shTechnical Analysis
The installation instructions download a shell script from the mutable
mainbranch of an external GitHub repository and execute it without verifying a cryptographic checksum, release signature, or immutable commit identifier.Saving the script before invoking
shavoids the literalcurl | shpattern, but it does not remove the underlying remote-code-execution trust boundary. The effective code executed by users can change after this Skill has been reviewed. Describing the upstream repository as official is not a technical integrity control and does not protect against repository compromise, maintainer account compromise, malicious branch updates, or an upstream supply-chain incident.Remote installer execution is not the minimum privilege required for the Skill's declared read-only DingTalk functionality. A preinstalled, version-pinned
dwsexecutable would be sufficient. Although the metadata specifies a minimum CLI version, the installation command does not pin a particular release.Attack Path
- An attacker compromises the upstream repository, a maintainer account, or the delivery path used for the mutable
mainbranch. - The attacker modifies
scripts/install.shto include malicious shell commands. - A user follows the Skill's documented installation procedure.
curlretrieves the modified script without integrity verification.shexecutes the payload with all privileges available to the user running the command.- The payload can access the user's files, authentication material, loca ...[truncated 883 chars]
- An attacker compromises the upstream repository, a maintainer account, or the delivery path used for the mutable
- Remediation
View remediation
Remediation Suggestions
- Replace the mutable
mainURL with an immutable, versioned release artifact or commit-specific URL. - Publish and verify a SHA-256 digest obtained through an independently trusted release channel.
- Prefer a trusted package manager or signed release package over direct shell-script execution.
- If a script remains necessary, instruct users to inspect it before execution.
- Fail closed when checksum or signature verification fails.
- Keep the documented version synchronized with the pinned artifact.
- Apply the same correction to both
SKILL.mdandreferences/02-setup.md.
A hardened workflow should follow this sequence:
- Create a private temporary directory using
mktemp -d. - Download an immutable release artifact.
- Verify its checksum or cryptographic signature.
- Inspect or execute it only after successful verification.
- Remove the temporary directory after installation.
- Replace the mutable
