Back to skill

Security audit

Email Backup

Security checks for vulnerabilities and agentic risk

Overview

This skill openly backs up files by emailing archives, but it encourages broad backups and has flawed sensitive-data cleaning that can send unredacted private files.

Review carefully before installing. Use only narrow, known-safe directories, prefer --no-send until you inspect the archive contents, do not rely on --clean to remove secrets, avoid backing up OpenClaw workspace/agent folders unless you have audited them, and do not install or run it with sudo or from an unverified tarball.

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

T09 · Insecure Skill Coding Practices

Error
Location
scripts/backup_and_send.py:91
Finding

Sanitization Replaces an Extracted File Instead of the Original Archive

Content
View full analysis
Remediation
View remediation

T09 · Insecure Skill Coding Practices

Error
Location
scripts/clean_sensitive.py:11
Finding

Incomplete Regex-Based Sanitization Creates a False Expectation of Secret Removal

Content
View full analysis
Remediation
View remediation

T09 · Insecure Skill Coding Practices

Warning
Location
scripts/backup_and_send.py:85
Finding

Extracted Symbolic Links Can Cause Sanitization Outside the Temporary Directory

Content
View full analysis
Remediation
View remediation
Vulnerability Patterns
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
  • Rogue AgentSelf-Modification, Session Persistence
  • Trigger AbuseOverly Broad Trigger, Shadow Command Trigger, Keyword Baiting Trigger
  • MCP Least PrivilegeUnderdeclared Capability, Wildcard Permission, Missing Permission Declaration
Findings (39)

Tp4

High
Category
MCP Tool Poisoning
Confidence
94% confidence
Finding

The skill advertises QQ email backup/compression, but the finding suggests those core functions may be absent while network transmission capability is undeclared. A user relying on the description could install a tool whose real behavior is materially different from its stated purpose, undermining informed consent and creating risk of hidden file processing or unauthorized outbound data handling.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
99% confidence
Finding

The skill advertises QQ email backup/compression, but the finding suggests those core functions may be absent while network transmission capability is undeclared. A user relying on the description could install a tool whose real behavior is materially different from its stated purpose, undermining informed consent and creating risk of hidden file processing or unauthorized outbound data handling.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
95% confidence
Finding

The skill advertises QQ email backup/compression, but the finding suggests those core functions may be absent while network transmission capability is undeclared. A user relying on the description could install a tool whose real behavior is materially different from its stated purpose, undermining informed consent and creating risk of hidden file processing or unauthorized outbound data handling.

Content

No source excerpt is available for this finding.

Missing User Warnings

High
Category
Not specified by scanner
Confidence
98% confidence
Finding

The instructions direct the user/agent to download a remote tarball via curl, extract it, mark scripts executable, and run a Python script, but they provide no authenticity verification, integrity checking, or warning that this executes untrusted code. This creates a clear software supply chain risk: a compromised URL, package, or transport path could lead to arbitrary code execution in the user's environment.

Content

No source excerpt is available for this finding.

Credential Access

High
Category
Privilege Escalation
Confidence
60% confidence
Finding

Code accesses credential files (SSH keys, AWS credentials, etc.). This could indicate credential theft attempts.

Content

Scanner excerpt · scripts/clean_sensitive.py (reported line 59)May include surrounding context.

python
try:
        # 检查文件类型
        file_ext = os.path.splitext(filepath)[1].lower()
        text_extensions = ['.md', '.json', '.py', '.js', '.ts', '.env', '.config', '.yaml', '.yml', '.txt', '.sh', '.bash']
        
        if file_ext not in text_extensions:
            return False

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

  1. 下载 Skill 文件
    bash
    # 创建 skills 目录(如果不存在)
    mkdir -p ~/.openclaw/workspace/skills
    
    # 下载并解压
    cd ~/.openclaw/workspace/skills
    

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

  1. 下载 Skill 文件
    bash
    # 创建 skills 目录(如果不存在)
    mkdir -p ~/.openclaw/workspace/skills
    
    # 下载并解压
    cd ~/.openclaw/workspace/skills
    

File System Enumeration

Medium
Category
Data Exfiltration
Confidence
60% confidence
Finding

Code scans file system directories looking for sensitive files. This could be reconnaissance for credential theft.

Content

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

  1. 验证安装
    bash
    # 检查文件结构
    ls -la ~/.openclaw/workspace/skills/email-backup/
    
    # 应该看到:
    # SKILL.md
    

File System Enumeration

Medium
Category
Data Exfiltration
Confidence
60% confidence
Finding

Code scans file system directories looking for sensitive files. This could be reconnaissance for credential theft.

Content

Scanner excerpt · SKILL.md (reported line 79)May include surrounding context.

  1. 验证安装
    bash
    # 检查文件结构
    ls -la ~/.openclaw/workspace/skills/email-backup/
    
    # 应该看到:
    # SKILL.md
    

Ssd 3

Medium
Category
Not specified by scanner
Confidence
96% confidence
Finding

The documented workflow explicitly encourages packaging local OpenClaw directories such as agents and workspace contents and sending them via email, which creates a clear exfiltration path for potentially sensitive user data, credentials, prompts, logs, and project files. Even with an optional 'clean' flag, README-level guidance normalizes exporting large local state to an external mailbox, and incomplete sanitization can easily miss secrets.

Content

No source excerpt is available for this finding.

Undeclared Tool Scope

Medium
Category
MCP Least Privilege
Confidence
92% confidence
Finding

The skill declares no tool scope or permissions, yet its documented behavior requires reading directories, creating archives, writing files, accessing environment variables, and transmitting data over SMTP. This mismatch is dangerous because it prevents users and the platform from accurately understanding or constraining the skill's effective capabilities, increasing the chance of unintended data access or exfiltration.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
94% confidence
Finding

The description says the skill will package a directory and send it via QQ email, but it does not prominently warn that archive contents may include sensitive personal, credential, workspace, or system data. This raises privacy and exfiltration risk because users may treat 'backup' as routine without appreciating that full directory contents are being transmitted to an external email service.

Content

No source excerpt is available for this finding.

Ssd 3

Medium
Category
Not specified by scanner
Confidence
94% confidence
Finding

The examples explicitly encourage backing up agent and workspace directories, which commonly contain configuration, prompts, credentials, logs, session artifacts, and other sensitive data. In the context of an email-sending skill, this substantially increases the risk of privacy breaches or credential exposure because whole directories may be exfiltrated to external mail infrastructure.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The installation guidance asks users to install a skill whose stated purpose is to package files and send them to QQ Mail, but it does not prominently warn that this can exfiltrate local data to an external service. In a security-sensitive skill, omission of a data-transmission warning can mislead users into authorizing behavior with privacy and compliance consequences.

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 · openclaw-command.md (reported line 35)May include surrounding context.

bash
# 创建脚本目录
mkdir -p ~/.openclaw/scripts

# 创建安装脚本
cat > ~/.openclaw/scripts/install-email-backup.sh << 'EOF'

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 · openclaw-command.md (reported line 136)May include surrounding context.

md
fi
  
  # 创建目录
  mkdir -p ~/.openclaw/workspace/skills
  
  # 下载 Skill
  cd ~/.openclaw/workspace/skills

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
94% confidence
Finding

The document instructs users to configure a QQ Mail SMTP authorization code but does not clearly warn that this is a sensitive credential or that use of the skill sends data outside the host. This increases the risk of credential mishandling and unnoticed off-system transmission of potentially sensitive archives.

Content

No source excerpt is available for this finding.

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 · openclaw-command.md (reported line 196)May include surrounding context.

bash
# Ubuntu/Debian
sudo apt install -y python3

# CentOS/RHEL
sudo yum install -y python3

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 · openclaw-command.md (reported line 199)May include surrounding context.

bash
# Ubuntu/Debian
sudo apt install -y python3

# CentOS/RHEL
sudo yum install -y python3

Sudo/Root Execution

Medium
Category
Privilege Escalation
Confidence
78% confidence
Finding

Advising users to run sudo openclaw skill install email-backup elevates installation of a third-party skill to root, increasing the blast radius if the package or install hooks are unsafe. For a skill designed to package files and send them externally, privileged installation makes the context more dangerous because it can grant broad filesystem access and persistence opportunities.

Content

Scanner excerpt · openclaw-command.md (reported line 213)May include surrounding context.

问题 4:权限不足

bash
# 使用 sudo
sudo openclaw skill install email-backup

Sudo/Root Execution

Medium
Category
Privilege Escalation
Confidence
76% confidence
Finding

This is part of the same recommendation to use sudo for skill installation, which unnecessarily normalizes elevated execution for untrusted add-ons. Running install workflows as root can expose system-wide files and configuration to modification if the package is compromised or behaves unexpectedly.

Content

Scanner excerpt · openclaw-command.md (reported line 214)May include surrounding context.

bash
# 使用 sudo
sudo openclaw skill install email-backup

获取帮助

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 · openclaw-install-command.txt (reported line 10)May include surrounding context.

text
1. 检查 OpenClaw 是否安装:openclaw --version
2. 检查 Python 是否安装:python3 --version
3. 创建 skills 目录:mkdir -p ~/.openclaw/workspace/skills
4. 下载 Skill 文件:cd ~/.openclaw/workspace/skills && curl -L -o email-backup-skill.tar.gz https://example.com/email-backup-skill.tar.gz
5. 解压 Skill 文件:tar -xzf email-backup-skill.tar.gz
6. 设置执行权限:chmod +x ~/.openclaw/workspace/skills/email-backup/scripts/*.py

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 · openclaw-install-command.txt (reported line 10)May include surrounding context.

text
1. 检查 OpenClaw 是否安装:openclaw --version
2. 检查 Python 是否安装:python3 --version
3. 创建 skills 目录:mkdir -p ~/.openclaw/workspace/skills
4. 下载 Skill 文件:cd ~/.openclaw/workspace/skills && curl -L -o email-backup-skill.tar.gz https://example.com/email-backup-skill.tar.gz
5. 解压 Skill 文件:tar -xzf email-backup-skill.tar.gz
6. 设置执行权限:chmod +x ~/.openclaw/workspace/skills/email-backup/scripts/*.py

Vague Triggers

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The trigger phrase "安装 email-backup skill" is overly broad and can cause an agent to infer and perform a multi-step installation workflow without explicit, bounded user approval for downloading, unpacking, and preparing executable code. In an agent setting, underspecified install triggers increase the chance of unreviewed tool use or accidental installation of the wrong package.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
88% confidence
Finding

The file instructs users to place QQ email credentials in environment variables without warning about shell history, process environment leakage, or scope of exposure to child processes. While common, this handling can expose SMTP secrets to local users, logs, debugging tools, or other software running in the same session.

Content

No source excerpt is available for this finding.