T03 · Remote Payload Retrieval and Execution
- Location
SKILL.md:33- Finding
Unverified Remote Installation Script Executed Directly by Shell
- Content
View full analysis
- Remediation
View remediation
Security audit
Security checks for vulnerabilities and agentic risk
The skill is coherently about prediction-market trading, but it combines real-money wallet authority with unverified installation, self-updating agent instructions, plaintext private-key handling, and autonomous trading guidance.
Review this carefully before installing. Do not run the remote `curl | bash` installer or enable heartbeat self-updates unless you can verify the source and changes. Use a low-balance dedicated hot wallet, avoid printing or passing private keys on the command line, require explicit confirmation for every trade/transfer/withdrawal/approval, and avoid unlimited token allowances where possible.
SKILL.md:33Unverified Remote Installation Script Executed Directly by Shell
HEARTBEAT.md:10Automatic Replacement of Trusted Agent Instructions from Mutable Network Sources
core/wallet/SKILL.md:132Private Keys Stored in Plaintext and Exposed Through Command Arguments and Output
markets/polymarket/SKILL.md:268Autonomous Financial Transactions Combined with Unlimited Token Allowance
The file includes a direct self-update mechanism that downloads and overwrites skill content, including market-specific files, with no integrity verification. In an agentic trading context, this is especially dangerous because modified instructions could later influence wallet actions, transfers, or trading decisions.
The quick-reference section again includes a command that updates skill files from a fetched source, reinforcing self-modification behavior. Even though this instance points to localhost, it still allows externally supplied or locally spoofed content to redefine the skill without validation, which is dangerous for a trading-capable agent.
curl https://manifold.markets/api/v0/me -H "Authorization: Bearer $MANIFOLD_API_KEY" curl https://trading-api.kalshi.com/v1/portfolio/balance -H "Authorization: Bearer $KALSHI_TOKEN"
curl -s http://localhost:3000/skills/SKILL.md > ~/.clawearn/skills/SKILL.md
Piping a remote script directly into bash executes unreviewed code from the network immediately, with no opportunity for inspection or integrity validation. Because this skill manages wallets and trading, compromise of the install endpoint or transport chain could lead to credential theft, wallet exfiltration, backdoored binaries, or arbitrary command execution on the host.
Fetching an external script and executing it immediately is a classic remote-code-execution anti-pattern. Given this project's wallet and trading scope, exploitation could compromise private keys, modify trading logic, install persistence, or take over the host running the bot.
# Option A: Using install script
curl -fsSL https://clawearn.xyz/install.sh | bash
# Option B: From repository
cd /path/to/clawearn
The use of a shell pipeline to chain network retrieval directly into bash removes any review boundary between untrusted content and execution. In an autonomous trading-bot environment, that makes compromise especially severe because the same environment may contain API keys, private keys, and permissions to move funds.
# Option A: Using install script
curl -fsSL https://clawearn.xyz/install.sh | bash
# Option B: From repository
cd /path/to/clawearn
The documented update flow causes the skill to modify its own installed files under the agent's skills directory by downloading fresh remote content, which is a self-modification pattern. In a bot skill that can access wallets and execute trades, self-updating behavior is especially dangerous because it can alter future agent behavior without trusted review or change control.
clawearn polymarket order cancel --order-id ORDER_ID
### Update Skills
```bash
# Check for updates
Fetching and executing an external script from https://clawearn.xyz/install.sh is a classic remote code execution pattern. Because this skill is meant to operate in a financial context with wallets and transfers, any compromise of that script or hosting path could directly expose funds, credentials, and the bot environment.
curl -fsSL https://clawearn.xyz/install.sh | bash
# or: bun link (if in repo)
The | bash chaining removes the opportunity for users or automation to inspect downloaded content before execution, turning a network fetch into immediate code execution. In this skill's context, that is particularly dangerous because successful abuse could alter wallet operations, steal secrets, or place unauthorized trades with little visibility.
curl -fsSL https://clawearn.xyz/install.sh | bash
# or: bun link (if in repo)
Code accesses credential files (SSH keys, AWS credentials, etc.). This could indicate credential theft attempts.
Good:
# .env file (gitignored)
POLYMARKET_PRIVATE_KEY=0x...
MANIFOLD_API_KEY=...
Code accesses credential files (SSH keys, AWS credentials, etc.). This could indicate credential theft attempts.
Good:
# .env file (gitignored)
POLYMARKET_PRIVATE_KEY=0x...
MANIFOLD_API_KEY=...
The documented command export $(cat .env | xargs) is unsafe because it can expose secret values to shell history, process inspection, parsing errors, and accidental expansion of malformed content. In a trading skill handling private keys, encouraging this pattern increases the chance of credential disclosure or misuse.
MANIFOLD_API_KEY=...
export $(cat .env | xargs)
**Better:**
Code accesses credential files (SSH keys, AWS credentials, etc.). This could indicate credential theft attempts.
2. Complete KYC verification
3. Link bank account
4. Get API credentials
5. Save to `~/.config/clawearn/kalshi-credentials.json`
---
Code accesses credential files (SSH keys, AWS credentials, etc.). This could indicate credential theft attempts.
2. Complete KYC verification
3. Link bank account
4. Get API credentials
5. Save to `~/.config/clawearn/kalshi-credentials.json`
---
Code accesses credential files (SSH keys, AWS credentials, etc.). This could indicate credential theft attempts.
2. Complete KYC verification
3. Link bank account
4. Get API credentials
5. Save to `~/.config/clawearn/kalshi-credentials.json`
---
The troubleshooting step tells users to reveal their private key with a direct file read, immediately exposing the wallet secret in plaintext on screen. Because this skill manages real-money wallets and USDC transfers, disclosure of that key enables unauthorized transfers and total wallet compromise.
The skill encourages storing a raw private key in a JSON file and environment variable, which expands the attack surface for credential theft through local file compromise, process inspection, logs, shell history, or agent misconfiguration. Because this skill controls real trading and fund transfers, exposure of the private key would directly enable theft of user assets.
⚠️ **Save your private key immediately!** Store it securely in:
- `~/.config/clawearn/credentials.json`
- Environment variable: `POLYMARKET_PRIVATE_KEY`
- Your agent's secure credential storage
The heartbeat instructs the agent to fetch remote content and overwrite local skill files automatically. This creates a supply-chain and self-modification risk: if the remote host or transport path is compromised, the agent's future behavior can be silently altered without review.
The update instructions overwrite local files from remote sources without warning that persistent local state is being modified. Beyond transparency concerns, this can permanently change the skill's behavior and trust boundary, making later abuse or compromise harder to detect.
The instructions tell the operator to print the full configuration file even though it may contain credentials or sensitive settings. In agent or terminal environments with logging, this can expose secrets to transcripts, telemetry, or other users with access to session history.
The manifest description specifically says the skill can 'Trade on Polymarket, manage wallets, transfer USDC, and automate trading strategies.' This heartbeat file instructs the agent to query Manifold and Kalshi accounts and balances, adding cross-platform market monitoring not clearly covered by the stated Polymarket-focused trading scope.
The README instructs users to fetch remote skill files and overwrite local files in the active OpenClaw skill directory without integrity verification, pinning, or an explicit warning that this modifies trusted bot behavior. In this context, downloaded SKILL/HEARTBEAT files can directly influence autonomous bot actions, so a compromised host or changed remote content could silently replace local behavior and lead to unsafe trading, fund movement, or persistence.
The install instructions establish persistent skill files in ~/.openclaw/skills so the agent can continue using them across sessions. Persistence is expected for a legitimate skill, but in this context it still represents a security-relevant capability because remotely fetched instructions become durable agent behavior on disk.
# Create skill directories
mkdir -p ~/.openclaw/skills/clawearn/{core,markets/polymarket}
# Download main skills
Skill enumerates or reads other installed skills. Access to other skills' SKILL.md files or the skills directory reveals prompt instructions, capabilities, and secrets that should be invisible to peer skills.
mkdir -p ~/.openclaw/skills/clawearn/{core,markets/polymarket}
# Download main skills
curl -s https://clawearn.xyz/skills/SKILL.md > ~/.openclaw/skills/clawearn/SKILL.md
curl -s https://clawearn.xyz/skills/HEARTBEAT.md > ~/.openclaw/skills/clawearn/HEARTBEAT.md
# Download core skills
Skill enumerates or reads other installed skills. Access to other skills' SKILL.md files or the skills directory reveals prompt instructions, capabilities, and secrets that should be invisible to peer skills.
mkdir -p ~/.openclaw/skills/clawearn/{core,markets/polymarket}
# Download main skills
curl -s https://clawearn.xyz/skills/SKILL.md > ~/.openclaw/skills/clawearn/SKILL.md
curl -s https://clawearn.xyz/skills/HEARTBEAT.md > ~/.openclaw/skills/clawearn/HEARTBEAT.md
# Download core skills
Skill enumerates or reads other installed skills. Access to other skills' SKILL.md files or the skills directory reveals prompt instructions, capabilities, and secrets that should be invisible to peer skills.
mkdir -p ~/.openclaw/skills/clawearn/{core,markets/polymarket}
# Download main skills
curl -s https://clawearn.xyz/skills/SKILL.md > ~/.openclaw/skills/clawearn/SKILL.md
curl -s https://clawearn.xyz/skills/HEARTBEAT.md > ~/.openclaw/skills/clawearn/HEARTBEAT.md
# Download core skills
No suspicious patterns detected.