Back to skill

Security audit

Baidu Search

Security checks for vulnerabilities and agentic risk

Overview

The skill performs Baidu web search as advertised, but it handles search queries and an API key in ways users should review before installing.

Install only if you are comfortable sending search terms to Baidu and storing a Baidu API key for this skill. Avoid searching for secrets, personal data, or confidential internal information, and protect ~/.openclaw/openclaw.json with restrictive permissions if you follow the documented setup.

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
scripts/search.py:35
Finding

Unredacted Search Queries Written to Standard Output

Content
View full analysis
Remediation
View remediation

T09 · Insecure Skill Coding Practices

Warning
Location
references/apikey-fetch.md:17
Finding

API Key Stored in a Plaintext Configuration File Without Permission Hardening

Content
View full analysis
Remediation
View remediation
Vulnerability Patterns
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Rogue AgentSelf-Modification, Session Persistence
  • MCP Least PrivilegeUnderdeclared Capability, Wildcard Permission, Missing Permission Declaration
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
Findings (8)

Undeclared Tool Scope

Medium
Category
MCP Least Privilege
Confidence
89% confidence
Finding

The skill invokes code with both network access and an API key dependency, but it does not declare any explicit tool scope or permissions boundary in the skill metadata. This creates a transparency and governance gap: an agent or user cannot easily determine or constrain what capabilities the skill may exercise, increasing the chance of unintended external requests or secret exposure through overly broad execution context.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The skill says it performs web search via Baidu, but it does not clearly warn users that submitted queries are transmitted to Baidu's external API. Users may enter sensitive internal data, credentials, or proprietary research terms under the assumption of local processing, causing inadvertent third-party disclosure.

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 · references/apikey-fetch.md (reported line 11)May include surrounding context.

md
Visit: **https://console.bce.baidu.com/ai-search/qianfan/ais/console/apiKey**

- Log in to your Baidu Cloud account
- Create an application or view existing API keys
- Copy your **API Key** (only API Key is needed)

### 2. Configure OpenClaw

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
94% confidence
Finding

The guide explicitly instructs users to place a live API key in plaintext within a local JSON file and does not mention file permission hardening, secret stores, or other secure handling practices. While this is common in developer tooling, it increases the chance of credential disclosure through backups, filesystem compromise, screenshots, shell history, or accidental inclusion in version control.

Content

No source excerpt is available for this finding.

External Transmission

Medium
Category
Data Exfiltration
Confidence
91% confidence
Finding

This code performs an outbound HTTP POST to a third-party service with user-controlled content. In the context of a web-search skill this is core functionality, but it still creates a genuine external transmission risk because entered queries leave the local trust boundary and may be stored or processed by the provider.

Content

Scanner excerpt · scripts/search.py (reported line 19)May include surrounding context.

python
}

    # 使用POST方法发送JSON数据
    response = requests.post(url, json=requestBody, headers=headers)
    response.raise_for_status()
    results = response.json()
    if "code" in results:

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
90% confidence
Finding

The skill sends the user-supplied query content to Baidu's external web search API, which is an external data disclosure boundary. In a search skill this behavior is expected, but it is still a real privacy/security concern because users may place sensitive data in queries and the file contains no disclosure, consent, or minimization around that transmission.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
72% confidence
Finding

The skill includes Chinese-only example queries and uses Chinese-language content throughout the examples, which can imply a fixed locale or language expectation. Because the file does not state that the skill is China-specific or explicitly allow other languages, this creates a mild natural-language locale policy concern.

Content

No source excerpt is available for this finding.

Missing User Warnings

Low
Category
Not specified by scanner
Confidence
95% confidence
Finding

The script logs the fully parsed request body to stdout, which can expose search terms and optional parameters in logs, terminal history, or orchestration systems. If users include sensitive information in queries, that data may be retained beyond the intended request path and become accessible to operators or other systems.

Content

No source excerpt is available for this finding.