Back to skill

Security audit

Technical Insight

Security checks for vulnerabilities and agentic risk

Overview

The skill mostly matches a technical analysis and diagramming purpose, but it includes unsafe local cleanup, broad credential loading, and under-scoped persistent outputs that should be reviewed before use.

Install only after reviewing the scripts and limiting permissions. Prefer passing TAVILY_API_KEY through a scoped environment variable, use an explicit output directory, avoid untrusted repository URLs until the /tmp deletion logic is fixed, and treat generated PlantUML/draw.io files from untrusted repos as untrusted content.

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
code-analysis-module.py:12
Finding

Predictable temporary path permits destructive recursive deletion

Content
View full analysis
Remediation
View remediation

T09 · Insecure Skill Coding Practices

Warning
Location
tavily-config.sh:7
Finding

Global environment file is executed as shell code to obtain one API key

Content
View full analysis
~/.openclaw/.env" exit 1 fi # Source the global configuration source "$HOME/.openclaw/.env" # Verify TAVILY_API_KEY is set if [ -z "$TAVILY_API_KEY" ]; then echo "Error: TAVILY_API_KEY not found in ~/.openclaw/.env" exit 1 fi ``` ### Technical Analysis The Skill only requires `TAVILY_API_KEY`, but it uses the Bash `source` command on the entire global OpenClaw environment file. `source` does not parse the file as passive key-value data; it executes all valid shell syntax in the current shell process. Consequently, command substitutions, function calls, redirections, and arbitrary commands placed in the environment file execute with the privileges of the account running the Skill. Sourcing the shared file also imports unrelated secrets and configuration values into the process, exceeding the minimum access required for Tavily integration. The audited script does not print or transmit the API key itself. The vulnerability is the unnecessary evaluation of a shared credential file and exposure to every variable stored in it. ### Attack Path 1. Another user, process, or compromised component capable of modifying `~/.openclaw/.env` inserts shell syntax into the file. 2. The Skill executes `tavily-config.sh`. 3. The script invokes `source "$HOME/.openclaw/.env"`. 4. The inserted shell commands execute in the context of the Skill process. 5. Those commands receive the filesystem and environment access available to the current account. ### Impact Assessment Exploitation permits arbi ...[truncated 424 chars]
Remediation
View remediation
`. A safer implementation can validate an existing environment variable without reading the global file: ```bash #!/bin/bash set -euo pipefail if [ -z "${TAVILY_API_KEY:-}" ]; then echo "Error: TAVILY_API_KEY is not set" >&2 exit 1 fi echo "Technical-insight skill is configured to use Tavily" ``` ]]>

T09 · Insecure Skill Coding Practices

Warning
Location
architecture-diagram-generator.py:27
Finding

Repository-controlled names are embedded into diagram languages without escaping

Content
View full analysis
1: group = parts[0] if group not in component_groups: component_groups[group] = [] component_groups[group].append(comp) else: if 'root' not in component_groups: component_groups['root'] = [] component_groups['root'].append(comp) # Create packages for each group for group_name, group_components in component_groups.items(): plantuml_content += f"package \"{group_name}\" {{\n" for comp in group_components[:5]: # Limit to first 5 components per group comp_name = comp['file_path'].replace('/', '_').replace('.', '_') plantuml_content += f" [**{comp_name}**\\n{comp['language']}\\n{comp['lines_of_code']} LOC]\n" if len(group_components) > 5: plantuml_content += f" note right: {len(group_components) - 5} more components...\n" plantuml_content += "}\n\n" ``` Repository metadata is also inserted into the topology and processed by an external PlantUML executable: ```python # Main application node plantuml_content += f"node \"{repo_info.get('name', 'Application')}\" <> {{\n" # Save and render diagram self._render_diagram(plantuml_content, 'architecture.png') ``` ```python # Save PlantUML file with open(diagram_path, 'w') as f: f.write(plantuml_content) # Render to PNG using plantuml command try: subprocess.run(['plantuml', '-tpng', ...[truncated 3286 chars]
Remediation
View remediation
`, `&`, backslashes, and newline characters. - Validate generated XML with a strict parser before saving or presenting the diagram. ]]>
Vulnerability Patterns
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
  • Supply ChainUnpinned Dependencies, External Script Fetching, Obfuscated Code
  • MCP Tool PoisoningHidden Instructions, Unicode Deception, Parameter Description Injection
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
Findings (77)

Tp4

High
Category
MCP Tool Poisoning
Confidence
95% confidence
Finding

The skill references configuration management for external API credentials and sourcing a global environment file from the user's home directory, which is materially more sensitive than ordinary analysis behavior. Accessing home-directory environment files can expose secrets and couples the skill to privileged local context without clear user disclosure or isolation.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
98% confidence
Finding

The skill references configuration management for external API credentials and sourcing a global environment file from the user's home directory, which is materially more sensitive than ordinary analysis behavior. Accessing home-directory environment files can expose secrets and couples the skill to privileged local context without clear user disclosure or isolation.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
95% confidence
Finding

The skill references configuration management for external API credentials and sourcing a global environment file from the user's home directory, which is materially more sensitive than ordinary analysis behavior. Accessing home-directory environment files can expose secrets and couples the skill to privileged local context without clear user disclosure or isolation.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
95% confidence
Finding

The skill references configuration management for external API credentials and sourcing a global environment file from the user's home directory, which is materially more sensitive than ordinary analysis behavior. Accessing home-directory environment files can expose secrets and couples the skill to privileged local context without clear user disclosure or isolation.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
98% confidence
Finding

The skill references configuration management for external API credentials and sourcing a global environment file from the user's home directory, which is materially more sensitive than ordinary analysis behavior. Accessing home-directory environment files can expose secrets and couples the skill to privileged local context without clear user disclosure or isolation.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
95% confidence
Finding

The skill references configuration management for external API credentials and sourcing a global environment file from the user's home directory, which is materially more sensitive than ordinary analysis behavior. Accessing home-directory environment files can expose secrets and couples the skill to privileged local context without clear user disclosure or isolation.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
98% confidence
Finding

The skill references configuration management for external API credentials and sourcing a global environment file from the user's home directory, which is materially more sensitive than ordinary analysis behavior. Accessing home-directory environment files can expose secrets and couples the skill to privileged local context without clear user disclosure or isolation.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
98% confidence
Finding

The skill references configuration management for external API credentials and sourcing a global environment file from the user's home directory, which is materially more sensitive than ordinary analysis behavior. Accessing home-directory environment files can expose secrets and couples the skill to privileged local context without clear user disclosure or isolation.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
98% confidence
Finding

The skill references configuration management for external API credentials and sourcing a global environment file from the user's home directory, which is materially more sensitive than ordinary analysis behavior. Accessing home-directory environment files can expose secrets and couples the skill to privileged local context without clear user disclosure or isolation.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
98% confidence
Finding

The skill references configuration management for external API credentials and sourcing a global environment file from the user's home directory, which is materially more sensitive than ordinary analysis behavior. Accessing home-directory environment files can expose secrets and couples the skill to privileged local context without clear user disclosure or isolation.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
99% confidence
Finding

The skill references configuration management for external API credentials and sourcing a global environment file from the user's home directory, which is materially more sensitive than ordinary analysis behavior. Accessing home-directory environment files can expose secrets and couples the skill to privileged local context without clear user disclosure or isolation.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
98% confidence
Finding

The skill references configuration management for external API credentials and sourcing a global environment file from the user's home directory, which is materially more sensitive than ordinary analysis behavior. Accessing home-directory environment files can expose secrets and couples the skill to privileged local context without clear user disclosure or isolation.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
95% confidence
Finding

The skill references configuration management for external API credentials and sourcing a global environment file from the user's home directory, which is materially more sensitive than ordinary analysis behavior. Accessing home-directory environment files can expose secrets and couples the skill to privileged local context without clear user disclosure or isolation.

Content

No source excerpt is available for this finding.

Description-Behavior Mismatch

High
Category
Not specified by scanner
Confidence
98% confidence
Finding

The manifest describes a skill for deep technical teardown, mechanism analysis, moat identification, risk assessment, evolution prediction, and report generation. This file instead only checks for a fixed set of draw.io filenames and writes placeholder PNG images with canned architecture text, which is a different operational purpose from performing technical insight analysis.

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 · tavily-config.sh (reported line 3)May include surrounding context.

sh
#!/bin/bash
# Unified Tavily configuration for technical-insight skill
# Uses the global ~/.openclaw/.env configuration

set -e

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 · tavily-config.sh (reported line 7)May include surrounding context.

sh
#!/bin/bash
# Unified Tavily configuration for technical-insight skill
# Uses the global ~/.openclaw/.env configuration

set -e

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 · tavily-config.sh (reported line 8)May include surrounding context.

sh
set -e

# Check if global .env file exists
if [ ! -f "$HOME/.openclaw/.env" ]; then
    echo "Error: Global Tavily configuration not found at ~/.openclaw/.env"
    echo "Please configure your Tavily API key using:"
    echo "echo 'TAVILY_API_KEY=your_api_key_here' > ~/.openclaw/.env"

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 · tavily-config.sh (reported line 9)May include surrounding context.

sh
set -e

# Check if global .env file exists
if [ ! -f "$HOME/.openclaw/.env" ]; then
    echo "Error: Global Tavily configuration not found at ~/.openclaw/.env"
    echo "Please configure your Tavily API key using:"
    echo "echo 'TAVILY_API_KEY=your_api_key_here' > ~/.openclaw/.env"

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 · tavily-config.sh (reported line 11)May include surrounding context.

sh
set -e

# Check if global .env file exists
if [ ! -f "$HOME/.openclaw/.env" ]; then
    echo "Error: Global Tavily configuration not found at ~/.openclaw/.env"
    echo "Please configure your Tavily API key using:"
    echo "echo 'TAVILY_API_KEY=your_api_key_here' > ~/.openclaw/.env"

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 · tavily-config.sh (reported line 20)May include surrounding context.

sh
set -e

# Check if global .env file exists
if [ ! -f "$HOME/.openclaw/.env" ]; then
    echo "Error: Global Tavily configuration not found at ~/.openclaw/.env"
    echo "Please configure your Tavily API key using:"
    echo "echo 'TAVILY_API_KEY=your_api_key_here' > ~/.openclaw/.env"

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 · tavily-config.sh (reported line 25)May include surrounding context.

sh
set -e

# Check if global .env file exists
if [ ! -f "$HOME/.openclaw/.env" ]; then
    echo "Error: Global Tavily configuration not found at ~/.openclaw/.env"
    echo "Please configure your Tavily API key using:"
    echo "echo 'TAVILY_API_KEY=your_api_key_here' > ~/.openclaw/.env"

Credential Access

High
Category
Privilege Escalation
Confidence
98% confidence
Finding

The script uses 'source' on ~/.openclaw/.env, which not only reads credentials but executes any shell code present in that file. That creates both credential exposure risk and code-execution risk if the file is modified, misplaced, or contains unexpected content; in this skill context, accessing global user secrets is more dangerous because the manifest does not justify broad credential access.

Content

Scanner excerpt · tavily-config.sh (reported line 16)May include surrounding context.

sh
fi

# Source the global configuration
source "$HOME/.openclaw/.env"

# Verify TAVILY_API_KEY is set
if [ -z "$TAVILY_API_KEY" ]; then

Rp1

Medium
Category
MCP Rug Pull
Confidence
91% confidence
Finding

The document instructs users to run npx clawdhub publish without pinning an exact package version. npx may fetch the latest package from the registry at execution time, which creates a supply-chain risk: a malicious, compromised, or breaking upstream release could execute arbitrary code on the user's machine during publish. Because this is a release/preparation document, readers are reasonably likely to copy-paste the command, making the issue more operationally dangerous.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
93% confidence
Finding

The plan explicitly defines writing multiple artifacts under ~/.openclaw/workspace/tech-insight/deep-dive/{技术名称}/ in the user's home directory, but does not mention user consent, visibility, overwrite behavior, or data retention. Silent filesystem writes are risky because they can persist sensitive analysis results, consume disk space, and surprise users with local side effects beyond the immediate chat interaction.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The skill plans to use Tavily API, GitHub, community sites, and source analysis without warning that user-supplied technology targets or related content may be sent to third-party services. This can leak sensitive project names, internal repositories, or proprietary analysis targets, especially if the skill is later used on non-public technologies or codebases.

Content

No source excerpt is available for this finding.