Back to skill

Security audit

Don't Be Scary

Security checks for vulnerabilities and agentic risk

Overview

This skill has a coherent OpenClaw update purpose, but it runs a detached updater that can modify and delete installation paths using unsafe, user-controllable settings.

Review this before installing. It is not clearly malicious, but it can update OpenClaw, restart LaunchAgents, run detached in the background, read Telegram bot credentials, send status to Telegram, and delete/restore application directories. Only use it if you trust the publisher and understand the configured paths; avoid untrusted environment overrides and prefer a version that validates paths, uses safe temporary files, and asks before destructive rollback actions.

Vulnerability Patterns
  • Insecure Skill Coding PracticesFinds exploitable flaws such as hardcoded secrets or command injection
  • 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
  • Remote Payload Retrieval and ExecutionFetches external code whose behavior can change after review
  • Embedded Malicious CodeShips malicious scripts inside the skill and executes them locally
Findings (3)

T09 · Insecure Skill Coding Practices

Error
Location
scripts/safe-update.sh:29
Finding

Environment Variables Are Interpolated Directly into Executable Python Source

Content
View full analysis

Vulnerability Details

File Location: scripts/safe-update.sh:29-35,48-78
Vulnerability Type: Python code injection through untrusted environment-derived configuration
Risk Level: High

Vulnerable Code

bash
CONFIG="${OPENCLAW_CONFIG:-$HOME/.openclaw/openclaw.json}"
NPM_DIR="${OPENCLAW_NPM_DIR:-/opt/homebrew/lib/node_modules/openclaw}"
APP_DIR="${OPENCLAW_APP_DIR:-/Applications/OpenClaw.app}"
PLIST="${OPENCLAW_PLIST:-$HOME/Library/LaunchAgents/ai.openclaw.gateway.plist}"
OC_BIN="${OPENCLAW_BIN:-/opt/homebrew/bin/openclaw}"
GATEWAY_PORT="${OPENCLAW_GATEWAY_PORT:-18789}"
SNAP_ROOT="${OPENCLAW_SNAP_ROOT:-/tmp/openclaw-rollback}"
TG_BOT="${OPENCLAW_TG_BOT:-default}"
bash
BOT_TOKEN=$(python3 -c "
import json, sys
try:
    cfg = json.load(open('$CONFIG'))
    print(cfg['channels']['telegram']['accounts']['$TG_BOT']['botToken'])
except Exception as e:
    sys.stderr.write(f'config error: {e}\n')
    sys.exit(1)
" 2>/dev/null)

# ---- Pull chat_id (env override > openclaw.json delivery target > fail) ----
CHAT_ID="${OPENCLAW_TG_CHAT_ID:-}"
if [ -z "$CHAT_ID" ]; then
    CHAT_ID=$(python3 -c "
import json, sys
try:
    cfg = json.load(open('$CONFIG'))
    # Try common locations: delivery.targets[], channels.telegram.accounts.default.defaultChatId, etc.
    targets = cfg.get('delivery', {}).get('targets', [])
    for t in targets:
        if t.get('channel') == 'telegram' and t.get('to'):
            print(t['to']); sys.exit(0)
    # Fallback: defaultChatId on the bot account
    chat = cfg.get('channels', {}).get('telegram', {}).get('accounts', {}).get('$TG_BOT', {}).get('defaultChatId')
    if chat:
        print(chat); sys.exit(0)
    sys.exit(1)
except Exception:
    sys.exit(1)
" 2>/dev/null)
fi

Technical Analysis

The supported OPENCLAW_CONFIG and OPENCLAW_TG_BOT environment variables are inserted directly into source code passed ...[truncated 1580 chars]

Remediation
View remediation

Remediation Suggestions

  • Never interpolate shell variables into Python source.

  • Pass configuration values as positional arguments:

    bash
    BOT_TOKEN=$(python3 - "$CONFIG" "$TG_BOT" <<'PY'
    import json
    import sys
    
    config_path = sys.argv[1]
    bot_name = sys.argv[2]
    
    with open(config_path, encoding="utf-8") as handle:
        cfg = json.load(handle)
    
    print(cfg["channels"]["telegram"]["accounts"][bot_name]["botToken"])
    PY
    )
    
  • Apply the same data-only argument handling to the chat-ID lookup.

  • Validate bot account names against a conservative allowlist if OpenClaw account identifiers have a restricted format.

  • Validate that the configuration path resolves to an expected user-owned OpenClaw configuration file and is not a symlink to an unrelated file.

  • Preserve error handling without printing credentials or sensitive configuration values to logs.

T09 · Insecure Skill Coding Practices

Error
Location
scripts/safe-update.sh:30
Finding

Unvalidated Path Overrides Reach Recursive Deletion and Snapshot-Pruning Operations

Content
View full analysis

Vulnerability Details

File Location: scripts/safe-update.sh:30-35,132-137,156-164
Vulnerability Type: Arbitrary user-writable directory deletion through unsafe path configuration
Risk Level: High

Vulnerable Code

bash
NPM_DIR="${OPENCLAW_NPM_DIR:-/opt/homebrew/lib/node_modules/openclaw}"
APP_DIR="${OPENCLAW_APP_DIR:-/Applications/OpenClaw.app}"
PLIST="${OPENCLAW_PLIST:-$HOME/Library/LaunchAgents/ai.openclaw.gateway.plist}"
OC_BIN="${OPENCLAW_BIN:-/opt/homebrew/bin/openclaw}"
GATEWAY_PORT="${OPENCLAW_GATEWAY_PORT:-18789}"
SNAP_ROOT="${OPENCLAW_SNAP_ROOT:-/tmp/openclaw-rollback}"
bash
if health_check; then
    NEW_VER=$("$OC_BIN" --version 2>/dev/null | head -1)
    echo "Health OK. New version: $NEW_VER"
    if [ "$OLD_VER" = "$NEW_VER" ]; then
        tg "✅ OpenClaw operational (no version change). Version: ${NEW_VER}. Nothing to update."
    else
        tg "✅ OpenClaw updated. ${OLD_VER} → ${NEW_VER}. Gateway operational."
    fi
    # Prune snapshots: keep last 2
    cd "$SNAP_ROOT" && ls -1t | tail -n +3 | xargs -I {} rm -rf "{}" 2>/dev/null
    echo "===== $(date) — UPDATE OK ====="
    exit 0
fi
bash
# ---- 4. ROLLBACK ----
echo "Health check FAILED. Rolling back..."
launchctl bootout "gui/$(id -u)" "$PLIST" 2>/dev/null
sleep 3

rm -rf "$NPM_DIR"
mv "$SNAP_DIR/openclaw-npm" "$NPM_DIR"
if [ -d "$SNAP_DIR/OpenClaw.app" ]; then
    rm -rf "$APP_DIR"
    mv "$SNAP_DIR/OpenClaw.app" "$APP_DIR"
fi
rmdir "$SNAP_DIR" 2>/dev/null

Technical Analysis

The Skill intentionally needs to replace the OpenClaw package and application during rollback. However, the deletion targets and snapshot root can be changed through environment variables without canonicalization or validation.

The script does not enforce that NPM_DIR is the OpenClaw npm installation, that APP_DIR is the OpenClaw application bundle, or that SNAP_ROOT is a ...[truncated 1738 chars]

Remediation
View remediation

Remediation Suggestions

  • Canonicalize every destructive target before use, using a mechanism that resolves .. components and symbolic links.
  • Enforce exact expected paths or strict allowed roots for the npm package, application bundle, and snapshot directory.
  • Reject empty paths, /, $HOME, /Users, /Applications, /opt/homebrew, and other broad parent directories.
  • Confirm that the final package directory basename is openclaw and that the application target is specifically OpenClaw.app.
  • Refuse destructive operations when a target or relevant parent is a symbolic link.
  • Require explicit interactive confirmation or a separate opt-in flag for nonstandard installation paths.
  • Replace the ls | xargs | rm pruning pipeline with a controlled loop that enumerates only validated snapshot directories matching the timestamp format.
  • Before rollback, verify that the snapshot contains expected OpenClaw markers and that source and destination ownership match the invoking user.
  • Consider preserving the failed installation by atomically renaming it rather than deleting it before a successful restore has been confirmed.

T09 · Insecure Skill Coding Practices

Warning
Location
scripts/safe-update.sh:38
Finding

Predictable Files in Shared Temporary Storage Permit Symlink-Based File Overwrite

Content
View full analysis

Vulnerability Details

File Location: scripts/safe-update.sh:38-42,142-145
Vulnerability Type: Unsafe temporary-file creation and symlink following
Risk Level: Medium

Vulnerable Code

bash
TS=$(date +%Y%m%d-%H%M%S)
LOG=/tmp/openclaw-update-${TS}.log
SNAP_DIR="${SNAP_ROOT}/${TS}"

exec >>"$LOG" 2>&1
bash
# ---- 2. Update ----
echo "Running openclaw update..."
"$OC_BIN" update --json > "/tmp/openclaw-update-${TS}.update.json" 2>&1
UPDATE_RC=$?
echo "openclaw update exit code: $UPDATE_RC"
cat "/tmp/openclaw-update-${TS}.update.json"

Technical Analysis

Both output filenames are derived solely from a timestamp with one-second resolution and are created directly in the shared /tmp directory. The files are opened using normal shell redirection, without exclusive creation, ownership verification, or symbolic-link checks.

On systems where another local user can create entries in /tmp, an attacker can predict or pre-create candidate names as symbolic links. When the victim starts the update during a matching second, shell redirection follows the symbolic link. The log uses append mode, while the update output uses truncation mode.

The snapshot directory also uses the predictable timestamp, although the most direct confirmed overwrite risk is associated with the two redirected files.

Attack Path

  1. A local attacker predicts likely future timestamps or creates symbolic links for a range of timestamp-based log and update-output filenames.
  2. A link such as /tmp/openclaw-update-<timestamp>.update.json points to a file writable by the victim but not normally writable by the attacker.
  3. The victim launches the Skill during one of the prepared timestamps.
  4. Shell redirection follows the attacker's symbolic link.
  5. The update-output redirection truncates and overwrites the target; the log redirection appends script output to its target.
  6. The attacke ...[truncated 474 chars]
Remediation
View remediation

Remediation Suggestions

  • Set a restrictive file-creation mask at startup:

    bash
    umask 077
    
  • Create a private per-run directory atomically:

    bash
    RUN_DIR=$(mktemp -d "${TMPDIR:-/tmp}/openclaw-update.XXXXXXXX") || exit 1
    LOG="$RUN_DIR/update.log"
    UPDATE_JSON="$RUN_DIR/update.json"
    
  • Store all per-run files beneath the private directory rather than directly in shared /tmp.

  • Verify that the private directory is owned by the invoking user and is not a symbolic link.

  • Use exclusive file creation where practical and abort if an output file already exists.

  • Add cleanup traps for temporary output that does not need to survive the update, while deliberately retaining required diagnostic logs with restrictive permissions.

  • Apply equivalent atomic-creation and ownership validation to the snapshot root and per-run snapshot directory.

Vulnerability Patterns
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
  • Excessive AgencyUnrestricted Tool Access, Autonomous Decision Making, Scope Creep
  • Tool MisuseTool Parameter Abuse, Chaining Abuse, Unsafe Defaults
  • Rogue AgentSelf-Modification, Session Persistence
Findings (31)

Tool Parameter Abuse

High
Category
Tool Misuse
Confidence
93% confidence
Finding

The prompt instructs deletion of installation directories using broad path-based actions inside an agentic workflow. If the path is wrong, symlinked, stale, or attacker-influenced, this could destroy unrelated files or leave the system in a worse state; combined with detached recovery behavior, the user may have little chance to intervene.

Content

Scanner excerpt · references/rescue-prompt.md (reported line 29)May include surrounding context.

md
3. If a snapshot is available in /tmp/openclaw-rollback/ and the issue is the new version:
   - launchctl bootout gui/$(id -u) ~/Library/LaunchAgents/ai.openclaw.gateway.plist
   - Delete /opt/homebrew/lib/node_modules/openclaw and /Applications/OpenClaw.app
   - Restore from /tmp/openclaw-rollback/<most-recent-timestamp>/openclaw-npm
     and /OpenClaw.app to their original paths
   - launchctl bootstrap gui/$(id -u) ~/Library/LaunchAgents/ai.openclaw.gateway.plist

Credential Access

High
Category
Privilege Escalation
Confidence
70% confidence
Finding

Code accesses credential files (SSH keys, AWS credentials, etc.). This could indicate credential theft attempts.

Content

Scanner excerpt · references/rescue-prompt.md (reported line 52)May include surrounding context.

  • Gateway logs: ~/.openclaw/logs/ and /tmp/openclaw-update-*.log
  • Binary: /opt/homebrew/bin/openclaw (symlink to npm package)

DO NOT touch: credential files (~/.ssh, keychain), tokens in config unless required, anything outside the OpenClaw stack. Ask before any destructive action you're unsure about.

Start with step 1 and report.

text

Chaining Abuse

High
Category
Tool Misuse
Confidence
85% confidence
Finding

The cleanup pipeline deletes paths under a configurable snapshot root using 'cd "$SNAP_ROOT" && ls -1t | tail -n +3 | xargs ... rm -rf'. If SNAP_ROOT is mis-set, attacker-controlled, or contains adversarial filenames such as symlinks or names beginning with option-like characters, this can cause deletion of unintended data; the use of xargs with parsed ls output makes the operation fragile and unsafe.

Content

Scanner excerpt · scripts/safe-update.sh (reported line 158)May include surrounding context.

sh
tg "✅ OpenClaw updated. ${OLD_VER} → ${NEW_VER}. Gateway operational."
    fi
    # Prune snapshots: keep last 2
    cd "$SNAP_ROOT" && ls -1t | tail -n +3 | xargs -I {} rm -rf "{}" 2>/dev/null
    echo "===== $(date) — UPDATE OK ====="
    exit 0
fi

Undeclared Tool Scope

Medium
Category
MCP Least Privilege
Confidence
95% confidence
Finding

The skill instructs the agent to launch a shell script and perform package updates, rollback, and service control, but it declares no explicit tool scope such as allowed shell access. Missing permission declarations weakens least-privilege controls and can cause the skill to be invoked with broader-than-expected execution capability.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
93% confidence
Finding

The skill description advertises Telegram notifications but does not prominently warn that status, version, and failure information will be transmitted to an external messaging service. This creates a privacy and data-handling risk because operational details about the host and software lifecycle are sent off-device without explicit user acknowledgment in the trigger/usage flow.

Content

No source excerpt is available for this finding.

Vague Triggers

Medium
Category
Not specified by scanner
Confidence
93% confidence
Finding

The trigger criteria are broad and multilingual, covering generic update phrasing without strong confirmation gates. This increases the chance the skill will run in response to ambiguous user intent, leading to unintended background execution of an updater that restarts the gateway and modifies installed software.

Content

No source excerpt is available for this finding.

Session Persistence

Medium
Category
Rogue Agent
Confidence
91% confidence
Finding

Using 'disown' further detaches the process from the controlling shell, making it harder to monitor, interrupt, or attribute once started. In the context of an update workflow that restarts software and manipulates application files, this creates a meaningful persistence and accountability risk.

Content

Scanner excerpt · SKILL.md (reported line 21)May include surrounding context.

Launch the script detached so it survives the gateway restart:

bash
nohup "<path-to-skill>/scripts/safe-update.sh" </dev/null >/dev/null 2>&1 & disown

Then tell the user: "Update launched in background. You'll get Telegram updates at each step." Do not wait for the script to finish — the gateway restart will likely terminate the current agent session. The user is the source of truth via Telegram.

Session Persistence

Medium
Category
Rogue Agent
Confidence
91% confidence
Finding

Using 'disown' further detaches the process from the controlling shell, making it harder to monitor, interrupt, or attribute once started. In the context of an update workflow that restarts software and manipulates application files, this creates a meaningful persistence and accountability risk.

Content

Scanner excerpt · SKILL.md (reported line 21)May include surrounding context.

Launch the script detached so it survives the gateway restart:

bash
nohup "<path-to-skill>/scripts/safe-update.sh" </dev/null >/dev/null 2>&1 & disown

Then tell the user: "Update launched in background. You'll get Telegram updates at each step." Do not wait for the script to finish — the gateway restart will likely terminate the current agent session. The user is the source of truth via Telegram.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
94% confidence
Finding

The prompt directs destructive actions including unloading the LaunchAgent, deleting the installed npm package and app bundle, and reinstalling software, but does not require an explicit confirmation immediately before deletion/reinstall. In an LLM-driven recovery flow, this increases the chance of accidental data loss, service disruption, or restoring from an incorrect snapshot path.

Content

No source excerpt is available for this finding.

Context-Inappropriate Capability

Medium
Category
Not specified by scanner
Confidence
89% confidence
Finding

The rescue prompt explicitly instructs the agent to read Telegram bot credentials from the user's config and send an external message. That extends the rescue flow beyond local recovery into credential use and outbound communication, which creates unnecessary secret exposure and data exfiltration risk if the prompt is misused or the environment is compromised.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
91% confidence
Finding

The prompt instructs the agent to access and use a Telegram bot token without a privacy or handling warning, despite the token being a secret that enables external messaging. This can normalize unnecessary credential exposure to the agent and increases the blast radius if logs, prompts, or tool traces capture the token.

Content

No source excerpt is available for this finding.

Session Persistence

Medium
Category
Rogue Agent
Confidence
65% confidence
Finding

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.

Content

Scanner excerpt · scripts/safe-update.sh (reported line 5)May include surrounding context.

sh
# dont-be-scary — Safe OpenClaw update with snapshot + rollback + Telegram report
#
# Launch detached so the script survives gateway restart (which kills the agent):
#   nohup "$OPENCLAW_WORKSPACE_DIR/skills/dont-be-scary/scripts/safe-update.sh" </dev/null >/dev/null 2>&1 & disown
#
# Flow:
#   1. Snapshot npm package + .app bundle to /tmp/openclaw-rollback/<ts>/

Session Persistence

Medium
Category
Rogue Agent
Confidence
65% confidence
Finding

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.

Content

Scanner excerpt · scripts/safe-update.sh (reported line 5)May include surrounding context.

sh
# dont-be-scary — Safe OpenClaw update with snapshot + rollback + Telegram report
#
# Launch detached so the script survives gateway restart (which kills the agent):
#   nohup "$OPENCLAW_WORKSPACE_DIR/skills/dont-be-scary/scripts/safe-update.sh" </dev/null >/dev/null 2>&1 & disown
#
# Flow:
#   1. Snapshot npm package + .app bundle to /tmp/openclaw-rollback/<ts>/

Session Persistence

Medium
Category
Rogue Agent
Confidence
75% confidence
Finding

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.

Content

Scanner excerpt · SKILL.md (reported line 50)May include surrounding context.

md
#   OPENCLAW_NPM_DIR      — Path to npm install (default: /opt/homebrew/lib/node_modules/openclaw)
#   OPENCLAW_APP_DIR      — Path to .app bundle (default: /Applications/OpenClaw.app)
#   OPENCLAW_GATEWAY_PORT — Gateway port for health check (default: 18789)
#   OPENCLAW_PLIST        — LaunchAgent plist (default: ~/Library/LaunchAgents/ai.openclaw.gateway.plist)
#   OPENCLAW_BIN          — openclaw binary path (default: /opt/homebrew/bin/openclaw)
#   OPENCLAW_SNAP_ROOT    — Snapshot root dir (default: /tmp/openclaw-rollback)

Session Persistence

Medium
Category
Rogue Agent
Confidence
75% confidence
Finding

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.

Content

Scanner excerpt · scripts/safe-update.sh (reported line 22)May include surrounding context.

sh
#   OPENCLAW_NPM_DIR      — Path to npm install (default: /opt/homebrew/lib/node_modules/openclaw)
#   OPENCLAW_APP_DIR      — Path to .app bundle (default: /Applications/OpenClaw.app)
#   OPENCLAW_GATEWAY_PORT — Gateway port for health check (default: 18789)
#   OPENCLAW_PLIST        — LaunchAgent plist (default: ~/Library/LaunchAgents/ai.openclaw.gateway.plist)
#   OPENCLAW_BIN          — openclaw binary path (default: /opt/homebrew/bin/openclaw)
#   OPENCLAW_SNAP_ROOT    — Snapshot root dir (default: /tmp/openclaw-rollback)

Session Persistence

Medium
Category
Rogue Agent
Confidence
75% confidence
Finding

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.

Content

Scanner excerpt · scripts/safe-update.sh (reported line 31)May include surrounding context.

sh
#   OPENCLAW_NPM_DIR      — Path to npm install (default: /opt/homebrew/lib/node_modules/openclaw)
#   OPENCLAW_APP_DIR      — Path to .app bundle (default: /Applications/OpenClaw.app)
#   OPENCLAW_GATEWAY_PORT — Gateway port for health check (default: 18789)
#   OPENCLAW_PLIST        — LaunchAgent plist (default: ~/Library/LaunchAgents/ai.openclaw.gateway.plist)
#   OPENCLAW_BIN          — openclaw binary path (default: /opt/homebrew/bin/openclaw)
#   OPENCLAW_SNAP_ROOT    — Snapshot root dir (default: /tmp/openclaw-rollback)

Session Persistence

Medium
Category
Rogue Agent
Confidence
75% confidence
Finding

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.

Content

Scanner excerpt · scripts/safe-update.sh (reported line 103)May include surrounding context.

sh
#   OPENCLAW_NPM_DIR      — Path to npm install (default: /opt/homebrew/lib/node_modules/openclaw)
#   OPENCLAW_APP_DIR      — Path to .app bundle (default: /Applications/OpenClaw.app)
#   OPENCLAW_GATEWAY_PORT — Gateway port for health check (default: 18789)
#   OPENCLAW_PLIST        — LaunchAgent plist (default: ~/Library/LaunchAgents/ai.openclaw.gateway.plist)
#   OPENCLAW_BIN          — openclaw binary path (default: /opt/homebrew/bin/openclaw)
#   OPENCLAW_SNAP_ROOT    — Snapshot root dir (default: /tmp/openclaw-rollback)

Session Persistence

Medium
Category
Rogue Agent
Confidence
75% confidence
Finding

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.

Content

Scanner excerpt · scripts/safe-update.sh (reported line 104)May include surrounding context.

sh
#   OPENCLAW_NPM_DIR      — Path to npm install (default: /opt/homebrew/lib/node_modules/openclaw)
#   OPENCLAW_APP_DIR      — Path to .app bundle (default: /Applications/OpenClaw.app)
#   OPENCLAW_GATEWAY_PORT — Gateway port for health check (default: 18789)
#   OPENCLAW_PLIST        — LaunchAgent plist (default: ~/Library/LaunchAgents/ai.openclaw.gateway.plist)
#   OPENCLAW_BIN          — openclaw binary path (default: /opt/homebrew/bin/openclaw)
#   OPENCLAW_SNAP_ROOT    — Snapshot root dir (default: /tmp/openclaw-rollback)

Session Persistence

Medium
Category
Rogue Agent
Confidence
75% confidence
Finding

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.

Content

Scanner excerpt · scripts/safe-update.sh (reported line 106)May include surrounding context.

sh
#   OPENCLAW_NPM_DIR      — Path to npm install (default: /opt/homebrew/lib/node_modules/openclaw)
#   OPENCLAW_APP_DIR      — Path to .app bundle (default: /Applications/OpenClaw.app)
#   OPENCLAW_GATEWAY_PORT — Gateway port for health check (default: 18789)
#   OPENCLAW_PLIST        — LaunchAgent plist (default: ~/Library/LaunchAgents/ai.openclaw.gateway.plist)
#   OPENCLAW_BIN          — openclaw binary path (default: /opt/homebrew/bin/openclaw)
#   OPENCLAW_SNAP_ROOT    — Snapshot root dir (default: /tmp/openclaw-rollback)

Session Persistence

Medium
Category
Rogue Agent
Confidence
75% confidence
Finding

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.

Content

Scanner excerpt · scripts/safe-update.sh (reported line 108)May include surrounding context.

sh
#   OPENCLAW_NPM_DIR      — Path to npm install (default: /opt/homebrew/lib/node_modules/openclaw)
#   OPENCLAW_APP_DIR      — Path to .app bundle (default: /Applications/OpenClaw.app)
#   OPENCLAW_GATEWAY_PORT — Gateway port for health check (default: 18789)
#   OPENCLAW_PLIST        — LaunchAgent plist (default: ~/Library/LaunchAgents/ai.openclaw.gateway.plist)
#   OPENCLAW_BIN          — openclaw binary path (default: /opt/homebrew/bin/openclaw)
#   OPENCLAW_SNAP_ROOT    — Snapshot root dir (default: /tmp/openclaw-rollback)

Session Persistence

Medium
Category
Rogue Agent
Confidence
75% confidence
Finding

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.

Content

Scanner excerpt · scripts/safe-update.sh (reported line 165)May include surrounding context.

sh
#   OPENCLAW_NPM_DIR      — Path to npm install (default: /opt/homebrew/lib/node_modules/openclaw)
#   OPENCLAW_APP_DIR      — Path to .app bundle (default: /Applications/OpenClaw.app)
#   OPENCLAW_GATEWAY_PORT — Gateway port for health check (default: 18789)
#   OPENCLAW_PLIST        — LaunchAgent plist (default: ~/Library/LaunchAgents/ai.openclaw.gateway.plist)
#   OPENCLAW_BIN          — openclaw binary path (default: /opt/homebrew/bin/openclaw)
#   OPENCLAW_SNAP_ROOT    — Snapshot root dir (default: /tmp/openclaw-rollback)

Session Persistence

Medium
Category
Rogue Agent
Confidence
75% confidence
Finding

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.

Content

Scanner excerpt · SKILL.md (reported line 50)May include surrounding context.

md
#   OPENCLAW_NPM_DIR      — Path to npm install (default: /opt/homebrew/lib/node_modules/openclaw)
#   OPENCLAW_APP_DIR      — Path to .app bundle (default: /Applications/OpenClaw.app)
#   OPENCLAW_GATEWAY_PORT — Gateway port for health check (default: 18789)
#   OPENCLAW_PLIST        — LaunchAgent plist (default: ~/Library/LaunchAgents/ai.openclaw.gateway.plist)
#   OPENCLAW_BIN          — openclaw binary path (default: /opt/homebrew/bin/openclaw)
#   OPENCLAW_SNAP_ROOT    — Snapshot root dir (default: /tmp/openclaw-rollback)

Session Persistence

Medium
Category
Rogue Agent
Confidence
75% confidence
Finding

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.

Content

Scanner excerpt · references/rescue-prompt.md (reported line 28)May include surrounding context.

md
#   OPENCLAW_NPM_DIR      — Path to npm install (default: /opt/homebrew/lib/node_modules/openclaw)
#   OPENCLAW_APP_DIR      — Path to .app bundle (default: /Applications/OpenClaw.app)
#   OPENCLAW_GATEWAY_PORT — Gateway port for health check (default: 18789)
#   OPENCLAW_PLIST        — LaunchAgent plist (default: ~/Library/LaunchAgents/ai.openclaw.gateway.plist)
#   OPENCLAW_BIN          — openclaw binary path (default: /opt/homebrew/bin/openclaw)
#   OPENCLAW_SNAP_ROOT    — Snapshot root dir (default: /tmp/openclaw-rollback)

Session Persistence

Medium
Category
Rogue Agent
Confidence
75% confidence
Finding

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.

Content

Scanner excerpt · references/rescue-prompt.md (reported line 32)May include surrounding context.

md
#   OPENCLAW_NPM_DIR      — Path to npm install (default: /opt/homebrew/lib/node_modules/openclaw)
#   OPENCLAW_APP_DIR      — Path to .app bundle (default: /Applications/OpenClaw.app)
#   OPENCLAW_GATEWAY_PORT — Gateway port for health check (default: 18789)
#   OPENCLAW_PLIST        — LaunchAgent plist (default: ~/Library/LaunchAgents/ai.openclaw.gateway.plist)
#   OPENCLAW_BIN          — openclaw binary path (default: /opt/homebrew/bin/openclaw)
#   OPENCLAW_SNAP_ROOT    — Snapshot root dir (default: /tmp/openclaw-rollback)

Session Persistence

Medium
Category
Rogue Agent
Confidence
75% confidence
Finding

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.

Content

Scanner excerpt · references/rescue-prompt.md (reported line 48)May include surrounding context.

md
#   OPENCLAW_NPM_DIR      — Path to npm install (default: /opt/homebrew/lib/node_modules/openclaw)
#   OPENCLAW_APP_DIR      — Path to .app bundle (default: /Applications/OpenClaw.app)
#   OPENCLAW_GATEWAY_PORT — Gateway port for health check (default: 18789)
#   OPENCLAW_PLIST        — LaunchAgent plist (default: ~/Library/LaunchAgents/ai.openclaw.gateway.plist)
#   OPENCLAW_BIN          — openclaw binary path (default: /opt/homebrew/bin/openclaw)
#   OPENCLAW_SNAP_ROOT    — Snapshot root dir (default: /tmp/openclaw-rollback)

Static analysis

No suspicious patterns detected.