Back to skill

Security audit

browser-toggle

Security checks for vulnerabilities and agentic risk

Overview

The skill mostly matches its browser-toggle purpose, but it gives risky install guidance through an unverified external archive and has an under-scoped restore command that can overwrite OpenClaw configuration from any file.

Install only from the reviewed ClawHub artifact or a verified maintainer source, not from the placeholder GitHub archive instructions in SHARE.md. Before using --restore, only pass backup files you trust from the OpenClaw backup directory, because the current implementation can replace the active OpenClaw config with arbitrary file contents. Review any sudo or deletion commands before copying them into a shell.

Vulnerability Patterns
  • Remote Payload Retrieval and ExecutionFetches external code whose behavior can change after review
  • 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
  • Embedded Malicious CodeShips malicious scripts inside the skill and executes them locally
Findings (2)

T03 · Remote Payload Retrieval and Execution

Error
Location
SHARE.md:24
Finding

External Skill Archive Is Downloaded and Executed Without Enforced Integrity Verification

Content
View full analysis
Remediation
View remediation

T09 · Insecure Skill Coding Practices

Warning
Location
browser_toggle.py:123
Finding

Unvalidated Restore Operation Can Replace the Active OpenClaw Configuration With an Arbitrary File

Content
View full analysis
bool: try: backup_path = Path(backup_file) if not backup_path.exists(): return False shutil.copy2(backup_path, self.config_file) return True except Exception: return False ``` The command-line path reaches this operation directly: ```python elif args.restore: if toggle.restore_from_backup(args.restore): print("\n✅ 恢复成功!") sys.exit(0) else: print("\n❌ 恢复失败!") sys.exit(1) ``` ### Technical Analysis The `--restore` option accepts any existing path accessible to the invoking user. The implementation does not: - Restrict the source to the designated OpenClaw backup directory. - Verify that the source is a regular file. - Reject symbolic links. - Parse the source as JSON before overwriting the active configuration. - Validate the restored data against an expected OpenClaw configuration schema. - Create a backup of the current configuration before restoration. - Perform an atomic replacement. Consequently, any readable file can be copied over `~/.openclaw/openclaw.json`. An invalid file can make the configuration unreadable, while an attacker-controlled valid JSON file can introduce arbitrary settings recognized by OpenClaw. `shutil.copy2` also copies source metadata, which may apply inappropriate permission or timestamp metadata to the active configuration. ### Attack Path 1. An attacker places or supplies a crafted file at a location readable by the victim. 2. The attacker persuades the user or an automation process to run: ```bash openclaw-browser --restore /path/to/attacker-controlled-file ``` 3. The program checks only that the supplied path exists. 4. The supplied f ...[truncated 1173 chars]
Remediation
View remediation
Vulnerability Patterns
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
  • Tool MisuseTool Parameter Abuse, Chaining Abuse, Unsafe Defaults
  • Rogue AgentSelf-Modification, Session Persistence
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
Findings (27)

Tool Parameter Abuse

High
Category
Tool Misuse
Confidence
90% confidence
Finding

Tool parameters are crafted to achieve unintended or unsafe behavior. Parameter abuse can bypass intended safety checks (e.g. shell=True, --force, dangerous glob patterns).

Content

Scanner excerpt · INSTALL.md (reported line 197)May include surrounding context.

md
openclaw gateway restart

# 2. 删除 Skill
rm -rf ~/.openclaw/workspace/skills/browser-toggle

# 3. 删除全局命令(如果存在)
sudo rm -f /usr/local/bin/openclaw-browser

Tool Parameter Abuse

High
Category
Tool Misuse
Confidence
90% confidence
Finding

Tool parameters are crafted to achieve unintended or unsafe behavior. Parameter abuse can bypass intended safety checks (e.g. shell=True, --force, dangerous glob patterns).

Content

Scanner excerpt · INSTALL.md (reported line 197)May include surrounding context.

md
openclaw gateway restart

# 2. 删除 Skill
rm -rf ~/.openclaw/workspace/skills/browser-toggle

# 3. 删除全局命令(如果存在)
sudo rm -f /usr/local/bin/openclaw-browser

Tool Parameter Abuse

High
Category
Tool Misuse
Confidence
85% confidence
Finding

Tool parameters are crafted to achieve unintended or unsafe behavior. Parameter abuse can bypass intended safety checks (e.g. shell=True, --force, dangerous glob patterns).

Content

Scanner excerpt · INSTALL.md (reported line 200)May include surrounding context.

rm -rf ~/.openclaw/workspace/skills/browser-toggle

3. 删除全局命令(如果存在)

sudo rm -f /usr/local/bin/openclaw-browser

text

---

Tool Parameter Abuse

High
Category
Tool Misuse
Confidence
93% confidence
Finding

The command rm -rf ~/.openclaw/workspace/skills/browser-toggle recursively deletes a directory and is presented as a copy-paste uninstall step without an explicit warning. Even though the path is specific to the skill, recursive force deletion is risky in documentation because path mistakes, symlink surprises, or user misunderstanding can cause unintended data loss.

Content

Scanner excerpt · SHARE.md (reported line 199)May include surrounding context.

md
openclaw gateway restart

# 2. 删除 Skill
rm -rf ~/.openclaw/workspace/skills/browser-toggle

# 3. 删除全局命令(如果存在)
sudo rm -f /usr/local/bin/openclaw-browser

Tool Parameter Abuse

High
Category
Tool Misuse
Confidence
93% confidence
Finding

The command rm -rf ~/.openclaw/workspace/skills/browser-toggle recursively deletes a directory and is presented as a copy-paste uninstall step without an explicit warning. Even though the path is specific to the skill, recursive force deletion is risky in documentation because path mistakes, symlink surprises, or user misunderstanding can cause unintended data loss.

Content

Scanner excerpt · SHARE.md (reported line 199)May include surrounding context.

md
openclaw gateway restart

# 2. 删除 Skill
rm -rf ~/.openclaw/workspace/skills/browser-toggle

# 3. 删除全局命令(如果存在)
sudo rm -f /usr/local/bin/openclaw-browser

Tool Parameter Abuse

High
Category
Tool Misuse
Confidence
89% confidence
Finding

The command rm -f /usr/local/bin/openclaw-browser removes a file from a privileged system path and may be executed with sudo, making it sensitive. In documentation, direct destructive commands against system locations are dangerous if presented without explanation, validation, or warnings, because users may remove the wrong file or normalize unsafe copy-paste behavior.

Content

Scanner excerpt · SHARE.md (reported line 202)May include surrounding context.

rm -rf ~/.openclaw/workspace/skills/browser-toggle

3. 删除全局命令(如果存在)

sudo rm -f /usr/local/bin/openclaw-browser

text

---

Tool Parameter Abuse

High
Category
Tool Misuse
Confidence
95% confidence
Finding

Tool parameters are crafted to achieve unintended or unsafe behavior. Parameter abuse can bypass intended safety checks (e.g. shell=True, --force, dangerous glob patterns).

Content

Scanner excerpt · build.sh (reported line 28)May include surrounding context.

sh
# 删除不必要的文件
echo "🗑️ 删除不必要的文件..."
rm -f "$BUILD_DIR"/*.pyc
rm -rf "$BUILD_DIR"/__pycache__
rm -f "$BUILD_DIR"/dist/*.tar.gz 2>/dev/null || true

Tool Parameter Abuse

High
Category
Tool Misuse
Confidence
95% confidence
Finding

Tool parameters are crafted to achieve unintended or unsafe behavior. Parameter abuse can bypass intended safety checks (e.g. shell=True, --force, dangerous glob patterns).

Content

Scanner excerpt · build.sh (reported line 29)May include surrounding context.

sh
# 删除不必要的文件
echo "🗑️ 删除不必要的文件..."
rm -f "$BUILD_DIR"/*.pyc
rm -rf "$BUILD_DIR"/__pycache__
rm -f "$BUILD_DIR"/dist/*.tar.gz 2>/dev/null || true

# 创建 README

Tool Parameter Abuse

High
Category
Tool Misuse
Confidence
95% confidence
Finding

Tool parameters are crafted to achieve unintended or unsafe behavior. Parameter abuse can bypass intended safety checks (e.g. shell=True, --force, dangerous glob patterns).

Content

Scanner excerpt · build.sh (reported line 30)May include surrounding context.

sh
echo "🗑️ 删除不必要的文件..."
rm -f "$BUILD_DIR"/*.pyc
rm -rf "$BUILD_DIR"/__pycache__
rm -f "$BUILD_DIR"/dist/*.tar.gz 2>/dev/null || true

# 创建 README
echo "📝 创建发布说明..."

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The file forces Chinese-language instructions throughout, including the title, headings, warnings, and command descriptions, with no indication that this skill is region-specific or that users may choose another language. Per the policy, imposing a specific language without user opt-in is a natural-language policy violation.

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 · INSTALL.md (reported line 40)May include surrounding context.

bash
# 1. 创建 Skill 目录
mkdir -p ~/.openclaw/workspace/skills/browser-toggle

# 2. 复制文件
cp browser_toggle.py ~/.openclaw/workspace/skills/browser-toggle/

Sudo/Root Execution

Medium
Category
Privilege Escalation
Confidence
70% confidence
Finding

Commands invoke sudo or root privileges. Verify this elevated access is necessary and justified.

Content

Scanner excerpt · INSTALL.md (reported line 159)May include surrounding context.

bash
# 安装 Chrome
wget https://dl.google.com/linux/direct/google-chrome-stable_current_amd64.deb
sudo dpkg -i google-chrome-stable_current_amd64.deb
sudo apt-get install -f -y

Sudo/Root Execution

Medium
Category
Privilege Escalation
Confidence
70% confidence
Finding

Commands invoke sudo or root privileges. Verify this elevated access is necessary and justified.

Content

Scanner excerpt · INSTALL.md (reported line 160)May include surrounding context.

bash
# 安装 Chrome
wget https://dl.google.com/linux/direct/google-chrome-stable_current_amd64.deb
sudo dpkg -i google-chrome-stable_current_amd64.deb
sudo apt-get install -f -y

Sudo/Root Execution

Medium
Category
Privilege Escalation
Confidence
70% confidence
Finding

Commands invoke sudo or root privileges. Verify this elevated access is necessary and justified.

Content

Scanner excerpt · INSTALL.md (reported line 200)May include surrounding context.

bash
# 安装 Chrome
wget https://dl.google.com/linux/direct/google-chrome-stable_current_amd64.deb
sudo dpkg -i google-chrome-stable_current_amd64.deb
sudo apt-get install -f -y

Sudo/Root Execution

Medium
Category
Privilege Escalation
Confidence
70% confidence
Finding

Commands invoke sudo or root privileges. Verify this elevated access is necessary and justified.

Content

Scanner excerpt · README.md (reported line 176)May include surrounding context.

bash
# 安装 Chrome
wget https://dl.google.com/linux/direct/google-chrome-stable_current_amd64.deb
sudo dpkg -i google-chrome-stable_current_amd64.deb
sudo apt-get install -f -y

Sudo/Root Execution

Medium
Category
Privilege Escalation
Confidence
70% confidence
Finding

Commands invoke sudo or root privileges. Verify this elevated access is necessary and justified.

Content

Scanner excerpt · SHARE.md (reported line 163)May include surrounding context.

bash
# 安装 Chrome
wget https://dl.google.com/linux/direct/google-chrome-stable_current_amd64.deb
sudo dpkg -i google-chrome-stable_current_amd64.deb
sudo apt-get install -f -y

Sudo/Root Execution

Medium
Category
Privilege Escalation
Confidence
70% confidence
Finding

Commands invoke sudo or root privileges. Verify this elevated access is necessary and justified.

Content

Scanner excerpt · SHARE.md (reported line 164)May include surrounding context.

bash
# 安装 Chrome
wget https://dl.google.com/linux/direct/google-chrome-stable_current_amd64.deb
sudo dpkg -i google-chrome-stable_current_amd64.deb
sudo apt-get install -f -y

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
90% confidence
Finding

This markdown file includes rm -rf ~/.openclaw/workspace/skills/browser-toggle and sudo rm -f /usr/local/bin/openclaw-browser as uninstall steps, which are destructive operations. While the section labels them as uninstall actions, the document does not explicitly warn users that these commands permanently delete files and may remove the installed skill or global command irreversibly.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
98% confidence
Finding

All user-facing instructions and descriptions in the file are presented only in Chinese, and the document does not indicate that this language choice is optional or region-specific. This can violate language/locale policy when a skill forces a specific language without user opt-in.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The uninstall section includes destructive deletion commands (rm -rf and sudo rm -f) without an explicit warning that they permanently remove files and may require elevated privileges. In documentation, this is dangerous because users may copy-paste commands blindly, leading to unintended data loss or removal of the wrong path if the command is modified or variables resolve unexpectedly.

Content

No source excerpt is available for this finding.

Sudo/Root Execution

Medium
Category
Privilege Escalation
Confidence
88% confidence
Finding

The documentation instructs users to run sudo rm -f /usr/local/bin/openclaw-browser, which performs privileged deletion without a warning or verification step. In a skill-installation context, privileged file deletion is sensitive because users may copy-paste it without confirming the target or understanding the impact.

Content

Scanner excerpt · SHARE.md (reported line 202)May include surrounding context.

rm -rf ~/.openclaw/workspace/skills/browser-toggle

3. 删除全局命令(如果存在)

sudo rm -f /usr/local/bin/openclaw-browser

text

---

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
96% confidence
Finding

The user-facing title/description text is written in Chinese and does not indicate that other languages are supported or that the locale restriction is intentional. The policy requires avoiding language or locale constraints unless the skill offers opt-in choice or clearly documents a justified region-specific limitation.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The script's comments, console messages, and the generated RELEASE.md content are entirely in Chinese, which imposes a specific language on users and operators. Under the policy, this is a natural-language locale violation because there is no opt-in, alternate language, or stated region-specific justification.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
96% confidence
Finding

The script's comments and nearly all user-facing status/help messages are in Chinese, which imposes a specific language on users. The file does not offer an alternative language, opt-in, or any justification that this skill is intended only for a Chinese-language environment.

Content

No source excerpt is available for this finding.

Missing User Warnings

Low
Category
Not specified by scanner
Confidence
89% confidence
Finding

This markdown file describes behavior that enables/disables the browser by changing configuration state, including automatic backup and recovery, but it does not explicitly warn users that configuration files will be modified. For markdown skills, operations affecting user data or system integrity should be disclosed so users understand the impact before running the skill.

Content

No source excerpt is available for this finding.