Back to skill

Security audit

ClawAPI

Security checks for vulnerabilities and agentic risk

Overview

The skill's stated app is coherent, but its installer can run a mutable remote shell script before review, so users should review it carefully before installing.

Prefer the manual signed GitHub Release path over the curl-to-bash installer. Before using this skill, understand that it manages provider API keys, writes a sync copy into OpenClaw's auth-profiles.json, and modifies OpenClaw configuration; verify the app signature, release provenance, and any installer script before running it.

Vulnerability Patterns
  • Remote Payload Retrieval and ExecutionFetches external code whose behavior can change after review
  • Skill Instruction HijackingAlters the agent's session goals or safety constraints when the skill loads
  • Agent Memory PoisoningWrites attacker-controlled rules into memory that affect later sessions
  • Embedded Malicious CodeShips malicious scripts inside the skill and executes them locally
  • Unauthorized Access and Privilege EscalationObtains permissions beyond the task's legitimate needs
Findings (1)

T03 · Remote Payload Retrieval and Execution

Error
Location
SKILL.md:6
Finding
Mutable Remote Installation Script Is Executed Directly by Bash<![CDATA[ ## Vulnerability Details **File Location**: `SKILL.md:6`, `SKILL.md:29`, and `README.md:14` **Vulnerability Type**: Remote payload retrieval and execution **Risk Level**: Critical ### Vulnerable Code `SKILL.md:6`: ```yaml metadata: {"openclaw":{"emoji":"🔑","requires":{"bins":["curl"],"config":["skills.entries.clawapi"]},"install":[{"kind":"script","command":"curl -fsSL https://raw.githubusercontent.com/Gogo6969/clawapi/main/install.sh | bash"}]}} ``` `SKILL.md:28-30`: ```bash curl -fsSL https://raw.githubusercontent.com/Gogo6969/clawapi/main/install.sh | bash ``` `README.md:13-15`: ```bash curl -fsSL https://raw.githubusercontent.com/Gogo6969/clawapi/main/install.sh | bash ``` ### Technical Analysis The installation command retrieves `install.sh` from the mutable `main` branch of a personal GitHub repository and pipes the response directly into Bash. This creates a remote code-execution channel whose effective payload may change after the Skill package has been reviewed. The audited project contains only `README.md` and `SKILL.md`. It does not include the installer, application source, a pinned Git commit, a release artifact checksum, or a trusted manifest against which the remote content can be independently verified. Consequently, the documentation claims that the installer downloads a signed archive and validates its SHA-256 checksum cannot be confirmed from the audited files. Even if the current remote script is benign, the command does not bind installation to that version. Compromise of the GitHub account or repository, malicious modification of the `main` branch, or other control over the retrieved response could replace the installer with arbitrary shell commands. The `-f`, `-s`, and `-S` options affect transfer behavior but do not authenticate the content beyond HTTPS transport and do not provide payload immutability. This behavior exceeds the minimum privileges required for the declared Skill functionality. Describing or launchi ...[truncated 2346 chars]
Remediation
<![CDATA[ ## Remediation Suggestions 1. Remove the automatic `curl | bash` installer from the Skill metadata and documentation. 2. Prefer a manually downloaded, versioned GitHub Release that users can inspect and verify before installation. 3. Pin every download to an immutable release version and commit rather than a mutable branch such as `main`. 4. Publish a fixed SHA-256 digest in the audited Skill package or through another trusted, independently controlled channel. Do not retrieve both the artifact and its expected checksum from the same mutable source without additional signature verification. 5. Download the installer or archive to a local file first instead of piping it directly into a shell. Verify integrity and authenticity before any execution. 6. Verify the macOS application signature and notarization status locally, for example with appropriate `codesign` and `spctl` checks, before moving it into `/Applications`. 7. Include the installer source in the reviewed project so its network requests, filesystem changes, permission requirements, and checksum verification can be audited. 8. If automation is essential, use a minimal installer pinned to a reviewed immutable commit and require explicit user confirmation before execution. 9. Document the exact files and directories the installer modifies and ensure it runs without elevated privileges unless a narrowly scoped privileged operation is demonstrably necessary. 10. Provide rollback instructions and ensure installation does not create launch agents, scheduled jobs, login items, or other persistence without explicit disclosure and consent. ]]>
Vulnerability Patterns
  • Supply ChainUnpinned Dependencies, External Script Fetching, Obfuscated Code
  • Tool MisuseTool Parameter Abuse, Chaining Abuse, Unsafe Defaults
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
Findings (5)

Chaining Abuse

High
Category
Tool Misuse
Content
**Option 2 — Install script:**
```bash
curl -fsSL https://raw.githubusercontent.com/Gogo6969/clawapi/main/install.sh | bash
```
The script downloads the signed `.zip` from GitHub Releases, verifies the SHA-256 checksum, and installs the app. [Review the script source](https://github.com/Gogo6969/clawapi/blob/main/install.sh) before running.
Confidence
98% confidence
Finding
The use of '| bash' is a classic chaining pattern that executes network-retrieved content immediately, eliminating meaningful user review and turning any upstream compromise into direct code execution on the user's machine. In the context of a tool that manages API keys and modifies local auth configuration, successful exploitation could steal credentials, alter model/provider settings, or install persistence on the host.

Chaining Abuse

High
Category
Tool Misuse
Content
### Option 2: Install script

```bash
curl -fsSL https://raw.githubusercontent.com/Gogo6969/clawapi/main/install.sh | bash
```

The install script downloads the same signed `.zip` from GitHub Releases, verifies the SHA-256 checksum, unzips it, and moves the app to `/Applications`. You can [review the script source](https://github.com/Gogo6969/clawapi/blob/main/install.sh) before running it.
Confidence
98% confidence
Finding
Using '| bash' chains network retrieval directly into command execution, eliminating an inspection step and increasing the blast radius of any upstream compromise. In this skill's context, the app manages API keys and writes to OpenClaw configuration, so installer compromise could expose secrets, alter configs, or install persistence on the host.

External Script Fetching

Low
Category
Supply Chain
Content
**Option 2 — Install script:**
```bash
curl -fsSL https://raw.githubusercontent.com/Gogo6969/clawapi/main/install.sh | bash
```
The script downloads the signed `.zip` from GitHub Releases, verifies the SHA-256 checksum, and installs the app. [Review the script source](https://github.com/Gogo6969/clawapi/blob/main/install.sh) before running.
Confidence
96% confidence
Finding
The README instructs users to fetch and execute a remote script in a single command, which creates a supply-chain and remote code execution risk if the GitHub account, repository, branch, or delivery path is ever compromised. Even though the text says the script verifies a checksum and suggests reviewing the source, the dangerous part is that arbitrary shell code is executed before the user can independently validate what it does.

External Script Fetching

Low
Category
Supply Chain
Content
description: Switch AI models and manage API keys for OpenClaw with a native macOS app. Supports 16 providers including OpenAI, Anthropic, xAI, Google, Groq, Ollama, LM Studio, and more.
homepage: https://github.com/Gogo6969/clawapi
user-invocable: true
metadata: {"openclaw":{"emoji":"🔑","requires":{"bins":["curl"],"config":["skills.entries.clawapi"]},"install":[{"kind":"script","command":"curl -fsSL https://raw.githubusercontent.com/Gogo6969/clawapi/main/install.sh | bash"}]}}
---

# ClawAPI — Model Switcher & Key Vault for OpenClaw
Confidence
96% confidence
Finding
The skill metadata includes an install command that fetches a remote script and immediately executes it with bash. This creates a direct remote code execution path during installation: if the upstream GitHub content, repository, account, or network path is compromised, arbitrary code will run on the user's machine without prior inspection.

External Script Fetching

Low
Category
Supply Chain
Content
### Option 2: Install script

```bash
curl -fsSL https://raw.githubusercontent.com/Gogo6969/clawapi/main/install.sh | bash
```

The install script downloads the same signed `.zip` from GitHub Releases, verifies the SHA-256 checksum, unzips it, and moves the app to `/Applications`. You can [review the script source](https://github.com/Gogo6969/clawapi/blob/main/install.sh) before running it.
Confidence
95% confidence
Finding
The documentation instructs users to run a curl-to-bash install command, which is an unsafe installation pattern even if the referenced script currently performs checksum verification later. The risk occurs before any script-internal validation, because untrusted remote code is already being executed by the shell.