Back to skill

Security audit

Cyber Security Engineer

Security checks for vulnerabilities and agentic risk

Overview

This skill has a coherent security-governance purpose, but its sudo interception design creates serious review concerns around persistent PATH changes, caller-controlled guard paths, and approval bypasses.

Install only after review. The port, egress, and compliance-reporting pieces are aligned with the stated purpose, but do not enable the sudo runtime hook until the shim stops trusting caller-controlled paths, policy files are mandatory and fail closed, approval-state mutation is protected, and the LaunchAgent PATH change has explicit confirmation and rollback.

Vulnerability Patterns
  • Unauthorized Access and Privilege EscalationObtains permissions beyond the task's legitimate needs
  • System PersistenceInstalls backdoors, hooks, services, or scheduled tasks that survive the run
  • Tool Hijacking and SpoofingModifies or replaces tools so legitimate-looking calls execute attacker logic
  • 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
Findings (5)

T05 · Unauthorized Access and Privilege Escalation

Error
Location
scripts/root_session_guard.py:278
Finding

Privileged Approval State Can Be Forged Through the Public State Helper

Content
View full analysis
argparse.Namespace: parser = argparse.ArgumentParser(description="OpenClaw root/elevated session guard") parser.add_argument( "--state-file", default=str(STATE_PATH), help="Path to session state JSON file", ) parser.add_argument( "--timeout-minutes", type=int, default=DEFAULT_TIMEOUT_MINUTES, help="Idle timeout for elevated mode", ) sub = parser.add_subparsers(dest="command", required=True) sub.add_parser("preflight", help="Check timeout and approval requirement") authz = sub.add_parser( "authorize", help="Authorize a specific argv against the current elevated allowlist", ) authz.add_argument( "--argv-json", required=True, help='Command argv as JSON array, e.g. ["launchctl","print","..."]', ) authz.add_argument("--session-id", help="Task session id to scope approvals") approve = sub.add_parser( "approve", help="Approve a specific argv for elevated execution (adds to allowlist)", ) approve.add_argument("--reason", required=True, help="Approval reason") approve.add_argument( "--argv-json", required=True, help='Command argv as JSON array, e.g. ["launchctl","print","..."]', ) approve.add_argument("--session-id", help="Task session id to scope approvals") sub.add_parser("elevated-used", help="Mark elevated mode as used now") sub.add_parser("normal-used", help="Mark normal mode activity now") sub.add_parser("drop", help="Drop to normal mode") sub.add_parser("status", help="Print current state and timeout info") return parser.parse_args() def main() -> int: args = parse_args() state_file = Path( ...[truncated 3098 chars]
Remediation
View remediation

T07 · Tool Hijacking and Spoofing

Error
Location
scripts/install-openclaw-runtime-hook.sh:102
Finding

Sudo Shim Executes Caller-Controlled Python and Guard Implementations

Content
View full analysis
"${WRAPPER}" <&2 exit 2 fi REASON="\${OPENCLAW_PRIV_REASON:-OpenClaw requested privileged execution}" # Sanitize reason: strip shell metacharacters to prevent injection REASON="\$(printf '%s' "\${REASON}" | tr -d '\`\$\\!;|&<>(){}' | head -c 200)" export OPENCLAW_REAL_SUDO="\${REAL_SUDO_OVERRIDE}" export OPENCLAW_PYTHON3="\${PYTHON3_OVERRIDE}" exec "\${PYTHON3_OVERRIDE}" "\${SKILL_DIR}/scripts/guarded_privileged_exec.py" \ --reason "\${REASON}" \ --use-sudo \ -- "\$@" EOF ``` ### Technical Analysis The generated sudo shim accepts `OPENCLAW_PYTHON3`, `OPENCLAW_CYBER_SKILL_DIR`, and `OPENCLAW_REAL_SUDO` from its caller. It then executes the selected Python binary and guard script before performing canonical-path, ownership, or permission validation. Consequently, the component intended to enforce approval and policy can be replaced at invocation time: - `OPENCLAW_PYTHON3` can reference an attacker-controlled executable. - `OPENCLAW_CYBER_SKILL_DIR` can reference an attacker-controlled directory containing a substitute `guarded_privileged_exec ...[truncated 1483 chars]
Remediation
View remediation

T06 · System Persistence

Error
Location
scripts/install-openclaw-runtime-hook.sh:95
Finding

Non-Interactive Installation Can Persistently Intercept Gateway Sudo Calls Without Confirmation

Content
View full analysis
"${WRAPPER}" </dev/null 2>&1; then if [[ -t 0 && "${OPENCLAW_SKIP_PLIST_CONFIRM:-0}" != "1" ]]; then printf '[cyber-security-engineer] This will modify the gateway LaunchAgent PATH in:\n %s\nProceed? [y/N]: ' "${PLIST}" read -r confirm if [[ "${confirm}" != "y" && "${confirm}" != "Y" ]]; then log "Skipped LaunchAgent PATH modification. You can add ${BIN_DIR} to PATH manually." log "Restart the OpenClaw gateway to apply:" log " openclaw gateway restart" exit 0 fi fi # Ensure EnvironmentVariables exists and prepend ~/.openclaw/bin to PATH. /usr/libexec/PlistBuddy -c "Add :EnvironmentVariables dict" "${PLIST}" 2>/dev/null || true EXISTING_PATH="$(/usr/libexec/PlistBuddy -c "Print :EnvironmentVariables:PATH" "${PLIST}" 2>/dev/null || true)" if [[ -z "${EXISTING_PATH}" ]]; then NEW_PATH="${BIN_DIR}:/usr/bin:/bin:/usr/sbin:/sbin" /usr/libexec/PlistBuddy -c "Add :EnvironmentVariables:PATH string ${NEW_PATH}" "${PLIST}" 2>/dev/null || \ /usr/libexec/PlistBuddy -c "Set :EnvironmentVariables:PATH ${NEW_PATH}" "${PLIST}" 2>/dev/null || true log "Updated gateway LaunchAgent PATH to include ${BIN_DIR}" else case ":${EXISTING_PATH}:" in *":${BIN_DIR}:"*) ;; *) NEW_PATH="${BIN_DIR}:${EXISTING_PATH}" /usr/libexec/Plist ...[truncated 2114 chars]
Remediation
View remediation

T09 · Insecure Skill Coding Practices

Error
Location
scripts/command_policy.py:12
Finding

Privileged Command and Prompt Policies Fail Open When Missing or Invalid

Content
View full analysis
Dict[str, object]: if not POLICY_PATH.exists(): return {} try: raw = json.loads(POLICY_PATH.read_text(encoding="utf-8")) return raw if isinstance(raw, dict) else {} except Exception: return {} def evaluate_command(argv: List[str]) -> Dict[str, object]: """ Evaluate the command argv against an optional allow/deny policy. Behavior: - If policy file is missing: allow. - If deny_exact or deny regex matches: block. - If allow_exact is non-empty: require exact match. - Else if allow regex list is non-empty: require allow match. """ cmd_str = shlex.join(argv) if argv else "" pol = _load_policy() allow = _compile_patterns(pol.get("allow")) deny = _compile_patterns(pol.get("deny")) allow_exact = _load_exact_rules(pol.get("allow_exact")) deny_exact = _load_exact_rules(pol.get("deny_exact")) if deny_exact and _match_exact(deny_exact, argv): return {"allowed": False, "reason": "deny_exact_match", "pattern": "exact"} deny_match = _match_any(deny, cmd_str) if deny_match: return {"allowed": False, "reason": "deny_match", "pattern": deny_match} if allow_exact: if not _match_exact(allow_exact, argv): return {"allowed": False, "reason": "not_in_allow_exact", "pattern": None} return {"allowed": True, "reason": "allow_exact_match", "pattern": "exact"} if allow: allow_match = _match_any(allow, cmd_str) if not allow_match: return {"allowed": False, "reason": "not_in_allowlist", "pattern": None} return {"allowed": True, "reason": "allow_match", "pattern": allow_match} return {"allowed": True, "reason": "no_policy_or_allow_empty", "pattern": N ...[truncated 2601 chars]
Remediation
View remediation

T07 · Tool Hijacking and Spoofing

Warning
Location
scripts/live_assessment.py:149
Finding

Compliance Check Can Be Spoofed by Any Executable at the Expected Sudo-Shim Path

Content
View full analysis
bool: hook = Path.home() / ".openclaw" / "bin" / "sudo" return hook.exists() and os.access(hook, os.X_OK) ``` ```python approval_enforced = runtime_hook_installed() set_check( checks_by_id, "privilege_approval_required", "compliant" if approval_enforced else "violation", "high", "Runtime privileged execution hook is installed." if approval_enforced else "Runtime privileged execution hook not detected.", "Checked for ~/.openclaw/bin/sudo wrapper installed by cyber-security-engineer.", "Approval-first execution is not enforced for privileged actions.", "Run cyber-security-engineer/scripts/install-openclaw-runtime-hook.sh and restart OpenClaw gateway.", "Security Engineering", due_in(14), ) ``` ### Technical Analysis The assessment treats the approval control as compliant if an executable filesystem entry exists at `~/.openclaw/bin/sudo`. It does not verify: - File ownership or permissions. - Whether the entry is a regular file or symlink. - The shim's content or checksum. - The canonical guard and interpreter paths. - Whether the gateway PATH actually resolves `sudo` to this file. - Whether the wrapper's policy and approval checks are functional. As a result, a malicious, unrelated, stale, or broken executable can satisfy the compliance test. This creates a false assurance condition in generated reports and dashboards. ### Attack Path 1. An attacker or misconfigured installer places any executable at `~/.openclaw/bin/sudo`. 2. The gateway may continue using the system sudo binary, or the replacement may omit all approval controls. 3. `live_assessment.py` runs and calls `runtime_hook_installed()`. 4. The existence and executable checks return tr ...[truncated 595 chars]
Remediation
View remediation
Vulnerability Patterns
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
  • System Prompt LeakageDirect Leakage, Indirect Extraction, Tool-Based Exfiltration
  • Rogue AgentSelf-Modification, Session Persistence
  • MCP Least PrivilegeUnderdeclared Capability, Wildcard Permission, Missing Permission Declaration
Findings (92)

Tp4

High
Category
MCP Tool Poisoning
Confidence
97% confidence
Finding

If the skill can dispatch notifications to an external command and maintain state beyond what its description emphasizes, that expands its effective attack surface. In a security-engineering skill, undocumented subprocess execution is risky because users may trust it with sensitive host context and privileged workflow decisions.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
97% confidence
Finding

If the skill can dispatch notifications to an external command and maintain state beyond what its description emphasizes, that expands its effective attack surface. In a security-engineering skill, undocumented subprocess execution is risky because users may trust it with sensitive host context and privileged workflow decisions.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
98% confidence
Finding

If the skill can dispatch notifications to an external command and maintain state beyond what its description emphasizes, that expands its effective attack surface. In a security-engineering skill, undocumented subprocess execution is risky because users may trust it with sensitive host context and privileged workflow decisions.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
95% confidence
Finding

If the skill can dispatch notifications to an external command and maintain state beyond what its description emphasizes, that expands its effective attack surface. In a security-engineering skill, undocumented subprocess execution is risky because users may trust it with sensitive host context and privileged workflow decisions.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
96% confidence
Finding

If the skill can dispatch notifications to an external command and maintain state beyond what its description emphasizes, that expands its effective attack surface. In a security-engineering skill, undocumented subprocess execution is risky because users may trust it with sensitive host context and privileged workflow decisions.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
89% confidence
Finding

If the skill can dispatch notifications to an external command and maintain state beyond what its description emphasizes, that expands its effective attack surface. In a security-engineering skill, undocumented subprocess execution is risky because users may trust it with sensitive host context and privileged workflow decisions.

Content

No source excerpt is available for this finding.

Direct Prompt Extraction

High
Category
System Prompt Leakage
Confidence
85% confidence
Finding

Skill contains instructions that could directly expose system prompts, internal rules, or hidden instructions to users or external parties.

Content

Scanner excerpt · scripts/generate_approved_ports.py (reported line 97)May include surrounding context.

python
rules.append(rule)

    rules.sort(key=lambda r: (int(r.get("port", 0)), str(r.get("protocol", "")), str(r.get("command", ""))))
    return rules, len(seen)


def main() -> int:

Env Variable Harvesting

High
Category
Data Exfiltration
Confidence
70% confidence
Finding

Code enumerates, copies, or searches environment variables for secrets. Bulk environment access can collect credentials unrelated to the skill's stated purpose.

Content

Scanner excerpt · scripts/notify_on_violation.py (reported line 203)May include surrounding context.

python
return 0
        _UNSAFE_ENV_VARS = {"LD_PRELOAD", "LD_LIBRARY_PATH", "DYLD_INSERT_LIBRARIES",
                           "PYTHONPATH", "RUBYLIB", "NODE_PATH", "IFS", "CDPATH"}
        safe_env = {k: v for k, v in os.environ.items() if k not in _UNSAFE_ENV_VARS}
        p = subprocess.run(argv, check=False, input=message, text=True, timeout=5, env=safe_env)
        return int(p.returncode or 0)
    except Exception:

Undeclared Tool Scope

Medium
Category
MCP Least Privilege
Confidence
90% confidence
Finding

The skill declares broad capabilities and references shell execution, environment variables, file reads, and file writes, but does not define an explicit tool/permission scope. In a security-sensitive skill that can influence privileged workflows and install a sudo shim, missing scope boundaries increases the chance of unintended or overbroad execution by the agent runtime.

Content

No source excerpt is available for this finding.

Sudo/Root Execution

Medium
Category
Privilege Escalation
Confidence
82% confidence
Finding

The skill exposes environment-variable overrides controlling the real sudo path, python path, skill directory, approval token behavior, and notifier execution. In a security-sensitive privileged-execution workflow, env-driven control of executable paths can be abused for command hijacking or policy bypass if not rigidly validated by the implementation.

Content

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

md
- `OPENCLAW_UNTRUSTED_SOURCE` — set to `1` to flag the current content source as untrusted
- `OPENCLAW_VIOLATION_NOTIFY_CMD` — absolute path to a notifier binary (must also be allowlisted)
- `OPENCLAW_VIOLATION_NOTIFY_ALLOWLIST` — JSON array of allowed argv arrays, or comma-separated absolute paths
- `OPENCLAW_REAL_SUDO` — override path to the real sudo binary (used by the runtime hook shim)
- `OPENCLAW_PYTHON3` — override path to python3 (used by the runtime hook shim)
- `OPENCLAW_CYBER_SKILL_DIR` — override path to the skill directory (used by the runtime hook shim)
- `OPENCLAW_ALLOW_NONINTERACTIVE_SUDO` — set to `1` to allow non-interactive sudo through the shim (default: blocked)

Sudo/Root Execution

Medium
Category
Privilege Escalation
Confidence
78% confidence
Finding

The documented OPENCLAW_ALLOW_NONINTERACTIVE_SUDO=1 switch weakens the safety model by allowing automated privileged execution through the shim. Combined with other env-based overrides, this can reduce the effectiveness of explicit user approval and enable unattended privilege use if misconfigured or attacker-controlled.

Content

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

md
- `OPENCLAW_REAL_SUDO` — override path to the real sudo binary (used by the runtime hook shim)
- `OPENCLAW_PYTHON3` — override path to python3 (used by the runtime hook shim)
- `OPENCLAW_CYBER_SKILL_DIR` — override path to the skill directory (used by the runtime hook shim)
- `OPENCLAW_ALLOW_NONINTERACTIVE_SUDO` — set to `1` to allow non-interactive sudo through the shim (default: blocked)
- `OPENCLAW_PRIV_REASON` — human-readable reason passed to the guarded execution wrapper
- `OPENCLAW_VIOLATION_NOTIFY_STATE` — override path to the notification state file
- `OPENCLAW_SKIP_PLIST_CONFIRM` — set to `1` to skip the interactive confirmation before modifying the macOS LaunchAgent plist

Session Persistence

Medium
Category
Rogue Agent
Confidence
75% confidence
Finding

This finding is the same persistence concern at the same line: a flag that disables confirmation before changing a LaunchAgent plist. LaunchAgent modifications affect future process behavior and therefore deserve strong anti-abuse controls.

Content

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

md
- `OPENCLAW_ALLOW_NONINTERACTIVE_SUDO` — set to `1` to allow non-interactive sudo through the shim (default: blocked)
- `OPENCLAW_PRIV_REASON` — human-readable reason passed to the guarded execution wrapper
- `OPENCLAW_VIOLATION_NOTIFY_STATE` — override path to the notification state file
- `OPENCLAW_SKIP_PLIST_CONFIRM` — set to `1` to skip the interactive confirmation before modifying the macOS LaunchAgent plist

**Policy files (admin reviewed):**
- `~/.openclaw/security/approved_ports.json`

Session Persistence

Medium
Category
Rogue Agent
Confidence
75% confidence
Finding

This finding is the same persistence concern at the same line: a flag that disables confirmation before changing a LaunchAgent plist. LaunchAgent modifications affect future process behavior and therefore deserve strong anti-abuse controls.

Content

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

md
- `OPENCLAW_ALLOW_NONINTERACTIVE_SUDO` — set to `1` to allow non-interactive sudo through the shim (default: blocked)
- `OPENCLAW_PRIV_REASON` — human-readable reason passed to the guarded execution wrapper
- `OPENCLAW_VIOLATION_NOTIFY_STATE` — override path to the notification state file
- `OPENCLAW_SKIP_PLIST_CONFIRM` — set to `1` to skip the interactive confirmation before modifying the macOS LaunchAgent plist

**Policy files (admin reviewed):**
- `~/.openclaw/security/approved_ports.json`

Sudo/Root Execution

Medium
Category
Privilege Escalation
Confidence
86% confidence
Finding

Documenting and installing a sudo-shimming mechanism that shadows the system sudo via PATH manipulation is inherently sensitive. Even if opt-in, PATH-based interception of privileged commands is dangerous because it creates opportunities for confusion, bypass, or abuse if users or calling processes do not clearly understand which sudo implementation is executing.

Content

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

md
8. If no approved baseline exists, generate one with `python3 scripts/generate_approved_ports.py`, then review and prune.
9. Benchmark controls against ISO 27001 and NIST and report violations with mitigations.

## Runtime Hook (sudo shim)

The script `scripts/install-openclaw-runtime-hook.sh` installs an **opt-in** sudo
shim at `~/.openclaw/bin/sudo`. This shim **shadows** the system `sudo` binary by

Sudo/Root Execution

Medium
Category
Privilege Escalation
Confidence
88% confidence
Finding

Placing a fake sudo earlier in PATH changes the trust boundary of all subsequent command execution in that process tree. In a security tool, that can be especially dangerous because operators may assume standard sudo behavior while actually invoking custom logic that mediates or logs privileged actions.

Content

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

md
## Runtime Hook (sudo shim)

The script `scripts/install-openclaw-runtime-hook.sh` installs an **opt-in** sudo
shim at `~/.openclaw/bin/sudo`. This shim **shadows** the system `sudo` binary by
prepending `~/.openclaw/bin` to `PATH` in the OpenClaw gateway process.

Sudo/Root Execution

Medium
Category
Privilege Escalation
Confidence
80% confidence
Finding

Interception of sudo invocations means this skill can sit in the execution path for privileged operations. That central mediation point becomes a high-value target: any flaw in policy enforcement, approval, logging, or argument handling could allow unauthorized root command execution or incomplete audit trails.

Content

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

md
- Intercepts `sudo` invocations and routes them through `guarded_privileged_exec.py`
- Requires explicit interactive user approval before running any privileged command
- Enforces command policy allow/deny rules, audit logging, and a 30-minute idle timeout
- Blocks non-interactive sudo by default (prevents automated abuse)
- Passes through harmless flags (`-h`, `--version`, `-k`, `-l`) directly to real sudo

**What it does NOT do:**

Sudo/Root Execution

Medium
Category
Privilege Escalation
Confidence
71% confidence
Finding

Passing selected flags directly through to the real sudo introduces split behavior that can create bypass opportunities if the allowlisted flag set is incomplete or parsed ambiguously. Attackers often exploit subtle option parsing differences in wrappers around security-sensitive binaries.

Content

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

md
- Requires explicit interactive user approval before running any privileged command
- Enforces command policy allow/deny rules, audit logging, and a 30-minute idle timeout
- Blocks non-interactive sudo by default (prevents automated abuse)
- Passes through harmless flags (`-h`, `--version`, `-k`, `-l`) directly to real sudo

**What it does NOT do:**
- It does not replace or modify the system sudo binary

Sudo/Root Execution

Medium
Category
Privilege Escalation
Confidence
84% confidence
Finding

The manifest explicitly states that behavior depends on PATH ordering, which is a classic command-hijacking vector. Any mechanism that relies on shadowing a standard administrative binary can be exploited or misapplied if PATH is manipulated unexpectedly or inherited in broader contexts than intended.

Content

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

md
- Passes through harmless flags (`-h`, `--version`, `-k`, `-l`) directly to real sudo

**What it does NOT do:**
- It does not replace or modify the system sudo binary
- It does not grant itself any elevated permissions
- It only affects processes whose `PATH` includes `~/.openclaw/bin` before `/usr/bin`

Session Persistence

Medium
Category
Rogue Agent
Confidence
75% confidence
Finding

The skill describes modifying the gateway LaunchAgent plist to enable PATH-based sudo interception, which is a form of persistent execution-context change. Persistence in a privileged-control skill is especially sensitive because it alters future command behavior beyond the immediate task.

Content

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

md
**Opt-in:** The hook is **not installed by default**. To enable it, run bootstrap with
`ENFORCE_PRIVILEGED_EXEC=1`. On macOS, the installer will prompt for confirmation
before modifying the gateway LaunchAgent plist. The shim can be removed at any time
by deleting `~/.openclaw/bin/sudo`.

## File Writes

Sudo/Root Execution

Medium
Category
Privilege Escalation
Confidence
74% confidence
Finding

The skill persists privileged session state and audit data and stores a sudo shim under the user’s OpenClaw directory. Persistence around privileged workflows increases risk because tampering with state files or the shim could alter approval behavior, suppress evidence, or affect future executions.

Content

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

md
- `~/.openclaw/security/root-session-state.json` — elevated session state (by `root_session_guard.py`)
- `~/.openclaw/security/privileged-audit.jsonl` — append-only audit log (by `audit_logger.py`)
- `~/.openclaw/security/violation-notify-state.json` — notification diff state (by `notify_on_violation.py`)
- `~/.openclaw/bin/sudo` — opt-in sudo shim (by `install-openclaw-runtime-hook.sh`, see Runtime Hook section)
- `~/.openclaw/logs/cyber-security-engineer-auto.log` — auto-cycle run log (by `auto_invoke_cycle.sh`)

**Under `assessments/` (inside skill directory):**

Session Persistence

Medium
Category
Rogue Agent
Confidence
60% 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 · assessments/compliance-dashboard.html (reported line 109)May include surrounding context.

html
<tr><td>privilege_approval_required</td><td>Route all privileged tasks through guarded_privileged_exec.py and enforce approval prompts for elevated execution.</td><td>Security Engineering</td><td>2026-03-15</td></tr>
<tr><td>least_privilege_enforced</td><td>Fix state dir ownership/permissions and enforce command allowlist/approval defaults.</td><td>Platform Security</td><td>2026-03-07</td></tr>
<tr><td>elevation_timeout_30m</td><td>Invoke guarded_privileged_exec.py for every elevated operation path.</td><td>Security Engineering</td><td>2026-03-15</td></tr>
<tr><td>audit_logging_privileged_actions</td><td>Create append-only correlated audit records linking approval, execution, and drop events.</td><td>SecOps</td><td>2026-03-22</td></tr>
<tr><td>open_ports_approved</td><td>Populate ~/.openclaw/security/approved_ports.json and remove unnecessary listeners.</td><td>Infrastructure</td><td>2026-02-28</td></tr>
<tr><td>insecure_ports_remediated</td><td>Enforce baseline checks to block insecure service ports.</td><td>Network Security</td><td>2026-04-01</td></tr>
        </tbody>

Session Persistence

Medium
Category
Rogue Agent
Confidence
60% 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 · assessments/compliance-summary.json (reported line 74)May include surrounding context.

json
"observed_state": "Gateway logs and session transition logs are available.",
        "evidence": "gateway status reports log paths; root_session_guard records transition metadata.",
        "gap": "No single correlated privileged action audit timeline is guaranteed.",
        "mitigation": "Create append-only correlated audit records linking approval, execution, and drop events.",
        "owner": "SecOps",
        "due_date": "2026-03-22"
      },

Intent-Code Divergence

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

This entry declares the least-privilege control as compliant while simultaneously documenting unresolved writable state directory and integrity warnings. That contradiction can mislead operators, auditors, or automated governance workflows into treating a non-hardened privileged environment as adequately protected, reducing urgency for remediation.

Content

No source excerpt is available for this finding.

Intent-Code Divergence

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The control section repeats the same contradiction: it marks least-privilege enforcement as compliant while admitting the posture is incomplete due to ownership/permission and integrity concerns. In a security engineering skill, this is especially dangerous because downstream reporting or approval processes may rely on the control table as authoritative and permit risky privileged operation paths.

Content

No source excerpt is available for this finding.

Session Persistence

Medium
Category
Rogue Agent
Confidence
60% 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 · assessments/openclaw-assessment.json (reported line 51)May include surrounding context.

json
"observed_state": "Gateway logs and session transition logs are available.",
      "evidence": "gateway status reports log paths; root_session_guard records transition metadata.",
      "gap": "No single correlated privileged action audit timeline is guaranteed.",
      "mitigation": "Create append-only correlated audit records linking approval, execution, and drop events.",
      "owner": "SecOps",
      "due_date": "2026-03-22"
    },

Static analysis

No suspicious patterns detected.