Back to skill

Security audit

视频生成 可灵 Kling V3

Security checks for vulnerabilities and agentic risk

Overview

This skill is a disclosed wrapper for a third-party video-generation CLI, with expected API-key storage, network calls, and local media uploads for that purpose.

Install only if you trust dLazy and its npm package. Prefer npx or a sandbox over global install, do not run npm or the CLI as administrator, review which local files are passed for upload, and rotate the dLazy API key if you suspect CLI compromise.

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 Executes with User Privileges<![CDATA[ ## Vulnerability Details **File Location**: `SKILL.md:5,49-55`; mirrored in `SKILL-cn.md:5,49-55` **Vulnerability Type**: Third-party supply-chain exposure **Risk Level**: Medium ### Complete Code Snippet From `SKILL.md`: ```yaml metadata: {"clawdbot":{"emoji":"🤖","requires":{"bins":["npm","npx"]},"install":"npm install -g @dlazy/cli@1.2.3","installAlternative":"npx @dlazy/cli@1.2.3","homepage":"https://github.com/dlazy-ai/cli","source":"https://github.com/dlazy-ai/cli","author":"dlazyai","license":"see-repo","npm":"https://www.npmjs.com/package/@dlazy/cli","configLocation":"~/.dlazy/config.json","apiEndpoints":["api.dlazy.com","files.dlazy.com"]},"openclaw":{"systemPrompt":"When invoking this skill, use dlazy kling-v3 -h for help."}} ``` ```markdown You can install on demand without persisting a global binary by running: ```bash npx @dlazy/cli@1.2.3 <command> ``` 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 equivalent configuration and commands appear in `SKILL-cn.md`: ```yaml metadata: {"clawdbot":{"emoji":"🤖","requires":{"bins":["npm","npx"]},"install":"npm install -g @dlazy/cli@1.2.3","installAlternative":"npx @dlazy/cli@1.2.3","homepage":"https://github.com/dlazy-ai/cli","source":"https://github.com/dlazy-ai/cli","author":"dlazyai","license":"see-repo","npm":"https://www.npmjs.com/package/@dlazy/cli","configLocation":"~/.dlazy/config.json","apiEndpoints":["api.dlazy.com","files.dlazy.com"]},"openclaw":{"systemPrompt":"当调用此技能时,可以使用 dlazy kling-v3 -h 查看帮助信息。"}} ``` ```bash npx @dlazy/cli@1.2.3 <command> ``` ### Technical Analysis The audited project contains only documentation and configuration; it does not contain the implementation of `@dlazy/cli`. Nevertheless, the Skill delegates authentication, API-key storage, local-file processing, uploads, and network communication to th ...[truncated 2550 chars]
Remediation
<![CDATA[ ## Remediation Suggestions 1. **Verify package integrity** - Record and validate the registry artifact's cryptographic integrity hash before execution. - Publish verifiable build provenance and signed releases. - Ensure the npm artifact is reproducibly linked to the reviewed source revision. 2. **Audit the complete dependency graph** - Review the source for `@dlazy/cli@1.2.3`, including package lifecycle scripts. - Generate and audit a lockfile or software bill of materials covering all transitive dependencies. - Add automated dependency, malware, provenance, and vulnerability scanning to the release process. 3. **Reduce installation risk** - Avoid global installation by default. - Run the CLI in a sandbox, container, or dedicated least-privileged account. - Disable npm lifecycle scripts where compatible with the package. - Do not run npm, `npx`, or the CLI with administrator or root privileges. 4. **Restrict credential exposure** - Use narrowly scoped, short-lived API credentials where supported. - Protect the local configuration file with owner-only permissions. - Rotate the API key promptly if package compromise is suspected. - Avoid exposing unrelated secrets through the CLI process environment. 5. **Control file and network access** - Require explicit user confirmation before uploading each local file. - Limit filesystem access to the files deliberately selected for generation. - Restrict outbound traffic to the documented dLazy endpoints when operationally feasible. 6. **Vendor or bundle reviewed code** - For stronger assurance, include a reviewed implementation in the Skill artifact or distribute a verified standalone binary with a pinned cryptographic digest rather than retrieving executable code at invocation time. ]]>
Vulnerability Patterns
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • Trigger AbuseOverly Broad Trigger, Shadow Command Trigger, Keyword Baiting Trigger
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
  • Supply ChainUnpinned Dependencies, External Script Fetching, Obfuscated Code
Findings (6)

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
94% confidence
Finding
The trigger keywords are broad and overlap with common user intents such as '生成视频' and generic references to Kling v3, which can cause the skill to activate when a user did not explicitly intend to invoke this third-party tool. In this skill's context, accidental activation is more concerning because invocation can lead to external API calls, local file uploads, authentication flows, and possible cost-incurring actions through the dLazy CLI.

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
95% confidence
Finding
In a markdown skill file, trigger phrases should be specific enough to avoid accidental activation. 'generate video' is a generic everyday request phrase and the document does not provide exclusion conditions or context constraints to narrow when this skill should trigger.

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.

Vague Triggers

Low
Confidence
82% confidence
Finding
This line describes broad capability areas rather than precise trigger phrases, which can make invocation conditions unclear. Without explicit phrasing, constraints, or negative examples, an agent may over-match many ordinary media-editing requests to this skill.

Static analysis

No suspicious patterns detected.