T05 · Unauthorized Access and Privilege Escalation
- Location
agentar_cli.mjs:851- Finding
Workspace Name Path Traversal Enables Writes Outside the Intended Agent Directory
- Content
View full analysis
- Remediation
View remediation
Security audit
Security checks for vulnerabilities and agentic risk
This skill does what it claims, but it has review-worthy risks because it can install unverified remote agent packages and persistently modify or overwrite local OpenClaw workspaces.
Review this skill carefully before installing. Use only trusted registries and agentars, avoid --overwrite unless you intend to replace the main workspace, do not pass API keys on the command line, and choose simple alphanumeric agent names until the path validation issue is fixed.
agentar_cli.mjs:851Workspace Name Path Traversal Enables Writes Outside the Intended Agent Directory
agentar_cli.mjs:795Remote Agent Packages Are Installed Without Cryptographic Authenticity Verification
agentar_cli.mjs:183Trusted Executable Search Can Be Bypassed Through Path-Prefix Confusion
agentar_cli.mjs:305API Key Is Accepted Through Process Arguments and Stored as Plaintext Without an Explicit Restrictive Mode
agentar_cli.mjs:1114Mandatory Explicit-Selection Gates Are Bypassed by Blank Input Defaults
agentar_cli.mjs:17Obfuscated Child-Process Import Conceals Local Command-Execution Capability
Referenced artifact was not completely inspected
tall, export, or rollback command, you MUST verify the bundled CLI.** The CLI (`agentar_cli.mjs`) is bundled in this skill's directory — no download or copy is
Referenced artifact was not completely inspected
tall, export, or rollback command, you MUST verify the bundled CLI.** The CLI (`agentar_cli.mjs`) is bundled in this skill's directory — no download or copy is
Referenced artifact was not completely inspected
tall, export, or rollback command, you MUST verify the bundled CLI.** The CLI (`agentar_cli.mjs`) is bundled in this skill's directory — no download or copy is
Code accesses credential files (SSH keys, AWS credentials, etc.). This could indicate credential theft attempts.
];
const SKIP_FILES = ["AGENTS.md", "BOOTSTRAP.md"];
const EXPORT_SKIP_DIRS = [".git", ".openclaw", "__MACOSX", "memory"];
const SENSITIVE_PATTERNS = [".credentials", ".env", ".secret", ".key", ".pem"];
// ─── Config ──────────────────────────────────────────────────────────────────
The skill explicitly instructs the agent to run shell commands and use environment-dependent behavior, but it does not declare any tool scope such as allowed-tools or permissions. This creates a mismatch between documented capability and enforcement, increasing the chance the skill can invoke shell operations more broadly than intended without clear sandboxing or user-visible authorization boundaries.
The skill is designed to install archives that can create or overwrite agent workspaces containing configuration, skills, and behavior files. That is persistent state modification, and in this context it is security-relevant because a marketplace package can materially change future agent behavior or replace an existing workspace in one step.
**Source:** This skill is from the [CatchClaw skill repository](https://github.com/OpenAgentar/catchclaw).
An agentar is a distributable agent archive (ZIP) containing workspace files such as SOUL.md, skills, and other configuration. It can be installed as a new agent or used to overwrite an existing agent with a single command.
## Trigger Conditions
The trigger condition allows invocation on any mention of "agentar" or "catchclaw," which is overly broad for a skill that can search, install, overwrite workspaces, export archives, and rollback state. Broad activation increases the risk of accidental tool use in unrelated conversations and can expose users to unintended destructive or security-sensitive actions.
The install commands write files into agent workspaces and optionally persist credentials in a skill-local .credentials file, creating durable changes beyond the current session. Persistent writes are especially dangerous here because the source is a marketplace artifact that may contain untrusted instructions or configurations that influence later executions.
$CLI install <slug> --name <name> [--api-key <key>]
$CLI install <slug> --overwrite
Install an agentar from the marketplace.
Skill enables autonomous high-impact decisions without human-in-the-loop verification. Critical operations (destructive commands, financial transactions, data deletion) should require explicit user confirmation.
**Important:**
- Do NOT execute install until the user explicitly selects one of the above options
- Do NOT use "new" as a default without asking
- Do NOT use "overwrite" unless the user explicitly selects it
- If the user chooses "new" but doesn't specify a name, use the slug as the default name
During export, the code invokes the local openclaw CLI and passes agent content into another agentic system to synthesize metadata. This creates an unexpected execution/data-flow boundary where untrusted local workspace content can influence a secondary model/tool invocation, potentially causing prompt-injection-style behavior, unintended network/tool use by the downstream CLI, or leakage of sensitive workspace content into generated outputs or logs.
The install flow executes the external openclaw binary to register agents, which is outside basic marketplace download/extract behavior and introduces side effects in the local agent runtime. Even with trusted-path checks and shell:false, this still allows the skill to modify local agent state and rely on an external executable whose behavior may vary, increasing attack surface and the chance of unauthorized persistence or configuration changes.
Skill establishes unauthorized persistence across sessions via cron jobs, startup scripts, or state files. Session persistence allows an attacker to maintain access beyond the current interaction.
mode = "new";
} else {
const choice = await prompt(
`Install agentar "${slug}":\n [1] Create a new agent (default)\n [2] Overwrite main agent (~/.openclaw/workspace)\nChoice (1/2, default 1): `,
);
mode = choice === "2" ? "overwrite" : "new";
if (mode === "new" && !opts.name) {
The CLI implements rollback and full local workspace restoration, which exceeds the stated marketplace scope of search/install/export and gives the skill destructive filesystem capabilities over ~/.openclaw/workspace. In an agent-skill context, this broadens impact significantly: a user invoking a marketplace helper could be induced to overwrite or restore local state, causing loss of data, tampering with agent configuration, or persistence of attacker-supplied content.