Back to skill

Security audit

mimotts25-plus (TTS增强版)

Security checks for vulnerabilities and agentic risk

Overview

This MiMo TTS skill mostly does what it says, but it can send API keys, text, and voice-clone samples to an arbitrary configured endpoint, so users should review it before installing.

Install only if you are comfortable sending text, style context, and any chosen voice-clone recordings to MiMo or the configured API endpoint. Avoid setting MIMO_API_BASE or --base-url to untrusted hosts, do not use http:// endpoints, and only upload voice samples you own or are authorized to use.

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/tts.py:151
Finding

Unrestricted API Endpoint Override Can Disclose API Credentials and Voice Samples

Content
View full analysis
bytes: data = json.dumps(payload).encode() req = urllib.request.Request( f"{API_BASE}/chat/completions", data=data, headers={"Content-Type": "application/json", "api-key": api_key}, method="POST", ) ``` Clone mode reads and Base64-encodes the user-selected voice sample: ```python def _read_clone_audio(path: str) -> Tuple[str, str]: if not os.path.exists(path): raise TtsError(f"音频文件不存在: {path}") suffix = os.path.splitext(path)[1].lower() mime_map = {".mp3": "audio/mpeg", ".wav": "audio/wav"} mime = mime_map.get(suffix) if not mime: raise TtsError(f"不支持的音频格式: {suffix},仅支持 mp3/wav") with open(path, "rb") as f: voice_bytes = f.read() if len(voice_bytes) > 10 * 1024 * 1024: raise TtsError("音频文件过大(最大 10 MB)") voice_b64 = base64.b64encode(voice_bytes).decode("utf-8") return f"data:{mime};base64,{voice_b64}", mime ``` The command-line interface also permits an unrestricted endpoint override: ```python parser.add_argument("--base-url", default=None, help="自定义 API 端点 URL(覆盖 MIMO_API_BASE 环境变量)") args = parser.parse_args() if args.base_url: global API_BASE API_B ...[truncated 4675 chars]
Remediation
View remediation
Vulnerability Patterns
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Taint TrackingDirect Taint Flow, Variable-Mediated Taint Flow, Credential Exfiltration Chain
  • 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
Findings (32)

Tainted flow: 'req' from os.getenv (line 52, credential/environment) → urllib.request.urlopen (network output)

Critical
Category
Data Flow
Confidence
90% confidence
Finding

The script sends API requests to a base URL taken from the MIMO_API_BASE environment variable without validation. In environments where attackers can influence environment variables, this can redirect requests and the API key to an attacker-controlled endpoint, causing credential leakage and exfiltration of user text/context.

Content

Scanner excerpt · scripts/mimo_tts.py (reported line 62)May include surrounding context.

python
method="POST",
    )
    try:
        with urllib.request.urlopen(req, timeout=60) as resp:
            body = json.loads(resp.read())
    except urllib.error.HTTPError as exc:
        err_body = exc.read().decode(errors="replace")

Tainted flow: 'req' from os.getenv (line 44, credential/environment) → urllib.request.urlopen (network output)

Critical
Category
Data Flow
Confidence
90% confidence
Finding

Credentials or environment variables flow to a network sink. This is a high-confidence indicator of credential exfiltration.

Content

Scanner excerpt · scripts/mimo_tts_voicedesign.py (reported line 51)May include surrounding context.

python
method="POST",
    )
    try:
        with urllib.request.urlopen(req, timeout=60) as resp:
            body = json.loads(resp.read())
    except urllib.error.HTTPError as exc:
        err_body = exc.read().decode(errors="replace")

Tainted flow: 'req' from os.getenv (line 54, credential/environment) → urllib.request.urlopen (network output)

Critical
Category
Data Flow
Confidence
95% confidence
Finding

The script allows a user-controlled base URL via --base-url or MIMO_API_BASE and then sends the authenticated request, including the api-key header and sensitive TTS content, to that endpoint. This creates an SSRF-style exfiltration risk and credential leakage path if the endpoint is changed to an attacker-controlled server, which is more dangerous in an agent/skill context where tooling may be invoked with untrusted parameters or inherited environment variables.

Content

Scanner excerpt · scripts/tts.py (reported line 62)May include surrounding context.

python
)
    for attempt in range(max_retries):
        try:
            with urllib.request.urlopen(req, timeout=60) as resp:
                body = json.loads(resp.read())
            break
        except urllib.error.HTTPError as exc:

Tp4

High
Category
MCP Tool Poisoning
Confidence
95% confidence
Finding

The English description similarly overclaims capabilities not reflected by the analyzed behavior, including preset voices, cloning, and a broad official-compatible TTS suite. Overstated capability is security-relevant because users may provide inputs, files, or trust assumptions inappropriate for the actual implementation and review scope.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
95% confidence
Finding

The English description similarly overclaims capabilities not reflected by the analyzed behavior, including preset voices, cloning, and a broad official-compatible TTS suite. Overstated capability is security-relevant because users may provide inputs, files, or trust assumptions inappropriate for the actual implementation and review scope.

Content

No source excerpt is available for this finding.

Tainted flow: 'req' from pathlib.Path.read_bytes (line 69, file read) → urllib.request.urlopen (network output)

High
Category
Data Flow
Confidence
80% confidence
Finding

File contents flow to a network sink. This may indicate data exfiltration of sensitive files.

Content

Scanner excerpt · scripts/mimo_tts_voiceclone.py (reported line 76)May include surrounding context.

python
method="POST",
    )
    try:
        with urllib.request.urlopen(req, timeout=60) as resp:
            body = json.loads(resp.read())
    except urllib.error.HTTPError as exc:
        err_body = exc.read().decode(errors="replace")

Undeclared Tool Scope

Medium
Category
MCP Least Privilege
Confidence
84% confidence
Finding

The skill declares access to environment variables, file I/O, and network behavior but does not define any explicit tool scope or allowed-tools boundaries. In an agent setting, that lack of least-privilege controls can let the skill read secrets, write arbitrary files, or transmit data externally beyond what a user would reasonably expect.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
87% confidence
Finding

The instructions state as a rule that --context must always be filled and all examples and guidance are written as mandatory Chinese phrasing, which effectively imposes a specific language/locale behavior rather than offering a choice. Because the skill also includes English voices later, this lack of explicit user language choice creates a locale-policy concern in the natural-language instructions.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
96% confidence
Finding

The skill promotes voice-cloning functionality without any warning about consent, biometric privacy, or authorization requirements. Because voice samples are sensitive biometric-like data and cloned voices can enable impersonation or fraud, omitting these safeguards materially increases misuse risk.

Content

No source excerpt is available for this finding.

External Transmission

Medium
Category
Data Exfiltration
Confidence
50% 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 · SKILL.md (reported line 51)May include surrounding context.

md
## API 地址

- 官方: `https://api.xiaomimimo.com/v1`
- 中国集群: `https://token-plan-cn.xiaomimimo.com/v1`

## 鉴权

External Transmission

Medium
Category
Data Exfiltration
Confidence
50% 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 · references/official-api-docs.md (reported line 25)May include surrounding context.

md
## API 地址

- 官方: `https://api.xiaomimimo.com/v1`
- 中国集群: `https://token-plan-cn.xiaomimimo.com/v1`

## 鉴权

External Transmission

Medium
Category
Data Exfiltration
Confidence
50% 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 · references/official-api-docs.md (reported line 172)May include surrounding context.

md
## API 地址

- 官方: `https://api.xiaomimimo.com/v1`
- 中国集群: `https://token-plan-cn.xiaomimimo.com/v1`

## 鉴权

External Transmission

Medium
Category
Data Exfiltration
Confidence
50% 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 · references/official-api-docs.md (reported line 202)May include surrounding context.

md
## API 地址

- 官方: `https://api.xiaomimimo.com/v1`
- 中国集群: `https://token-plan-cn.xiaomimimo.com/v1`

## 鉴权

External Transmission

Medium
Category
Data Exfiltration
Confidence
50% 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 · references/official-api-docs.md (reported line 243)May include surrounding context.

md
## API 地址

- 官方: `https://api.xiaomimimo.com/v1`
- 中国集群: `https://token-plan-cn.xiaomimimo.com/v1`

## 鉴权

External Transmission

Medium
Category
Data Exfiltration
Confidence
50% 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 · references/official-api-docs.md (reported line 334)May include surrounding context.

md
## API 地址

- 官方: `https://api.xiaomimimo.com/v1`
- 中国集群: `https://token-plan-cn.xiaomimimo.com/v1`

## 鉴权

External Transmission

Medium
Category
Data Exfiltration
Confidence
50% 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 · references/official-api-docs.md (reported line 363)May include surrounding context.

md
## API 地址

- 官方: `https://api.xiaomimimo.com/v1`
- 中国集群: `https://token-plan-cn.xiaomimimo.com/v1`

## 鉴权

External Transmission

Medium
Category
Data Exfiltration
Confidence
50% 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 · references/official-api-docs.md (reported line 403)May include surrounding context.

md
## API 地址

- 官方: `https://api.xiaomimimo.com/v1`
- 中国集群: `https://token-plan-cn.xiaomimimo.com/v1`

## 鉴权

External Transmission

Medium
Category
Data Exfiltration
Confidence
50% 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 · references/official-api-docs.md (reported line 469)May include surrounding context.

md
## API 地址

- 官方: `https://api.xiaomimimo.com/v1`
- 中国集群: `https://token-plan-cn.xiaomimimo.com/v1`

## 鉴权

External Transmission

Medium
Category
Data Exfiltration
Confidence
50% 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 · references/official-api-docs.md (reported line 500)May include surrounding context.

md
## API 地址

- 官方: `https://api.xiaomimimo.com/v1`
- 中国集群: `https://token-plan-cn.xiaomimimo.com/v1`

## 鉴权

External Transmission

Medium
Category
Data Exfiltration
Confidence
50% 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 · references/official-api-docs.md (reported line 546)May include surrounding context.

md
## API 地址

- 官方: `https://api.xiaomimimo.com/v1`
- 中国集群: `https://token-plan-cn.xiaomimimo.com/v1`

## 鉴权

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 · references/official-api-docs.md (reported line 172)May include surrounding context.

Curl:

bash
curl --location --request POST 'https://api.xiaomimimo.com/v1/chat/completions' \
--header "api-key: $MIMO_API_KEY" \
--header 'Content-Type: application/json' \
--data-raw '{

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 · references/official-api-docs.md (reported line 334)May include surrounding context.

Curl:

bash
curl --location --request POST 'https://api.xiaomimimo.com/v1/chat/completions' \
--header "api-key: $MIMO_API_KEY" \
--header 'Content-Type: application/json' \
--data-raw '{

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
91% confidence
Finding

The voice-cloning documentation instructs users to upload base64-encoded voice samples to a third-party API but does not warn about consent, privacy, or biometric-data handling risks. Because voice samples can be sensitive personal data and may belong to another person, the omission can lead users to submit recordings without authorization or awareness of retention/compliance implications.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The skill transmits user-provided text and optional context to a remote third-party TTS service, but the code provides no user-facing notice or consent mechanism. If callers assume processing is local, sensitive or confidential content may be unintentionally disclosed to the external provider.

Content

No source excerpt is available for this finding.

Tainted flow: 'audio_data' from os.environ.get (line 108, credential/environment) → pathlib.Path.write_bytes (file write)

Medium
Category
Data Flow
Confidence
65% confidence
Finding

Data from a source is assigned to a variable that is later passed to a sink, creating a variable-mediated taint flow.

Content

Scanner excerpt · scripts/mimo_tts.py (reported line 112)May include surrounding context.

python
output_path = Path(args.output)
    output_path.parent.mkdir(parents=True, exist_ok=True)
    output_path.write_bytes(audio_data)
    print(output_path)