Back to skill

Security audit

baidu-maps-poi-ai-search

Security checks for vulnerabilities and agentic risk

Overview

The skill mostly does the advertised Baidu Maps search, but its script can expose the Baidu API key and private search terms in logs.

Review before installing. Use only a restricted Baidu Maps API key, prefer BAIDU_AK over passing keys in JSON, avoid sensitive location queries, and remove or redact the stderr request logging before using this in shared terminals, CI, or agent environments.

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

T09 · Insecure Skill Coding Practices

Warning
Location
scripts/search.py:109
Finding

API Key Exposure Through Command-Line Input and Request Logging

Content
View full analysis
Remediation
View remediation
Vulnerability Patterns
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • MCP Least PrivilegeUnderdeclared Capability, Wildcard Permission, Missing Permission Declaration
  • MCP Tool PoisoningHidden Instructions, Unicode Deception, Parameter Description Injection
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
Findings (8)

Tp4

High
Category
MCP Tool Poisoning
Confidence
91% confidence
Finding

The code clearly matches part of the description: it searches for places/POIs via Baidu Maps and can include richer result fields when scope=2. However, the declared description explicitly says it can also retrieve detailed POI information by UID. No such UID lookup endpoint or function exists in the supplied code; UID only appears as a field in search results. Therefore the description overstates the implemented functionality. There are no obvious undeclared harmful capabilities, but there is a material mismatch because one of the core declared features is absent.

Content

No source excerpt is available for this finding.

Undeclared Tool Scope

Medium
Category
MCP Least Privilege
Confidence
92% confidence
Finding

The skill requires environment access to BAIDU_AK and performs network requests, but it does not declare an explicit tool scope such as permissions or allowed-tools. This weakens sandboxing and reviewability because consumers cannot clearly see that the skill will access secrets and transmit data externally, increasing the chance of unintended secret exposure or overly broad execution privileges.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
91% confidence
Finding

The natural-language documentation and usage guidance are presented in Chinese, but the file does not indicate that this locale is optional or that users can choose another language. Under the policy, forcing a specific language without user opt-in is a natural-language policy concern.

Content

No source excerpt is available for this finding.

External Transmission

Medium
Category
Data Exfiltration
Confidence
84% confidence
Finding

The skill is designed to send user-supplied queries and use an API key to an external Baidu Maps endpoint. External transmission is expected for this skill's purpose, but it remains security-relevant because potentially sensitive location queries and secret-backed requests leave the local environment and go to a third party.

Content

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

text

## API 文档
- 多维检索:`https://api.map.baidu.com/api_place_pro/v1/region`

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
83% confidence
Finding

The file presents itself entirely as a Baidu Maps search script in Chinese and its documented API usage is tied to Chinese-language behavior, while not offering any user-facing language/locale choice. Under the policy rule, forcing a specific language or locale without opt-in is a natural-language policy concern unless clearly justified as region-specific.

Content

No source excerpt is available for this finding.

External Transmission

Medium
Category
Data Exfiltration
Confidence
60% confidence
Finding

Data is being sent to an external URL. This could be legitimate telemetry or data exfiltration. Manual review is recommended.

Content

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

python
#!/usr/bin/env python3
"""
Baidu Maps Place Search - 多维检索 API
Docs: https://api.map.baidu.com/place/v3/multidimensional
"""

import sys

External Transmission

Medium
Category
Data Exfiltration
Confidence
60% confidence
Finding

Data is being sent to an external URL. This could be legitimate telemetry or data exfiltration. Manual review is recommended.

Content

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

python
#!/usr/bin/env python3
"""
Baidu Maps Place Search - 多维检索 API
Docs: https://api.map.baidu.com/place/v3/multidimensional
"""

import sys

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
98% confidence
Finding

The script logs the full parsed request body to stderr, which can include sensitive user queries and the 'ak' API key. In agent, server, or CI environments, stderr is often collected centrally, so this can leak credentials and potentially sensitive location/search data to operators, logs, or downstream systems.

Content

No source excerpt is available for this finding.