T05 · Unauthorized Access and Privilege Escalation
- Location
SKILL.md:13- Finding
Overbroad Scanning of Sensitive Workspace State
- Content
View full analysis
Vulnerability Details
File Location:
SKILL.md, lines 13-16
Vulnerability Type: Overbroad access to agent workspace and persistent state
Risk Level: MediumVulnerable Code
bash grep -r "filename" ~/.openclaw/workspace/*.md grep -r "filename" ~/.openclaw/cron/Technical Analysis
The skill instructs the agent to search every Markdown file in the workspace root and recursively search the cron directory. According to the documented workspace model, root Markdown files can include
USER.mdandMEMORY.md, which may contain personal information and persistent agent memory.Returning matching lines gives the operation access to file contents rather than only the reference metadata required for workspace organization. This violates least-privilege principles because reference discovery can be performed by returning only file paths or by searching a narrowly defined allowlist.
The commands do not transmit information over a network, alter permissions, or establish persistence. The risk is limited to unnecessarily exposing sensitive workspace content to the active agent context and any generated report.
Attack Path
- Sensitive information is stored in a root Markdown file such as
USER.mdorMEMORY.md, or in a cron configuration file. - A filename or chosen search term also appears on a line containing that sensitive information.
- The workspace-cleaner skill executes the unrestricted recursive search.
grepreturns the complete matching line rather than only the name of the referencing file.- The sensitive line enters the command output and may subsequently be incorporated into the conversation or audit report.
Impact Assessment
The issue can disclose matching portions of personal information, long-term agent memory, configuration instructions, or scheduled-task content available to the current user account. It does not independently provide elevated operating-system pr ...[truncated 120 chars]
- Sensitive information is stored in a root Markdown file such as
- Remediation
View remediation
Remediation Suggestions
-
Search an explicit allowlist of non-sensitive configuration files instead of all root Markdown files.
-
Exclude
USER.md,MEMORY.md, and other sensitive state files by default. -
Request explicit user consent before inspecting persistent memory or personal-information files.
-
Return only referencing file names rather than matching content, for example:
bash grep -rlF -- "$filename" "${approved_files[@]}" -
Apply equivalent scope restrictions to the cron directory.
-
Redact secrets and personal data before including search results in a generated report.
-
Display the exact search scope to the user before accessing sensitive workspace state.
-
