Back to skill

Security audit

语音合成 豆包 Doubao TTS

Security checks for vulnerabilities and agentic risk

Overview

This is a disclosed TTS skill that uses dLazy's external npm CLI and cloud API, with some documentation quality and supply-chain cautions but no hidden or destructive behavior in the inspected artifacts.

Install only if you are comfortable trusting the dLazy npm CLI and sending prompts and selected inputs to dLazy cloud endpoints. Prefer per-invocation or sandboxed use over a global install when possible, confirm any `--save` destination before writing files, and avoid passing local file paths unless you intend those files to be uploaded.

Vulnerability Patterns
  • Insecure DependenciesIntroduces malicious components through unsafe dependency sources
  • 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)

T08 · Insecure Dependencies

Warning
Location
SKILL.md:5
Finding
Unverified Third-Party CLI Installation and Execution<![CDATA[ ## Vulnerability Details **File Location**: `SKILL.md:5,56-63`; duplicated in `SKILL-cn.md:5,56-63` **Vulnerability Type**: Third-party package installation and execution without artifact integrity verification **Risk Level**: Medium ### Complete Code Snippet ```bash npx @dlazy/cli@1.2.3 <command> ``` ```markdown Or, if you prefer a global install, the skill's `metadata.clawdbot.install` field declares the exact pinned version (`npm install -g @dlazy/cli@1.2.3`). Review the GitHub source before installing. ``` The corresponding metadata declares: ```json { "install": "npm install -g @dlazy/cli@1.2.3", "installAlternative": "npx @dlazy/cli@1.2.3" } ``` ### Technical Analysis The Skill depends on an external npm package, `@dlazy/cli@1.2.3`, whose executable source and transitive dependencies are not included in the audited project. Both documented installation methods cause code obtained from the npm registry to run locally: - `npx` can download and immediately execute the package. - `npm install -g` installs the package globally and may execute package lifecycle scripts during installation. Pinning the package version reduces unintended version drift, but it does not independently verify the downloaded artifact's integrity or the safety of its transitive dependencies. The project does not provide a lockfile, integrity hash, vendored dependency tree, or locally reviewable implementation corresponding to the executable package. This creates a supply-chain trust boundary. If the package artifact, publisher account, npm registry delivery path, or a transitive dependency is compromised, attacker-controlled code could execute under the privileges of the user invoking the Skill. No evidence in the audited files establishes that the named package is currently malicious. The finding concerns the unsafe dependency execution model and absence of verifiable dependency integrity controls. ### Attack Path 1. An attacker compromises the npm publisher ...[truncated 1457 chars]
Remediation
<![CDATA[ ## Remediation Suggestions 1. Avoid global installation and prefer an isolated, non-privileged execution environment. 2. Vendor the reviewed implementation and exact dependency tree into a controlled build process where licensing permits. 3. Provide a lockfile containing exact transitive versions and registry integrity hashes. 4. Verify downloaded package artifacts against a separately published cryptographic digest or signed provenance record before execution. 5. Use npm provenance and package-signing verification where supported. 6. Disable package lifecycle scripts during installation when they are not required, for example by using `--ignore-scripts`, after confirming that this does not break legitimate operation. 7. Run the CLI inside a sandbox or container with: - No elevated privileges. - A minimal environment-variable allowlist. - Access only to explicitly selected input and output files. - Network access restricted to the documented endpoints. - No access to unrelated credential stores or home-directory content. 8. Store the API key in an operating-system credential manager rather than a plaintext user configuration file where feasible. 9. Review and pin every transitive dependency, not only the top-level CLI version. 10. Document the expected package digest and a repeatable procedure for verifying that the installed executable corresponds to the reviewed source revision. ]]>
Vulnerability Patterns
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • Trigger AbuseOverly Broad Trigger, Shadow Command Trigger, Keyword Baiting Trigger
  • MCP Tool PoisoningHidden Instructions, Unicode Deception, Parameter Description Injection
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
Findings (10)

Ae1

High
Category
analysis-evasion
Content
[English](./SKILL.md) · [中文](./SKILL-cn.md)
Confidence
100% confidence
Finding
Referenced artifact was not completely inspected

Vague Triggers

Medium
Confidence
95% confidence
Finding
The trigger keywords are broad everyday phrases related to speech generation, increasing the chance the skill is invoked unintentionally. In an agent environment, accidental activation can lead to unnecessary API calls, credential use, remote data transfer, or local file writes when the user did not intend to use this particular third-party service.

Description-Behavior Mismatch

Medium
Confidence
88% confidence
Finding
The skill is marketed as TTS, but the documentation states that local image/video/audio paths may be uploaded to remote storage. This creates a data exfiltration and user-expectation mismatch risk: an agent or user may provide local file paths assuming a simple TTS action, while the CLI transfers local content to third-party infrastructure.

Intent-Code Divergence

Medium
Confidence
98% confidence
Finding
The output example shows an image result for a TTS skill, which is inconsistent with the stated purpose. Such contradictions can cause downstream agents to mis-handle outputs, trust the wrong MIME types, or invoke follow-on processing inappropriate for the actual content returned.

Whitespace Padding

Medium
Category
Prompt Injection
Content
## 错误处理

| Code | 错误类型                         | 示例信息                                                                                                                 |
| ---- | -------------------------------- | ------------------------------------------------------------------------------------------------------------------------ |
| 401  | 未授权 (API Key缺失或无效)       | `ok: false, code: "unauthorized", message: "API key is missing or invalid"`                                                              |
| 501  | 缺少必填参数                     | `error: required option '--prompt <prompt>' not specified`                                                               |
Confidence
70% confidence
Finding
Large whitespace padding was detected (a block of blank lines or a long run of spaces). This can push injected instructions below or to the right of the visible area so a human reviewer never sees them while the agent still reads them. Manual review of the hidden content is recommended.

Vague Triggers

Medium
Confidence
94% confidence
Finding
The trigger list includes generic phrases such as "text to speech", "generate speech", and "voice broadcast", which are broad enough to overlap with ordinary user requests rather than uniquely identifying this skill. The file does not provide exclusion conditions or tighter activation constraints to distinguish when this specific skill should or should not be invoked.

Intent-Code Divergence

Medium
Confidence
97% confidence
Finding
The documented JSON output for `doubao-tts` shows `type: "image"`, a `.png` URL, and `mimeType: "image/png"`. For a skill explicitly described as synthesizing speech, this is an active contradiction in the documentation rather than a minor omission.

Whitespace Padding

Medium
Category
Prompt Injection
Content
## Error Handling

| Code | Error Type                         | Example Message                                                                                                          |
| ---- | ---------------------------------- | ------------------------------------------------------------------------------------------------------------------------ |
| 401  | Unauthorized (No API Key)          | `ok: false, code: "unauthorized", message: "API key is missing or invalid"`                                                              |
| 501  | Missing required parameter         | `error: required option '--prompt <prompt>' not specified`                                                              |
Confidence
70% confidence
Finding
Large whitespace padding was detected (a block of blank lines or a long run of spaces). This can push injected instructions below or to the right of the visible area so a human reviewer never sees them while the agent still reads them. Manual review of the hidden content is recommended.

Missing User Warnings

Low
Confidence
87% confidence
Finding
The `--save` flag writes output to a local path, but the documentation does not prominently warn that this changes the local filesystem. In agent-driven contexts, undisclosed file writes can surprise users, overwrite data, or create persistent artifacts without informed consent.

Natural-Language Policy Violations

Low
Confidence
77% confidence
Finding
The description and usage surface present bilingual content, and the command help later shows a default voice language of `zh-cn`, which can steer output toward a specific locale absent an explicit user choice. The file does mention `en` as an option, but it does not instruct the agent to ask the user for language preference before using the default.

Static analysis

No suspicious patterns detected.