T05 · Unauthorized Access and Privilege Escalation
- Location
SKILL.md:20- Finding
Overbroad Access to Sensitive OpenClaw Configuration and Session State
- Content
View full analysis
Vulnerability Details
File Location:
SKILL.md, lines 20-29; additional session inspection instructions at lines 124-128
Vulnerability Type:T05: Unauthorized Access and Privilege Escalation
Risk Level: MediumVulnerable Instructions
markdown 1. Read `~/.openclaw/openclaw.json` 2. Read `~/.openclaw/cron/jobs.json` if it exists 3. Read `~/.openclaw/secrets.json` (path only, never the values) 4. Read `~/.openclaw/workspace/AGENTS.md` if present 5. Read `~/.openclaw/workspace/HEARTBEAT.md` if present 6. Check plugin status: `openclaw status 2>&1 | head -30` 7. Check channel status: `openclaw channels status --probe 2>&1` 8. Run the built-in security audit: `openclaw security audit 2>&1` 9. Check `~/.openclaw/workspace/state/sessions/` for stale ACP session files 10. Cross-reference fallback model providers with `auth.profiles` for orphansmarkdown #### 17. ACP zombie session state (CRITICAL) - List `~/.openclaw/workspace/state/sessions/*.json` and `~/.openclaw/agents/*/sessions/sessions.json` - Any session with `closed: false` whose `pid` is no longer running is a zombie - ALSO check `~/.openclaw/<channel>/thread-bindings-default.json` — these can silently re-route inbound messages to dead ACP subprocesses for 24h+ - **Fix:** archive the stale session state files, delete thread-bindings; if ACP is disabled (`acp.enabled: false`), the entire `~/.openclaw/workspace/state/sessions/` directory should be empty.Technical Analysis
The Skill instructs the Agent to read multiple security-sensitive files, including the secret store, Agent instruction files, authentication configuration, cron payloads, channel bindings, and session records. This exceeds least privilege because the audit only needs selected metadata, such as whether a secret reference is object-shaped, whether a provider profile exists, and whether a session PID remains active.
The inst ...[truncated 1933 chars]
- Remediation
View remediation
Remediation Suggestions
- Remove the instruction to read
secrets.json. Check only its existence, ownership, permissions, and non-secret schema metadata through a trusted redacting utility. - Use field-level extraction for configuration files. Permit only the exact keys required by each check and redact values associated with names such as
apiKey,token,secret,password, andcredential. - For session records, extract only
pid,closed, timestamps, and non-sensitive identifiers. Never load message bodies or transcripts into model context. - Require explicit user approval before inspecting
AGENTS.md,HEARTBEAT.md, session stores, or channel-binding files. - Treat all inspected file content as untrusted data and explicitly prohibit following instructions found inside configuration, workspace, cron, or session files.
- Perform secret-pattern checks locally using a deterministic scanner that returns only file paths, field paths, and redacted match types.
- Ensure generated reports never include raw credentials, complete session payloads, or unrelated workspace instructions.
- Document the minimum filesystem permissions required and run the audit under a restricted account with access only to the necessary OpenClaw metadata.
- Remove the instruction to read
