T08 · Insecure Dependencies
- Location
scripts/install_aliyun_cli.sh:70- Finding
Unverified Remote CLI Binary Is Downloaded and Installed
- Content
View full analysis
- Remediation
View remediation
Security audit
Security checks for vulnerabilities and agentic risk
This skill is built for real Alibaba Cloud voice calls, but it can place calls with too little confirmation and includes under-scoped credential and install helpers.
Review carefully before installing. Use only a tightly scoped RAM user or short-lived STS profile, avoid root or broad Alibaba Cloud profiles, do not enable debug on the fallback RPC script, and require an explicit final confirmation showing the intended recipient and message before any call is placed.
scripts/install_aliyun_cli.sh:70Unverified Remote CLI Binary Is Downloaded and Installed
scripts/dyvmsapi_rpc.py:184Credential-Bearing RPC Requests Can Be Redirected to an Arbitrary Endpoint
scripts/dyvmsapi_rpc.py:226Debug Output Discloses STS Tokens, AccessKey IDs, and Call Intent
scripts/run_with_aliyun_creds.py:218Generic Subprocess Wrapper Exposes Alibaba Cloud Credentials to Arbitrary Commands
The skill also performs credential-profile inspection and instructs the use of a helper that injects Alibaba Cloud credentials into subprocess environments, yet this sensitive behavior is not clearly declared in the skill's purpose. Hidden credential handling materially raises the risk of privilege misuse, accidental leakage, or abuse through arbitrary subcommand execution under cloud credentials.
The skill also performs credential-profile inspection and instructs the use of a helper that injects Alibaba Cloud credentials into subprocess environments, yet this sensitive behavior is not clearly declared in the skill's purpose. Hidden credential handling materially raises the risk of privilege misuse, accidental leakage, or abuse through arbitrary subcommand execution under cloud credentials.
Remote code is downloaded and executed. This bypasses code review and could introduce malicious code.
> **Notes**:
> - **Do not** run `curl -fsSL https://aliyuncli.alicdn.com/setup.sh | bash` to install the CLI: piping a remote script directly to a shell **bypasses integrity verification and is treated as a security violation** by static scanners; that script also writes to `/usr/local/bin/aliyun` and silently retries with `sudo`, which fails in non-interactive shells (agent sandboxes, CI runners) where no tty is available to type the password. The installer above downloads only the **signed binary tarball**, never executes a remote script, and routes around the sudo issue.
> - On Apple Silicon Macs the installer pulls `aliyun-cli-macosx-latest-arm64.tgz`; **never** install the `amd64` build on arm64 hardware — it requires Rosetta 2 and is brittle.
> - **Verify before continuing**: the installer exits non-zero if the resulting `aliyun version` is < `3.3.8`. If it fails, switch to the manual matrix in [`references/cli-installation-guide.md`](./references/cli-installation-guide.md) (it covers macOS amd64/arm64, Linux amd64/arm64, and Windows, each with a sudo-less variant).
Referenced artifact was not completely inspected
- For error handling, see the error-code table in `references/related-commands.md`
Referenced artifact was not completely inspected
- For error handling, see the error-code table in `references/related-commands.md`
Referenced artifact was not completely inspected
- For error handling, see the error-code table in `references/related-commands.md`
Referenced artifact was not completely inspected
- For error handling, see the error-code table in `references/related-commands.md`
YARA rule matched a known malware signature (reverse shell, backdoor, ransomware, C2 framework, or info stealer).
` is not writable.
DEST="$HOME/.local/bin"
mkdir -p "$DEST"
case "$(uname -m)" in
x86_64|amd64) ARCH=amd64 ;;
aarch64|arm64) ARCH=arm64 ;;
*) echo "Unsupported arch: $(uname -m)" >&2; exit 1 ;;
esac
curl -fsSL "https://aliyuncli.alicdn.com/aliyun-cli-linux-latest-${ARCH}.tgz" \
| tar -xz -C "$DEST"
chmod +x "$DEST/aliyun"
export PATH="$DEST:$PATH"
grep -qsF "$DEST" ~/.bashrc || echo "export PATH=\"$DEST:\$PATH\"" >> ~/.bashrc
hash -r
aliyun version
Using Binary
aliyun versionUsing PowerShell
# Download
Invoke-WebRequest -Uri "https://aliyuncli.alicdn.com/aliyun-cli-windows-latest-amd64.zip" -OutFile "aliyun-cli.zip"
# Extract
Expand-Archive -Path aliyun-cli.zip -DestinationPath C:\aliyun-cli
# Add to PATH at th
Tool parameters are crafted to achieve unintended or unsafe behavior. Parameter abuse can bypass intended safety checks (e.g. shell=True, --force, dangerous glob patterns).
cp ~/.aliyun.bak.<ts>/config.json ~/.aliyun/).rm -rf ~/.aliyun — it is irrecoverable and a static-scanner red flag.mv ~/.aliyun ~/.aliyun.bak."$(date +%Y%m%d-%H%M%S)"
aliyun configure to create a fresh profile.Tool parameters are crafted to achieve unintended or unsafe behavior. Parameter abuse can bypass intended safety checks (e.g. shell=True, --force, dangerous glob patterns).
cp ~/.aliyun.bak.<ts>/config.json ~/.aliyun/).rm -rf ~/.aliyun — it is irrecoverable and a static-scanner red flag.mv ~/.aliyun ~/.aliyun.bak."$(date +%Y%m%d-%H%M%S)"
aliyun configure to create a fresh profile.Tool parameters are crafted to achieve unintended or unsafe behavior. Parameter abuse can bypass intended safety checks (e.g. shell=True, --force, dangerous glob patterns).
cp ~/.aliyun.bak.<ts>/config.json ~/.aliyun/).rm -rf ~/.aliyun — it is irrecoverable and a static-scanner red flag.mv ~/.aliyun ~/.aliyun.bak."$(date +%Y%m%d-%H%M%S)"
aliyun configure to create a fresh profile.Remote code is downloaded and executed. This bypasses code review and could introduce malicious code.
# Strategy 1 — Homebrew (preferred on macOS / Linuxbrew; brew tracks
# updates and removal cleanly).
# Strategy 2 — User-level binary tarball under $HOME/.local/bin
# (no sudo, no brew, no `curl | bash`).
#
# Properties:
# - Idempotent: safe to re-run; brew path uses upgrade-or-install,
The script downloads an archive from a remote CDN and immediately extracts it into a user-controlled bin directory without validating a cryptographic checksum or signature in the script itself. Although this is not curl|bash, it still trusts network-delivered content at install time; if the CDN, transport path, or artifact is compromised, a malicious aliyun binary could be planted and later executed by the user or agent.
log "Strategy 2: downloading signed tarball ${tarball} into ${USER_BIN_DIR}/"
mkdir -p "$USER_BIN_DIR"
# `curl -fsSL ... | tar -xz -C ...` extracts the tarball stream to the
# destination; this is NOT `curl | bash`. No remote script is ever executed.
curl -fsSL "$url" | tar -xz -C "$USER_BIN_DIR" \
|| fail "Download or extract failed for ${url}"
chmod +x "${USER_BIN_DIR}/aliyun"
os.system() and os exec-family calls run shell commands with the process's full privileges, enabling arbitrary command execution.
# Use os.execvpe to replace the current process; the child's exit code is
# propagated naturally.
try:
os.execvpe(cmd[0], cmd, env)
except FileNotFoundError:
print(
f"[run_with_aliyun_creds] ERROR: executable not found: {cmd[0]}",
The skill uses powerful capabilities including shell, network, file access, and environment/credential handling, but it does not declare any explicit tool scope or permission boundaries. That makes it harder for the host agent or reviewer to enforce least privilege and increases the chance of unintended command execution, filesystem changes, or credential exposure during use.
The trigger phrases include broad everyday expressions such as 'AI 打电话', 'smart voice call', and '给某人打电话', which can cause accidental invocation of a skill that places real outbound calls. Because the skill can initiate real-world actions affecting third parties, over-broad activation language materially increases misuse and surprise execution risk.
The skill description does not prominently warn that execution may place a real phone call to a contact selected via semantic matching from the user's address book. Without a strong upfront warning, users may not appreciate that the action is external, irreversible, and may reach the wrong recipient if matching is mistaken.
The skill instructs persistent local modifications such as installing or overwriting CLI plugins and enabling AI-mode, and it depends on cleanup steps being followed perfectly. Persistent environment changes can outlive the skill session, affect other workflows, and leave the system in a more privileged or altered state than the user expected if execution is interrupted.
Plugin aliyun-cli-dyvmsapi 0.1.0 installed successfully!
> If the output reads `plugin "aliyun-cli-dyvmsapi" is already installed (version X.Y.Z); continuing will replace it with version 0.1.0` → **expected behavior** (overwrite install). Let it finish.
>
> If the output reads `ERROR: invalid flag source-base` → **CLI version is < 3.3.8** and does not understand the flag. Re-run the **environment-aware fallback chain in §1.1** (it auto-picks brew / system-wide / user-level upgrade) to upgrade, then retry §1.3. **[FORBIDDEN]** It is strictly forbidden to switch to §1.alt due to this error — this is a tooling-version issue, not a network issue. The external fallback is reserved for `no such host` / `connection timeout` only.
>
The skill explicitly allows execution without confirmation when the model judges the user's intent to be clear, even though the result is a real outbound call to another person. Autonomous execution is dangerous here because mistakes in intent understanding or contact resolution can trigger harassment, privacy violations, or fraudulent communications without a final human check.
## 5. Parameter Confirmation
> **IMPORTANT: Parameter Confirmation** — Before executing the API call,
> confirm the user's **intent** (who to call + what to convey). If the user's message already makes both clear, no confirmation is needed — proceed directly.
> Do NOT iterate on wording or draft the spoken text — `UserMessage` is an intent description,
> not the final playback script; the server-side LLM generates the actual spoken content (`Model.CallContent`).
The 'zero or one round, then fire' rule minimizes friction at the cost of safety for a high-impact external action. Combined with semantic contact matching and LLM-generated call content, this creates a significant risk of wrong-recipient calls or unintended messages being delivered without robust user verification.
Extract **who** to call and **what** to convey from the user's message. A natural-language reference is sufficient (e.g. "我爸", "Mom", "张经理") — it does **not** need to be the exact Tag literal stored in the address book; the server-side LLM performs **semantic matching** against the user's contact list.
- **Intent already clear** (who + what both unambiguous) → skip confirmation, proceed to Step 2 immediately. Example: "Call my dad and tell him to go grocery shopping" — who=dad, what=go grocery shopping, fire directly.
- **Intent partially unclear** (missing who, or what is too vague to act on) → ask **once** to clarify the missing part, then fire. Example: "Make a call" — who=? what=? ask once.
> **[MUST] Zero or one round, then fire** — `UserMessage` is NOT the verbatim script that will be spoken; it is an intent description fed to the server-side LLM, which generates the actual spoken content. Once who + what are clear (whether from the original message or a single clarification), proceed to Step 2 immediately. Prohibited behaviors:
Commands invoke sudo or root privileges. Verify this elevated access is necessary and justified.
> | Runtime | Architecture | Recommended Strategy | Why |
> |---|---|---|---|
> | macOS with Homebrew | Apple Silicon (`arm64`) or Intel (`x86_64`) | **macOS · Homebrew** | Managed by `brew`; `brew upgrade` keeps it current; works for both architectures |
> | macOS without Homebrew, **with** sudo | Intel | macOS · Binary (Intel, system-wide) | Standard `/usr/local/bin` install |
> | macOS without Homebrew, **with** sudo | Apple Silicon | macOS · Binary (Apple Silicon, system-wide) | Native arm64 binary; **do not use the `amd64` build on arm64 hardware** |
> | macOS, **no** sudo (agent sandbox, restricted user) | any | macOS · Binary (user-level, no sudo) | Drops into `$HOME/.local/bin` and updates PATH |
> | Linux with sudo (Debian/Ubuntu/CentOS/RHEL) | `amd64` or `arm64` | Linux · Binary (system-wide) | Standard `/usr/local/bin` install |
Commands invoke sudo or root privileges. Verify this elevated access is necessary and justified.
> | Runtime | Architecture | Recommended Strategy | Why |
> |---|---|---|---|
> | macOS with Homebrew | Apple Silicon (`arm64`) or Intel (`x86_64`) | **macOS · Homebrew** | Managed by `brew`; `brew upgrade` keeps it current; works for both architectures |
> | macOS without Homebrew, **with** sudo | Intel | macOS · Binary (Intel, system-wide) | Standard `/usr/local/bin` install |
> | macOS without Homebrew, **with** sudo | Apple Silicon | macOS · Binary (Apple Silicon, system-wide) | Native arm64 binary; **do not use the `amd64` build on arm64 hardware** |
> | macOS, **no** sudo (agent sandbox, restricted user) | any | macOS · Binary (user-level, no sudo) | Drops into `$HOME/.local/bin` and updates PATH |
> | Linux with sudo (Debian/Ubuntu/CentOS/RHEL) | `amd64` or `arm64` | Linux · Binary (system-wide) | Standard `/usr/local/bin` install |
Commands invoke sudo or root privileges. Verify this elevated access is necessary and justified.
> | Runtime | Architecture | Recommended Strategy | Why |
> |---|---|---|---|
> | macOS with Homebrew | Apple Silicon (`arm64`) or Intel (`x86_64`) | **macOS · Homebrew** | Managed by `brew`; `brew upgrade` keeps it current; works for both architectures |
> | macOS without Homebrew, **with** sudo | Intel | macOS · Binary (Intel, system-wide) | Standard `/usr/local/bin` install |
> | macOS without Homebrew, **with** sudo | Apple Silicon | macOS · Binary (Apple Silicon, system-wide) | Native arm64 binary; **do not use the `amd64` build on arm64 hardware** |
> | macOS, **no** sudo (agent sandbox, restricted user) | any | macOS · Binary (user-level, no sudo) | Drops into `$HOME/.local/bin` and updates PATH |
> | Linux with sudo (Debian/Ubuntu/CentOS/RHEL) | `amd64` or `arm64` | Linux · Binary (system-wide) | Standard `/usr/local/bin` install |
Commands invoke sudo or root privileges. Verify this elevated access is necessary and justified.
> | Runtime | Architecture | Recommended Strategy | Why |
> |---|---|---|---|
> | macOS with Homebrew | Apple Silicon (`arm64`) or Intel (`x86_64`) | **macOS · Homebrew** | Managed by `brew`; `brew upgrade` keeps it current; works for both architectures |
> | macOS without Homebrew, **with** sudo | Intel | macOS · Binary (Intel, system-wide) | Standard `/usr/local/bin` install |
> | macOS without Homebrew, **with** sudo | Apple Silicon | macOS · Binary (Apple Silicon, system-wide) | Native arm64 binary; **do not use the `amd64` build on arm64 hardware** |
> | macOS, **no** sudo (agent sandbox, restricted user) | any | macOS · Binary (user-level, no sudo) | Drops into `$HOME/.local/bin` and updates PATH |
> | Linux with sudo (Debian/Ubuntu/CentOS/RHEL) | `amd64` or `arm64` | Linux · Binary (system-wide) | Standard `/usr/local/bin` install |
Commands invoke sudo or root privileges. Verify this elevated access is necessary and justified.
> | Runtime | Architecture | Recommended Strategy | Why |
> |---|---|---|---|
> | macOS with Homebrew | Apple Silicon (`arm64`) or Intel (`x86_64`) | **macOS · Homebrew** | Managed by `brew`; `brew upgrade` keeps it current; works for both architectures |
> | macOS without Homebrew, **with** sudo | Intel | macOS · Binary (Intel, system-wide) | Standard `/usr/local/bin` install |
> | macOS without Homebrew, **with** sudo | Apple Silicon | macOS · Binary (Apple Silicon, system-wide) | Native arm64 binary; **do not use the `amd64` build on arm64 hardware** |
> | macOS, **no** sudo (agent sandbox, restricted user) | any | macOS · Binary (user-level, no sudo) | Drops into `$HOME/.local/bin` and updates PATH |
> | Linux with sudo (Debian/Ubuntu/CentOS/RHEL) | `amd64` or `arm64` | Linux · Binary (system-wide) | Standard `/usr/local/bin` install |