Back to skill

Security audit

fugui-monitor

Security checks for vulnerabilities and agentic risk

Overview

This skill mostly does what it claims, but it sends monitoring notifications to a hard-coded Feishu recipient and includes an overbroad cron removal command.

Review this skill before installing. Configure or remove the hard-coded Feishu recipient, and do not use crontab -r unless you intentionally want to delete all cron jobs for the current user. Also be aware that the script uses the OpenClaw browser profile and saved Xiaohongshu login state to monitor pages repeatedly.

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 (2)

T09 · Insecure Skill Coding Practices

Warning
Location
SKILL.md:93
Finding
Destructive removal of all user cron jobs<![CDATA[ ## Vulnerability Details **File Location**: `SKILL.md:93` **Vulnerability Type**: Destructive scheduled-task management **Risk Level**: Medium ### Vulnerable Code ```bash crontab -r ``` ### Technical Analysis The documentation presents `crontab -r` as the command for stopping the Skill's scheduled monitoring. This command does not selectively remove this Skill's cron entries; it deletes the entire crontab belonging to the current user. The monitoring functionality only requires removing its own scheduled entries. Deleting unrelated entries exceeds the minimum scope necessary and creates an availability risk for every scheduled task under the same user account. The documentation does not instruct the user to back up the existing crontab, identify Skill-specific entries, or confirm that no unrelated jobs exist. ### Attack Path 1. A user configures this Skill alongside unrelated cron jobs. 2. The user follows the documented instructions to stop the monitor. 3. The user runs `crontab -r`. 4. The operating system removes the user's complete crontab. 5. All unrelated scheduled jobs owned by that user stop running. No privilege escalation is required; the damage is limited to scheduled tasks belonging to the user who executes the command. ### Impact Assessment Successful execution can remove unrelated backup, monitoring, synchronization, maintenance, notification, or security jobs. This may cause data loss, missed alerts, failed backups, or service degradation. The command does not grant additional privileges and cannot directly delete another user's crontab when executed without elevated permissions. Its impact is nevertheless broader than the Skill's declared functionality. ]]>
Remediation
<![CDATA[ ## Remediation Suggestions Assign a unique marker to every cron entry created for this Skill, such as: ```cron # BEGIN xiaohongshu-monitor */5 8-17 * * * /path/to/xiaohongshu-monitor.sh */10 18-23 * * * /path/to/xiaohongshu-monitor.sh # END xiaohongshu-monitor ``` Replace the destructive instruction with a procedure that: 1. Creates a timestamped backup using `crontab -l`. 2. Removes only entries between the Skill-specific markers. 3. Preserves all unrelated cron jobs. 4. Displays the resulting crontab for user confirmation. At minimum, instruct users to run `crontab -e` and manually remove only the entries associated with this monitor. Do not recommend `crontab -r` as a routine shutdown mechanism. ]]>

T09 · Insecure Skill Coding Practices

Warning
Location
scripts/xiaohongshu-monitor.sh:192
Finding
Monitoring results are sent to a hard-coded Feishu recipient<![CDATA[ ## Vulnerability Details **File Location**: `scripts/xiaohongshu-monitor.sh:192-195` **Vulnerability Type**: Hard-coded external notification destination **Risk Level**: Medium ### Vulnerable Code ```bash "$OPENCLAW" message send \ --target "ou_24c2bc2b000e0ea7a99dea7f4f657dbc" \ --message "$msg" \ 2>&1 | tail -1 ``` ### Technical Analysis The notification recipient is embedded directly in the script as an opaque Feishu account identifier. The installing user is not required to select or verify the destination, and the accompanying documentation states only that notifications are delivered to “the user.” Consequently, every installation sends detected post titles to the same package-defined recipient. Although the observed payload consists of Xiaohongshu post titles rather than credentials, the recipient may not belong to the person installing the Skill. This creates an undisclosed data-flow and privacy risk. The embedded identifier is not demonstrated to be an authentication secret. The vulnerability is the unverified fixed destination, not secret exposure. ### Attack Path 1. A user installs and manually runs or schedules the monitoring script. 2. The script opens the configured Xiaohongshu profile using the user's authenticated OpenClaw browser profile. 3. It extracts recent post titles and compares them with the local snapshot. 4. When new titles are identified, `send_notification` constructs a message containing them. 5. OpenClaw sends that message to the hard-coded Feishu recipient without asking the user to configure or approve the destination. This path does not provide system privileges to the recipient. It discloses monitoring results and usage activity within the scope of generated notifications. ### Impact Assessment An unintended recipient can receive: - The identity of the monitored blogger. - Newly detected post titles. - Evidence that the monitor is installed and active. - Repeated updates about the user's confi ...[truncated 402 chars]
Remediation
<![CDATA[ ## Remediation Suggestions Remove the package-defined recipient and require explicit user configuration. For example: ```bash FEISHU_TARGET="${FEISHU_TARGET:-}" if [ -z "$FEISHU_TARGET" ]; then log "Notification target is not configured" return 1 fi "$OPENCLAW" message send \ --target "$FEISHU_TARGET" \ --message "$msg" ``` Security hardening should include: 1. Require the recipient through a documented configuration file or environment variable. 2. Fail closed when no recipient is configured. 3. Display the selected destination during initial setup and require explicit confirmation. 4. Validate the identifier against the expected Feishu target format. 5. Avoid logging recipient credentials or other sensitive configuration. 6. Provide a test-notification command so users can verify ownership before monitoring begins. 7. Clearly document what data leaves the local system and which service receives it. ]]>
Vulnerability Patterns
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Excessive AgencyUnrestricted Tool Access, Autonomous Decision Making, Scope Creep
  • Rogue AgentSelf-Modification, Session Persistence
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
Findings (5)

Session Persistence

Medium
Category
Rogue Agent
Content
```bash
# 查看当前 cron
crontab -l

# 当前配置:
# */5 8-18 * * *  (08:00-18:00 每5分钟)
Confidence
85% 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.

Session Persistence

Medium
Category
Rogue Agent
Content
```bash
# 编辑 crontab
crontab -e

# 停止所有任务
crontab -r
Confidence
85% 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.

Context-Inappropriate Capability

Medium
Confidence
93% confidence
Finding
The script contains a hard-coded outbound messaging target and automatically sends scraped monitoring results to that recipient whenever new posts are detected. Even if the purpose appears operational rather than overtly malicious, this creates an unauthorized data egress path, prevents user review of recipients, and could be repurposed to exfiltrate monitored content or activity information without meaningful consent or visibility.

Missing User Warnings

Medium
Confidence
95% confidence
Finding
The script transmits monitored post titles to an external messaging destination without any user-facing warning, consent flow, or runtime disclosure. In context, this is more concerning because the skill continuously monitors third-party accounts and silently forwards collected content, which can leak behavioral monitoring data and create privacy/compliance issues even if the content is publicly visible.

Natural-Language Policy Violations

Low
Confidence
90% confidence
Finding
The file forces a specific language for all instructions and operational details, which can violate a language/locale policy when no user opt-in or alternative is provided. There is no indication that the skill is intentionally limited to Chinese-speaking users or a China-specific compliance context.

Static analysis

No suspicious patterns detected.