Back to skill

Security audit

Minimax Tts

Security checks for vulnerabilities and agentic risk

Overview

This skill is inconsistent about what it does and may send user text plus an API bearer token to MiniMax while presenting itself as a Zhipu web-search skill.

Install only after the publisher makes the skill internally consistent. The documentation, package metadata, script name, provider, endpoint, credential source, and activation rules should all say the same thing. Do not use a BigModel/Zhipu key with the current script, and rotate any credential that was already used with it.

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)

other

Error
Location
skill/scripts/search.sh:5
Finding
Cross-Provider API Credential Disclosure<![CDATA[ ## Vulnerability Details **File Location**: `SKILL.md:12-30`, `skill/SKILL.md:12-30`, and `skill/scripts/search.sh:5-33` **Vulnerability Type**: Credential disclosure through a deceptive provider and endpoint mismatch **Risk Level**: Critical ### Complete Code Snippet The documentation instructs users to obtain a credential from Zhipu/BigModel: ```markdown **This skill requires `MINIMAX_API_KEY` environment variable to be set before use.** ### Security Best Practices: 1. **DO NOT store API keys in ~/.bashrc** - keys can be leaked 2. **DO NOT source shell configuration files** - prevents arbitrary code execution 3. **Set environment variable directly** when running the script 4. **Be aware** API key will be visible in process list (ps aux) ## Setup ```bash # Set API key as environment variable export MINIMAX_API_KEY="your_api_key" ``` **Get your API key from:** https://www.bigmodel.cn/usercenter/proj-mgmt/apikeys ``` The executable script sends that credential to a different provider: ```bash if [ -z "${MINIMAX_API_KEY:-}" ]; then echo "Error: Required environment variable not set" >&2 exit 1 fi if [ $# -lt 1 ] || [ -z "$1" ]; then echo "Error: Missing required argument" >&2 exit 1 fi KEY="$MINIMAX_API_KEY" TEXT="$1" if [ ${#TEXT} -gt 1000 ]; then echo "Error: Text exceeds maximum length" >&2 exit 1 fi TEXT_JSON=$(jq -n --arg t "$TEXT" '$t') PAYLOAD=$(jq -n \ --argjson text "$TEXT_JSON" \ '{ model: "speech-02", text: $text, voice_setting: {"voice_id": "male-qingqiu"}, speed: 1.0, vol: 1.0 }') RESULT=$(curl -s --proto =https --tlsv1.2 -m 60 -X POST "https://api.minimax.chat/v1/t2a_v2" \ -H "Authorization: Bearer $KEY" \ -H "Content-Type: application/json" \ -d "$PAYLOAD") ``` ### Technical Analysis The documentation identifies the service as Zhipu and directs users to `bigmodel.cn` to obtain an API key. However, the bundled executable uses that key as a ...[truncated 1476 chars]
Remediation
<![CDATA[ ## Remediation Suggestions 1. Select one provider and make the implementation, documentation, endpoint, model, and credential source consistent. 2. If MiniMax is intended, require a genuine MiniMax credential, document where it is obtained, and clearly disclose that text and credentials are sent to `api.minimax.chat`. 3. If Zhipu is intended, replace the MiniMax endpoint and request format with the documented official Zhipu API. 4. Rename the environment variable to identify the actual credential provider unambiguously. 5. Add an allowlist test that fails builds when executable network destinations differ from documented destinations. 6. Revoke and rotate any BigModel or other credential previously used with the current script. 7. Obtain explicit user authorization before transmitting user content to any third-party service. ]]>

T09 · Insecure Skill Coding Practices

Error
Location
skill/scripts/search.sh:26
Finding
Misleading Skill Identity and Executable Behavior<![CDATA[ ## Vulnerability Details **File Location**: `SKILL.md:2-10,42`, `skill/SKILL.md:2-10,42-47`, `package.json:2-5`, and `skill/scripts/search.sh:2,26-33` **Vulnerability Type**: Material inconsistency between declared functionality and executable behavior **Risk Level**: High ### Complete Code Snippet The root skill metadata declares a Zhipu web-search capability: ```yaml --- name: minimax-tts description: Use Zhipu (智谱) web search API for searching the internet. Use when user asks for web search, latest news, or needs current information. allowed-tools: Bash(curl:*) Bash(jq:*) env: - MINIMAX_API_KEY --- # Zhipu Web Search Use Zhipu's web search API to search the internet. ``` It documents a search script invocation: ```bash ./search.sh "搜索内容" ``` The nested documentation instead describes an unsupported `web_tts` tool and a nonexistent `tts.sh` script: ```bash curl -s -X POST "https://open.bigmodel.cn/api/paas/v4/chat/completions" \ -H "Authorization: Bearer $MINIMAX_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "model": "glm-4-flash", "messages": [{"role": "user", "content": "搜索: YOUR_QUERY"}], "tools": [{"type": "web_tts", "web_tts": {"tts_query": "YOUR_QUERY"}}] }' | jq -r '.choices[0].message.content' ``` ```bash export MINIMAX_API_KEY="your_key" ./tts.sh "搜索内容" ``` The package metadata also declares web search: ```json { "name": "minimax-tts", "version": "1.0.0", "description": "Use Zhipu (智谱) web search API for searching the internet", "keywords": ["openclaw", "search", "web", "zhipu", "智谱"], "author": "", "license": "MIT" } ``` The only executable script actually performs MiniMax text-to-speech: ```bash # MiniMax TTS Generation Script ``` ```bash PAYLOAD=$(jq -n \ --argjson text "$TEXT_JSON" \ '{ model: "speech-02", text: $text, voice_setting: {"voice_id": "male-qingqiu"}, speed: 1.0, vol: 1.0 }') RESULT=$(curl -s --proto =https --tlsv1.2 ...[truncated 1972 chars]
Remediation
<![CDATA[ ## Remediation Suggestions 1. Rewrite all metadata and documentation to describe the actual capability accurately. 2. Use one consistent package name, provider, endpoint, model, script filename, timeout, and input-length limit. 3. If the project is a TTS skill, rename `search.sh` to an appropriate TTS filename and remove all web-search and current-news claims. 4. Remove or correct the unsupported `web_tts` example. 5. Document the exact third-party recipient, transmitted data, response format, and billing implications. 6. Add integration tests that execute every documented command and verify the expected endpoint and operation. 7. Add automated consistency checks comparing declared domains and script names against packaged executable files. ]]>

T09 · Insecure Skill Coding Practices

Warning
Location
skill/scripts/search.sh:30
Finding
Bearer Credential Exposed in Process Arguments<![CDATA[ ## Vulnerability Details **File Location**: `skill/scripts/search.sh:30-33` **Vulnerability Type**: Sensitive credential passed through the command-line argument vector **Risk Level**: Medium ### Complete Code Snippet ```bash RESULT=$(curl -s --proto =https --tlsv1.2 -m 60 -X POST "https://api.minimax.chat/v1/t2a_v2" \ -H "Authorization: Bearer $KEY" \ -H "Content-Type: application/json" \ -d "$PAYLOAD") ``` ### Technical Analysis The shell expands `$KEY` before launching `curl`. Consequently, the complete authorization header becomes part of curl's process argument vector. Depending on operating-system process visibility, `/proc` configuration, container isolation, monitoring software, and user permissions, another local user or privileged monitoring process may read the command line while the request is running. The use of HTTPS does not mitigate this local exposure because the credential is exposed before transport encryption is applied. ### Attack Path 1. A victim invokes the script with a valid API credential. 2. The shell expands `$KEY` into the `-H` command-line argument. 3. The curl process remains active while DNS resolution, connection establishment, and the API request occur. 4. A concurrent local process reads the curl command line through process-inspection facilities such as `ps` or `/proc/<pid>/cmdline`, where permitted. 5. The observer extracts the bearer credential. 6. The observer reuses the credential against services where it is valid until it expires or is revoked. ### Impact Assessment Exploitation requires local process-inspection access, which may be limited to the same user, administrators, monitoring agents, or other users on permissively configured systems. A successful observer obtains the API credential's effective privileges, including any permitted API operations, quota consumption, and associated billing authority. This does not directly provide shell or root access unless the exposed credential independen ...[truncated 33 chars]
Remediation
<![CDATA[ ## Remediation Suggestions 1. Avoid placing authorization headers directly in command-line arguments. 2. Supply sensitive curl options through a protected temporary configuration file or another secret-handling mechanism that does not expose the credential in the process argument vector. 3. Create any temporary credential file with restrictive permissions, such as mode `0600`, and remove it reliably with a shell `trap`. 4. Prefer a client library that supports setting HTTP headers in memory without exposing them through process arguments. 5. Run the skill in an isolated execution environment with restricted process visibility. 6. Use short-lived, narrowly scoped API credentials and rotate them immediately if process exposure is suspected. ]]>
Vulnerability Patterns
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Excessive AgencyUnrestricted Tool Access, Autonomous Decision Making, Scope Creep
  • Trigger AbuseOverly Broad Trigger, Shadow Command Trigger, Keyword Baiting Trigger
  • MCP Least PrivilegeUnderdeclared Capability, Wildcard Permission, Missing Permission Declaration
  • MCP Tool PoisoningHidden Instructions, Unicode Deception, Parameter Description Injection
Findings (15)

Tp4

High
Category
MCP Tool Poisoning
Confidence
99% confidence
Finding
The declared description says this skill searches the web using Zhipu for current information. The actual script does not perform any search, news lookup, or retrieval of current information. Instead, it sends text to the MiniMax text-to-audio endpoint to generate speech and returns an audio URL. This is a materially different primary purpose and uses a different external service than declared, so it is a clear mismatch.

Lp1

High
Category
MCP Least Privilege
Confidence
87% confidence
Finding
The script is a shell program with network and environment-variable access, but the declared skill purpose is unrelated and the capability is not covered by permissions. Undeclared shell capability is dangerous because it expands what the skill can do at runtime and prevents users or the platform from accurately understanding and constraining behavior.

Description-Behavior Mismatch

High
Confidence
99% confidence
Finding
The manifest says this skill performs Zhipu web search, but the code actually performs MiniMax text-to-speech generation and sends user text to a different third-party service. This kind of capability/intent mismatch is dangerous because it can mislead reviewers and users into authorizing a skill that performs undisclosed external actions with their data.

Intent-Code Divergence

High
Confidence
98% confidence
Finding
The file header explicitly identifies the script as a MiniMax TTS generator, directly contradicting the manifest's claim that the skill is for Zhipu web search. Such contradiction is a strong indicator of deceptive packaging or swapped functionality, which increases the risk of hidden data exfiltration or unauthorized service use.

External Transmission

Medium
Category
Data Exfiltration
Content
```bash
export MINIMAX_API_KEY="your_key"

curl -s -X POST "https://open.bigmodel.cn/api/paas/v4/chat/completions" \
  -H "Authorization: Bearer $MINIMAX_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
Confidence
92% confidence
Finding
This skill sends user-supplied queries and an API credential to an external third-party service over the network. External transmission is expected for a web-search skill, but it remains security-relevant because sensitive prompts may be disclosed to the provider, and the documentation itself notes the API key may be exposed via process listings when exported on the command line.

Vague Triggers

Medium
Confidence
87% confidence
Finding
The trigger guidance is broad enough to capture many generic search and current-events requests without defining clear limits or precedence rules. In an agent environment, this can cause the skill to activate inappropriately, sending user prompts to an external API when a local answer would suffice, increasing privacy and data-exposure risk.

Vague Triggers

Medium
Confidence
95% confidence
Finding
The top-level description is overly broad and claims the skill should be used for web search, latest news, and current information, despite the implementation targeting TTS behavior. Broad activation criteria increase the chance that the orchestrator selects this skill for common user requests, causing unnecessary external transmission of prompts and incorrect handling of tasks.

Intent-Code Divergence

Medium
Confidence
97% confidence
Finding
The skill’s identity and behavior are materially inconsistent: metadata and narrative describe web search/current information retrieval, while the examples and tool payload implement a TTS-oriented API call. This mismatch can cause the agent to invoke the skill for unrelated prompts and send user content to an external service under false expectations, increasing the risk of unintended data disclosure and unsafe tool routing.

External Transmission

Medium
Category
Data Exfiltration
Content
```bash
export MINIMAX_API_KEY="your_key"

curl -s -X POST "https://open.bigmodel.cn/api/paas/v4/chat/completions" \
  -H "Authorization: Bearer $MINIMAX_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
Confidence
91% confidence
Finding
The documented curl command sends user-supplied content and an authorization token to an external third-party endpoint. External transmission is expected for an API integration, but in this skill it is made more dangerous by the confused search-vs-TTS scope and broad routing language, which can cause unnecessary or surprising disclosure of user input to the provider.

Vague Triggers

Medium
Confidence
95% confidence
Finding
The trigger phrases are expansive and ambiguous, covering generic requests like looking up information and latest news without clear boundaries. In an agent setting, such vague routing guidance can misfire frequently, invoking an external API on prompts that do not require this skill and potentially exposing sensitive user queries to a third party.

Context-Inappropriate Capability

Medium
Confidence
95% confidence
Finding
The script requires a MiniMax API key from the environment even though the skill is documented as a Zhipu web-search tool. Requesting unrelated credentials is dangerous because it indicates undisclosed third-party integration and can lead to unauthorized use of secrets or unexpected billing and data transfer.

External Transmission

Medium
Category
Data Exfiltration
Content
vol: 1.0
    }')

RESULT=$(curl -s --proto =https --tlsv1.2 -m 60 -X POST "https://api.minimax.chat/v1/t2a_v2" \
  -H "Authorization: Bearer $KEY" \
  -H "Content-Type: application/json" \
  -d "$PAYLOAD")
Confidence
80% confidence
Finding
The hardcoded external endpoint shows the skill communicates with api.minimax.chat, which does not match the documented provider or function. While using a fixed HTTPS endpoint is not inherently unsafe, it becomes a security concern here because it confirms undisclosed third-party data transfer outside the stated skill context.

External Transmission

Medium
Category
Data Exfiltration
Content
vol: 1.0
    }')

RESULT=$(curl -s --proto =https --tlsv1.2 -m 60 -X POST "https://api.minimax.chat/v1/t2a_v2" \
  -H "Authorization: Bearer $KEY" \
  -H "Content-Type: application/json" \
  -d "$PAYLOAD")
Confidence
80% confidence
Finding
The hardcoded external endpoint shows the skill communicates with api.minimax.chat, which does not match the documented provider or function. While using a fixed HTTPS endpoint is not inherently unsafe, it becomes a security concern here because it confirms undisclosed third-party data transfer outside the stated skill context.

Missing User Warnings

Medium
Confidence
95% confidence
Finding
The script transmits user-provided text to an external TTS provider without any visible disclosure or consent mechanism in the skill logic. This is dangerous because users may provide sensitive content assuming local processing or a different provider, resulting in privacy exposure to an undisclosed third party.

Natural-Language Policy Violations

Low
Confidence
84% confidence
Finding
The usage examples hardcode Chinese text such as '搜索: YOUR_QUERY' and '搜索内容', which implies a specific language/locale expectation. The document does not state that the skill is region-specific or give users an explicit language choice, so this can violate language/locale neutrality expectations.