Back to skill

Security audit

短剧生产

Security checks for vulnerabilities and agentic risk

Overview

ClawScan rates this skill suspicious with medium confidence, mainly because authenticated requests may expose credentials through redirects and paid generation can run without confirmed current consent.

Consider the credential redirect and download-destination risks, and whether the skill’s paid generation actions can be gated by your own confirmation process. The scan was partial: two local references could not be resolved, so the evidence is incomplete. The verdict is suspicious, not a claim that the author acted maliciously.

Vulnerability Patterns
  • 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
  • Unauthorized Access and Privilege EscalationObtains permissions beyond the task's legitimate needs
Vulnerability Patterns
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • System Prompt LeakageDirect Leakage, Indirect Extraction, Tool-Based Exfiltration
  • Behavioral ASTexec() Call, eval() Call, Dynamic Import
  • Taint TrackingDirect Taint Flow, Variable-Mediated Taint Flow, Credential Exfiltration Chain
  • MCP Least PrivilegeUnderdeclared Capability, Wildcard Permission, Missing Permission Declaration
Findings (16)

Tainted flow: 'request' from os.environ.get (line 1091, credential/environment) → urllib.request.urlopen (network output)

Critical
Category
Data Flow
Confidence
94% confidence
Finding

Sending an environment-sourced API credential to its intended provider is necessary for this skill, not inherently exfiltration. However, the default urllib redirect handler can forward the Authorization header to a different host or an HTTP destination, so a malicious or compromised configured endpoint could redirect the request and expose the credential; _base_url validates only the initial URL.

Content

Scanner excerpt · scripts/provider_adapters.py (reported line 1096)May include surrounding context.

python
if body is not None:
        request.add_header("Content-Type", "application/json")
    try:
        with urllib.request.urlopen(request, timeout=180) as response:
            raw = response.read(MAX_JSON_RESPONSE + 1)
            headers = dict(response.headers.items())
    except urllib.error.HTTPError as exc:

Tainted flow: 'url' from os.environ.get (line 1654, credential/environment) → urllib.request.urlopen (network output)

Critical
Category
Data Flow
Confidence
91% confidence
Finding

The download URL comes from a provider response rather than directly from an environment credential, and this request does not attach the API bearer token. Nevertheless, validating only an initial HTTPS scheme and nonempty authority permits requests to internal HTTPS services and unchecked redirects, creating an SSRF risk if a provider response or configured endpoint is attacker-controlled; media validation occurs after the request.

Content

Scanner excerpt · scripts/provider_adapters.py (reported line 1458)May include surrounding context.

python
path = _output_root(job) / ("result" + Path(target).suffix.casefold())
    size = 0
    try:
        with urllib.request.urlopen(url, timeout=180) as response, path.open("xb") as handle:
            while chunk := response.read(1024 * 1024):
                size += len(chunk)
                if size > MAX_OUTPUT_BYTES:

Tainted flow: 'request' from os.environ.get (line 1697, credential/environment) → urllib.request.urlopen (network output)

Critical
Category
Data Flow
Confidence
94% confidence
Finding

Uploading selected reference images and authenticating to OpenAI are expected operations for this media-production skill. The multipart request nevertheless uses urllib's default redirect handling, which can forward the bearer credential across origins or to HTTP; HTTPS validation of the initial base URL does not prevent this.

Content

Scanner excerpt · scripts/provider_adapters.py (reported line 1701)May include surrounding context.

python
request.add_header("Authorization", f"Bearer {token}")
        request.add_header("Content-Type", content_type)
        try:
            with urllib.request.urlopen(request, timeout=300) as response:
                raw = response.read(MAX_JSON_RESPONSE + 1)
                request_id = _request_id(dict(response.headers.items()))
        except urllib.error.HTTPError as exc:

Description-Behavior Mismatch

High
Category
MCP Tool Poisoning
Confidence
90% confidence
Finding

The generation modalities and provider interactions match the declared purpose. However, the description makes fresh explicit confirmation a mandatory prerequisite. main() directly invokes a provider runner after parsing the job, and neither _require_job() nor the runners checks confirmation, its freshness, or its binding to the submitted job. A structurally valid job with configured credentials is sufficient to trigger a paid request. An external caller might enforce consent, but that safeguard is not established by the supplied code. Reference-contract formatting, reference uploads, polling, and temporary output storage are supporting implementation details rather than unrelated capabilities.

Content

No source excerpt is available for this finding.

Direct Prompt Extraction

High
Category
System Prompt Leakage
Confidence
85% confidence
Finding

Skill contains instructions that could directly expose system prompts, internal rules, or hidden instructions to users or external parties.

Content

Scanner excerpt · scripts/provider_adapters.py (reported line 262)May include surrounding context.

python
raise ValueError("provider adapter requires exactly one output")
    if len(outputs) > max_outputs:
        raise ValueError(f"provider adapter accepts at most {max_outputs} outputs")
    return prompt, dict(parameters)


ZH_ROLE_LABELS = {

Direct Prompt Extraction

High
Category
System Prompt Leakage
Confidence
85% confidence
Finding

Skill contains instructions that could directly expose system prompts, internal rules, or hidden instructions to users or external parties.

Content

Scanner excerpt · scripts/provider_adapters.py (reported line 330)May include surrounding context.

python
bindings = job.get("reference_bindings", [])
    references = job.get("references", [])
    if not bindings:
        return prompt
    if (
        not isinstance(bindings, list)
        or not isinstance(references, list)

Direct Prompt Extraction

High
Category
System Prompt Leakage
Confidence
85% confidence
Finding

Skill contains instructions that could directly expose system prompts, internal rules, or hidden instructions to users or external parties.

Content

Scanner excerpt · scripts/provider_adapters.py (reported line 402)May include surrounding context.

python
)
            )
    if _prompt_already_binds_references(prompt, bindings, reference_tokens):
        return prompt
    if language.startswith("zh"):
        heading = zh_heading
    elif language.startswith("en"):

Skill declares no tool scope ('permissions' or 'allowed-tools') but code capabilities were detected: env, file_read, file_write, network, shell.

Medium
Category
MCP Least Privilege
Confidence
70% confidence
Finding

Without declared permissions the skill's intent is opaque and cannot be validated.

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 · references/builtin-providers.md (reported line 11)May include surrounding context.

{"command": ["python3", "/opt/studio/provider_adapters.py", "gpt-image-2"], "timeout_seconds": 600}

text

- **环境变量**:`OPENAI_API_KEY`(必填);`OPENAI_BASE_URL`(可选 HTTPS 地址覆盖,默认 `https://api.openai.com/v1`)。
- **任务与路由**:`modality` 为 `image`,单次支持产出 1–16 张同格式图片(`.png`、`.jpg`/`.jpeg` 或 `.webp`),自动按 `n = len(outputs)` 请求并逐张解码 `b64_json` 写入临时中转目录。无参考图时调用 `POST /images/generations`;带 1–16 张参考图时调用 `POST /images/edits`(`image[]` 表单上传,固定 `model: "gpt-image-2"`)。
- **支持参数**:`width` + `height`(自动拼成 `size`)或直接传 `size`,另支持 `quality`、`background`(不支持透明背景)与 `moderation`。

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/builtin-providers.md (reported line 36)May include surrounding context.

text

- **必填环境变量**:`MINIMAX_API_KEY`、`MINIMAX_VIDEO_MODEL`(账号已开通的模型 ID)。
- **可选环境变量**:`MINIMAX_VIDEO_BASE_URL`(默认 `https://api.minimax.io/v2`)、`MINIMAX_VIDEO_POLL_INTERVAL`(默认 `5` 秒)、`MINIMAX_VIDEO_TIMEOUT_SECONDS`(默认 `1800` 秒);`MINIMAX_VIDEO_ALLOWED_RESOLUTIONS`(兼容 `MINIMAX_VIDEO_RESOLUTIONS`)、`MINIMAX_VIDEO_ALLOWED_RATIOS`(兼容 `MINIMAX_VIDEO_RATIOS`)、`MINIMAX_VIDEO_MIN_DURATION` 与 `MINIMAX_VIDEO_MAX_DURATION` 用于按模型档位收窄校验(未配置时回退内置合法全集 `480P,768P,2K`、`adaptive,1:1,3:4,4:3,9:16,16:9,21:9` 与 `1–30` 秒)。
- **参数与多模态 `content`**:`modality` 为 `video`,单次产出 1 个 `.mp4`;`duration` 与 `resolution` 必填,纯文生视频必填非 `adaptive` 的 `ratio`。内置默认支持 `first_frame` / `last_frame`(首尾帧模式)或 `reference_image` ≤ 9、`reference_video` ≤ 3、`reference_audio` ≤ 3(全参考模式,两模式互斥;配置无需重复手写 `reference_roles`)。提示词正文上限 7000 字符;已包含 `retention_analysis:` 原生结构或已显式写出全部 `<Picture N>` 等槽位时不再追加参考尾巴。提交 `POST {base}/video_generation` 后轮询 `GET {base}/query/video_generation/{task_id}` 下载成片。

官方文档:[MiniMax 视频生成 API](https://platform.minimax.io/do

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/builtin-providers.md (reported line 47)May include surrounding context.

{"command": ["python3", "/opt/studio/provider_adapters.py", "minimax-music"], "timeout_seconds": 600}

text

- **环境变量**:`MINIMAX_API_KEY`(必填);`MINIMAX_BASE_URL`(可选 HTTPS 地址覆盖,默认 `https://api.minimax.io/v1`)。
- **任务与调用**:`modality` 为 `music`,单次产出 1 个与 `format` 一致的 `.mp3` 或 `.wav`。`prompt` 填曲风、配器与情绪描述;支持 `lyrics`、`is_instrumental`、`sample_rate`、`bitrate` 与 `format`(不启用 `lyrics_optimizer` 自动改词:人声歌曲传定稿 `lyrics`,纯配乐不传歌词)。以 `model: "music-3.0"` 与 `output_format: "hex"` 调用 `POST /music_generation` 并解码 `data.audio`。

官方文档:[MiniMax 音乐生成 API](https://platform.minimax.io/docs/api-reference/music-generation)。

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/builtin-providers.md (reported line 58)May include surrounding context.

{"command": ["python3", "/opt/studio/provider_adapters.py", "minimax-speech"], "timeout_seconds": 600}

text

- **环境变量**:`MINIMAX_API_KEY`(必填);`MINIMAX_BASE_URL`(可选 HTTPS 地址覆盖,默认 `https://api.minimax.io/v1`)。
- **任务与调用**:`modality` 为 `tts`,单次产出 1 个与 `format` 一致的 `.mp3` 或 `.wav`。`prompt` 只放纯台词原文;必填 `model` 与预设 `voice_id`(取自 `$short-drama-assets` 在《视觉设定.md》登记的角色声线设定),可选 `emotion`(`happy`、`sad`、`angry`、`fearful`、`disgusted`、`surprised`、`neutral`)、`speed`、`vol`、`pitch`、`sample_rate`、`bitrate` 与 `format`。本内置接口使用预设 `voice_id` 调用 `POST /t2a_v2` 合成;需上传角色参考录音做音色绑定的场景请走支持 `reference_audio` 的视频生成接口或自定义语音接口。

官方文档:[MiniMax 语音合成 API](https://platform.minimax.io/docs/api-reference/speech-t2a-http)。

subprocess module call

Medium
Category
Dangerous Code Execution
Confidence
70% confidence
Finding

subprocess module calls execute external commands. Without careful input validation, this enables command injection.

Content

Scanner excerpt · scripts/production_tool.py (reported line 2039)May include surrounding context.

python
note = _confirmation_note(consumes_confirmation)
    with tempfile.TemporaryFile() as stdout, tempfile.TemporaryFile() as stderr:
        try:
            completed = subprocess.run(
                command,
                input=_canonical(payload),
                stdout=stdout,

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/provider_adapters.py (reported line 34)May include surrounding context.

python
OPENAI_MODEL = "gpt-image-2"
MINIMAX_MUSIC_MODEL = "music-3.0"
OPENAI_BASE_URL = "https://api.openai.com/v1"
SEEDANCE_BASE_URL = "https://ark.cn-beijing.volces.com/api/v3"
MINIMAX_BASE_URL = "https://api.minimax.io/v1"
MINIMAX_VIDEO_BASE_URL = "https://api.minimax.io/v2"

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/provider_adapters.py (reported line 36)May include surrounding context.

python
MINIMAX_MUSIC_MODEL = "music-3.0"
OPENAI_BASE_URL = "https://api.openai.com/v1"
SEEDANCE_BASE_URL = "https://ark.cn-beijing.volces.com/api/v3"
MINIMAX_BASE_URL = "https://api.minimax.io/v1"
MINIMAX_VIDEO_BASE_URL = "https://api.minimax.io/v2"
MAX_JSON_RESPONSE = 128 * 1024 * 1024
MAX_OUTPUT_BYTES = 512 * 1024 * 1024

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/provider_adapters.py (reported line 37)May include surrounding context.

python
OPENAI_BASE_URL = "https://api.openai.com/v1"
SEEDANCE_BASE_URL = "https://ark.cn-beijing.volces.com/api/v3"
MINIMAX_BASE_URL = "https://api.minimax.io/v1"
MINIMAX_VIDEO_BASE_URL = "https://api.minimax.io/v2"
MAX_JSON_RESPONSE = 128 * 1024 * 1024
MAX_OUTPUT_BYTES = 512 * 1024 * 1024
MAX_REFERENCE_BYTES = 50 * 1024 * 1024