T05 · Unauthorized Access and Privilege Escalation
- Location
SKILL.md:114- Finding
Overbroad Host Reconnaissance Exceeds the Minimum OpenClaw Audit Scope
- Content
View full analysis
Vulnerability Details
File Location:
SKILL.md:43-53,SKILL.md:64-68,SKILL.md:102-129
Vulnerability Type: Excessive system enumeration and least-privilege boundary violation
Risk Level: MediumRelevant Code
markdown ### 0) Identify Environment 1. Determine OS and host context: - `uname -a` - `cat /etc/os-release` - `hostname` 2. Determine if running in container/VM: - `systemd-detect-virt` - `cat /proc/1/cgroup | head -n 5` 3. Determine working dir and user: - `pwd` - `whoami`markdown ### 2) Network Exposure & Listening Services 1. List open ports: - `ss -tulpen` 2. Identify whether gateway ports are bound to **localhost only** or **public**. 3. Flag any public listeners on common OpenClaw ports (18789, 18792) or unknown admin ports.markdown ### 7) Credentials & Secret Storage 1. Check for plaintext secrets locations: - `~/.openclaw/` directories - `.env` files, token dumps, backups 2. Identify world-readable or group-readable secret files: - `find ~/.openclaw -type f -perm -o+r -maxdepth 4 2>/dev/null | head -n 50` 3. Report only **paths**, never contents. ### 8) File Permissions & Privilege Escalation Risks 1. Check for risky permissions on key dirs: - `ls -ld ~/.openclaw` - `ls -l ~/.openclaw | head -n 50` 2. Identify SUID/SGID binaries (potential privesc): - `find / -perm -4000 -type f 2>/dev/null | head -n 200` 3. Flag if OpenClaw runs as root or with unnecessary sudo. ### 9) Process & Persistence Indicators 1. Check for unexpected cron jobs: - `crontab -l` - `ls -la /etc/cron.* 2>/dev/null` 2. Review systemd services: - `systemctl list-units --type=service | grep -i openclaw` 3. Flag unknown services related to OpenClaw or skills. ### 10) Logs & Audit Trails 1. Review gateway logs (read-only): - `journalctl -u openclaw-gateway --no-pager ...[truncated 2790 chars]- Remediation
View remediation
Remediation Suggestions
- Restrict the default workflow to OpenClaw-owned paths, known gateway ports, OpenClaw processes, and explicitly named OpenClaw services.
- Move system-wide SUID, cron, listener, and service enumeration into a separate optional host-hardening phase.
- Require explicit informed approval before executing host-wide checks, clearly listing the commands and data categories they may expose.
- Replace
find / -perm -4000with a scoped search of OpenClaw installation paths unless a full host audit is explicitly requested. - Filter listener results to known OpenClaw ports and processes rather than returning all host listeners.
- Continue reporting only secret-file paths, but redact usernames, home directories, external IP addresses, tokens, command-line credentials, and other sensitive values.
- Avoid storing raw command output in reports or persistent agent memory; summarize only the evidence needed to support each finding.
- Run the audit under a dedicated unprivileged account without unrestricted
sudo, and document the minimum permissions required for each optional check. - Mark checks as
UNKNOWNwhen the required data is inaccessible rather than requesting or assuming elevated privileges. - Retain the existing prohibition against modifying configuration, rotating keys, terminating processes, or performing remediation without explicit user approval.
