Back to skill

Security audit

DingTalk Channel Install

Security checks for vulnerabilities and agentic risk

Overview

The skill does what it says, but its default setup exposes the OpenClaw agent broadly over DingTalk and stores credentials without enough safeguards.

Review before installing. Use an explicit DingTalk allowlist instead of allowFrom ["*"], restrict DM and group policies where possible, pin the @soimy/dingtalk plugin version, and protect or rotate the DingTalk client secret if it has been entered on a command line or stored in a broadly readable OpenClaw config file.

Vulnerability Patterns
  • Unauthorized Access and Privilege EscalationObtains permissions beyond the task's legitimate needs
  • Insecure DependenciesIntroduces malicious components through unsafe dependency sources
  • 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
Findings (3)

T08 · Insecure Dependencies

Error
Location
scripts/install_dingtalk.py:145
Finding

Unpinned Third-Party Plugin Installation Creates a Supply-Chain Risk

Content
View full analysis
Remediation
View remediation
"] ``` 2. Where supported, verify the package against a trusted integrity hash or signed provenance record before activation. 3. Use an organization-controlled lockfile or approved dependency manifest. 4. Restrict installation to an explicitly trusted registry and reject unexpected registry overrides. 5. Review each version update before changing the pinned version. 6. Install and test the plugin in a restricted environment before enabling it in a production gateway. 7. Run OpenClaw under a dedicated least-privilege service account to reduce the impact of a compromised plugin. ]]>

T05 · Unauthorized Access and Privilege Escalation

Error
Location
scripts/install_dingtalk.py:59
Finding

DingTalk Channel Is Configured to Accept Messages from Every Sender

Content
View full analysis
Remediation
View remediation

T09 · Insecure Skill Coding Practices

Warning
Location
scripts/install_dingtalk.py:98
Finding

Client Secret Is Accepted Through the Command Line and Stored Without Permission Hardening

Content
View full analysis
\ --client-secret <你的 Client Secret> ``` ### Technical Analysis Command-line secrets can be retained in shell history and may be visible through process-inspection mechanisms while the command is running, depending on operating-system and account isolation rules. The script also stores `clientSecret` directly in the JSON configuration. While application credentials may need persistent storage for gateway operation, the script neither verifies that the existing file is owner-only nor applies restrictive permissions after writing it. Python's `open(..., "w")` preserves the permission mode of an existing file, so an already over-permissive OpenClaw configuration remains over-permissive. The scrip ...[truncated 1558 chars]
Remediation
View remediation
Vulnerability Patterns
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Excessive AgencyUnrestricted Tool Access, Autonomous Decision Making, Scope Creep
  • Behavioral ASTexec() Call, eval() Call, Dynamic Import
  • MCP Least PrivilegeUnderdeclared Capability, Wildcard Permission, Missing Permission Declaration
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
Findings (7)

Undeclared Tool Scope

Medium
Category
MCP Least Privilege
Confidence
88% confidence
Finding

The skill instructs users to run shell commands and a Python installer that will read and write configuration files, but it does not declare any tool scope such as permissions or allowed-tools. This weakens reviewability and containment because an agent or user cannot easily tell up front that the skill requires shell execution and config file modification.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The sample configuration sets allowFrom: ["*"], which permits messages from all sources, but the skill does not clearly warn that this broadens who can interact with the DingTalk channel. In a messaging gateway context, this can expose the bot to unsolicited or unauthorized conversations, increasing the risk of abuse, data exposure, or unintended command execution through the channel.

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 user-facing documentation and console messages are written in Chinese only, which imposes a specific language on all users without offering opt-in or alternative locale support. The file does not document that this tool is intentionally limited to a Chinese-speaking or region-specific audience.

Content

No source excerpt is available for this finding.

subprocess module call

Medium
Category
Dangerous Code Execution
Confidence
70% confidence
Finding

subprocess module calls execute external commands. Without careful input validation, this enables command injection.

Content

Scanner excerpt · scripts/install_dingtalk.py (reported line 31)May include surrounding context.

python
# 将命令字符串转换为列表形式以避免 shell 注入
    if isinstance(cmd, str):
        cmd = cmd.split()
    result = subprocess.run(cmd, capture_output=True, text=True)
    if result.returncode != 0:
        print(f"❌ 失败:{result.stderr}")
        return False

Context-Inappropriate Capability

Medium
Category
Not specified by scanner
Confidence
97% confidence
Finding

The script configures allowFrom as ['*'], which permits messages from any DingTalk sender instead of restricting access to expected users, groups, or tenants. In the context of an agent channel installation tool, this broadens the exposed attack surface and can allow unauthorized parties to interact with the agent, potentially triggering sensitive actions or data exposure through the connected system.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
94% confidence
Finding

The script stores the DingTalk client ID and client secret directly in a JSON config file without any warning, permission tightening, or safer secret-handling path. If the file is readable by other local users, checked into version control, included in backups, or exposed through support tooling, the credentials could be recovered and abused to impersonate or access the DingTalk integration.

Content

No source excerpt is available for this finding.

subprocess module call

Medium
Category
Dangerous Code Execution
Confidence
70% confidence
Finding

subprocess module calls execute external commands. Without careful input validation, this enables command injection.

Content

Scanner excerpt · scripts/install_dingtalk.py (reported line 106)May include surrounding context.

python
def restart_gateway():
    """重启 Gateway"""
    print("\n🔄 重启 Gateway...")
    result = subprocess.run(
        ["openclaw", "gateway", "restart"],
        capture_output=True,
        text=True