Back to skill

Security audit

Seedance Video Generation Extension

Security checks for vulnerabilities and agentic risk

Overview

This appears to be a real video workflow skill, but its video download and filename handling are under-scoped enough that users should review it before installing.

Install only if you are comfortable sending storyboards and prompts to the configured external generation providers. Use a dedicated project directory, review every generated storyboard before confirming stages, avoid sensitive/private source material, and do not run untrusted storyboard JSON until identifiers and downloaded URLs are constrained or patched.

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 (3)

T09 · Insecure Skill Coding Practices

Error
Location
scripts/orchestrate_story.py:389
Finding

Path Traversal Through Unvalidated Shot and Task Identifiers

Content
View full analysis
None: output_path.parent.mkdir(parents=True, exist_ok=True) urllib.request.urlretrieve(video_url, output_path) ``` ### Technical Analysis The storyboard validator requires a nonempty, unique shot identifier but does not restrict path separators, `..` components, absolute-path syntax, control characters, or identifier length. The `task_id` returned by the delegated `seedance.py` process is also not validated. Both values are interpolated directly into a filename. When the resulting value is joined to `run_dir`, embedded traversal components can cause the normalized destination to resolve outside the intended run directory. The code does not resolve the destination and verify t ...[truncated 1781 chars]
Remediation
View remediation
str: if not isinstance(value, str) or not SAFE_ID.fullmatch(value): raise OrchestratorError(f"Invalid {field}") return value ``` 2. Resolve the destination and enforce containment beneath the run directory: ```python base = run_dir.resolve() destination = (base / filename).resolve() try: destination.relative_to(base) except ValueError: raise OrchestratorError("Output path escapes the run directory") ``` 3. Generate local filenames independently of remote identifiers. Store the original task ID only as JSON metadata. 4. Reject absolute paths, path separators, `.` and `..` components, null bytes, control characters, and excessively long values. 5. Avoid silently overwriting existing files. Use exclusive creation or a collision-resistant, locally generated filename. 6. Add regression tests using traversal payloads in both `shot_id` and `task_id`, including mixed separators and deeply nested parent-directory components. ]]>

T09 · Insecure Skill Coding Practices

Error
Location
scripts/orchestrate_story.py:226
Finding

Server-Side Request Forgery Through Unrestricted Video URL Retrieval

Content
View full analysis
None: output_path.parent.mkdir(parents=True, exist_ok=True) urllib.request.urlretrieve(video_url, output_path) ``` The URL is obtained from the delegated task-status response and passed to the download function without validation: ```python content = status_json.get("content", {}) video_url = content.get("video_url", "") last_frame_url = content.get("last_frame_url", "") output_file = "" if video_url: filename = f"{idx:02d}-{shot_id}-{task_id}.mp4" output_path = run_dir / filename download_video(video_url, output_path) output_file = str(output_path) ``` ### Technical Analysis The orchestrator trusts `video_url` from the external `seedance.py` status response. It does not enforce: - An HTTPS-only scheme. - An allowlist of expected media hosts. - Rejection of URL credentials or unexpected ports. - Blocking of loopback, private, link-local, multicast, or reserved IP ranges. - DNS rebinding protections. - Redirect validation. - Response-size or download-time limits. - Media content-type or file-signature validation. `urllib.request.urlretrieve()` may access URLs selected by the delegated component. If that component is malicious, compromised, or pointed at an untrusted service, the request originates from the machine running the Skill and therefore has access to network locations that may not be reachable by the original attacker. The absence of response-size controls also permits an attacker-controlled endpoint to consume excessive disk space. ### Attack Path 1. An attacker controls or compromises the delegated `seedance.py`, its upstream API response, or another source capable of influencing the returned t ...[truncated 1378 chars]
Remediation
View remediation

T09 · Insecure Skill Coding Practices

Warning
Location
scripts/build_subagent_task.py:29
Finding

Prompt Injection in Generated Sub-Agent Parsing Tasks

Content
View full analysis
>> {raw_input} <<>> """ ``` The corresponding contract uses the same direct interpolation pattern: ```text 原始输入如下: <<>> {raw_input_here} <<>> ``` ### Technical Analysis The helper combines trusted parser instructions, a caller-selected contract file, and untrusted source content into one plain-text prompt. The raw-input delimiters provide visual separation but do not create an enforceable trust boundary. There is no explicit instruction that commands appearing inside the raw story are untrusted data and must never override the parser contract. A crafted document can contain statements directing the sub-agent to ignore preceding requirements, change the output structure, insert attacker-selected storyboard fields, or emit content intended to influence later agents and tools. This risk is amplified because `prepare_storyboard.py` accepts packaged sub-agent output largely as supplied when its `storyboard.version` is `storyboard.v1`. The resulting storyboard can flow into image-generation requests, the external video-generation script, and video download handling. The contract file is also supplied through `--contract-file`. If an untrusted caller controls that path, it can replace the expected contract with arbitrary instructions. ### Attack Path 1. An ...[truncated 1456 chars]
Remediation
View remediation
Vulnerability Patterns
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
  • Behavioral ASTexec() Call, eval() Call, Dynamic Import
  • MCP Least PrivilegeUnderdeclared Capability, Wildcard Permission, Missing Permission Declaration
  • MCP Tool PoisoningHidden Instructions, Unicode Deception, Parameter Description Injection
Findings (23)

Tp4

High
Category
MCP Tool Poisoning
Confidence
99% confidence
Finding

If the implementation only performs Seedream image batch generation while claiming a much broader strict stage-gated pipeline, the mismatch can cause users to expose content to external APIs under mistaken assumptions about local-only preparation or downstream controls. This is especially risky in media-generation workflows because storyboards and scripts may contain confidential, copyrighted, or regulated material.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
98% confidence
Finding

If the implementation only performs Seedream image batch generation while claiming a much broader strict stage-gated pipeline, the mismatch can cause users to expose content to external APIs under mistaken assumptions about local-only preparation or downstream controls. This is especially risky in media-generation workflows because storyboards and scripts may contain confidential, copyrighted, or regulated material.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
97% confidence
Finding

If the implementation only performs Seedream image batch generation while claiming a much broader strict stage-gated pipeline, the mismatch can cause users to expose content to external APIs under mistaken assumptions about local-only preparation or downstream controls. This is especially risky in media-generation workflows because storyboards and scripts may contain confidential, copyrighted, or regulated material.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
95% confidence
Finding

If the implementation only performs Seedream image batch generation while claiming a much broader strict stage-gated pipeline, the mismatch can cause users to expose content to external APIs under mistaken assumptions about local-only preparation or downstream controls. This is especially risky in media-generation workflows because storyboards and scripts may contain confidential, copyrighted, or regulated material.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
97% confidence
Finding

If the implementation only performs Seedream image batch generation while claiming a much broader strict stage-gated pipeline, the mismatch can cause users to expose content to external APIs under mistaken assumptions about local-only preparation or downstream controls. This is especially risky in media-generation workflows because storyboards and scripts may contain confidential, copyrighted, or regulated material.

Content

No source excerpt is available for this finding.

Undeclared Tool Scope

Medium
Category
MCP Least Privilege
Confidence
92% confidence
Finding

The skill advertises shell, file, env, network, and media-processing behavior but does not declare any explicit tool scope or permissions boundaries. In an agent ecosystem, missing scope declarations can lead to over-privileged execution, weaker review, and users invoking the skill without understanding that it may access files, environment secrets, external services, or shell commands.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
94% confidence
Finding

The documentation describes image/video generation workflows involving external services but omits a warning that storyboard and story content may be transmitted off-box to third-party providers. This creates a privacy and data-governance risk because users may unknowingly send sensitive scripts, personal data, or proprietary creative content to external generation services.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
90% confidence
Finding

The title and document content are written in Chinese, and the file does not indicate that language selection is optional or that the skill is intended only for a Chinese-speaking or region-specific context. Under the stated policy, forcing a specific language without user opt-in can be a natural-language policy violation.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
94% confidence
Finding

The shot prompt strings at L19, L23, and L27 are written only in Chinese, which imposes a specific language/locale in the skill content. The file does not indicate that this is optional, user-selected, or justified as a region-specific tool, so it appears to violate the language/locale policy criterion.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
94% confidence
Finding

The embedded parent-agent prompt is written entirely in Chinese and includes a Chinese-specific formatting rule, which effectively constrains the sub-agent interaction to a specific language/locale. The file does not offer a language choice or explain why Chinese is required, so this is a natural-language policy concern under the locale rule.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
97% confidence
Finding

The embedded prompt is written as a directive in Chinese and includes a Chinese-specific requirement, which steers the sub-agent toward a fixed language/locale behavior. The file does not offer a language choice or document a justified region-specific constraint, so this is a natural-language locale policy issue.

Content

No source excerpt is available for this finding.

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

python
for cmd in candidates:
        try:
            result = subprocess.run(
                [cmd, "-version"],
                capture_output=True,
                text=True,

Sudo/Root Execution

Medium
Category
Privilege Escalation
Confidence
70% confidence
Finding

Commands invoke sudo or root privileges. Verify this elevated access is necessary and justified.

Content

Scanner excerpt · scripts/concat_videos.py (reported line 58)May include surrounding context.

python
raise ConcatError(
        "FFmpeg not found. Please install FFmpeg:\n"
        "  macOS: brew install ffmpeg\n"
        "  Ubuntu: sudo apt install ffmpeg\n"
        "  Windows: choco install ffmpeg"
    )

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

python
]
    
    try:
        result = subprocess.run(cmd, capture_output=True, text=True, timeout=30)
        if result.returncode == 0:
            return float(result.stdout.strip())
    except (subprocess.SubprocessError, ValueError):

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

python
# Run FFmpeg
    try:
        result = subprocess.run(
            cmd,
            capture_output=True,
            text=True,

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

python
def run_json_command(cmd: List[str]) -> Dict[str, Any]:
    result = subprocess.run(cmd, capture_output=True, text=True)
    if result.returncode != 0:
        raise OrchestratorError(
            f"Command failed ({result.returncode}): {' '.join(cmd)}\n{result.stderr.strip()}"

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

python
def run_json_command(cmd: List[str]) -> Dict[str, Any]:
    result = subprocess.run(cmd, capture_output=True, text=True)
    if result.returncode != 0:
        raise OrchestratorError(
            f"Command failed ({result.returncode}): {' '.join(cmd)}\n{result.stderr.strip()}"

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

python
def run_json_command(cmd: List[str]) -> Dict[str, Any]:
    result = subprocess.run(cmd, capture_output=True, text=True)
    if result.returncode != 0:
        raise OrchestratorError(
            f"Command failed ({result.returncode}): {' '.join(cmd)}\n{result.stderr.strip()}"

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

python
def run_json_command(cmd: List[str]) -> Dict[str, Any]:
    result = subprocess.run(cmd, capture_output=True, text=True)
    if result.returncode != 0:
        raise OrchestratorError(
            f"Command failed ({result.returncode}): {' '.join(cmd)}\n{result.stderr.strip()}"

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

python
"--output", str(run_dir / "final-video.mp4"),
        ]
        
        concat_result = subprocess.run(concat_cmd, capture_output=True, text=True)
        if concat_result.returncode == 0:
            concat_output = parse_last_json(concat_result.stdout)
            final_video_path = concat_output.get("output_path", "")

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
96% confidence
Finding

This code reads prompts from a local storyboard file and transmits them to an external HTTPS API via create_one/api_request, but there is no confirmation prompt or user-facing disclosure at the point of execution. Because prompts may contain user-authored or sensitive project content, the network transmission should be explicitly surfaced to the user in this code path.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
88% confidence
Finding

This JSON sample contains user-facing natural-language fields entirely in Chinese, including the shot title, prompt, and style descriptions. Because the file provides no indication that language choice is optional or region-specific, it may violate the policy against forcing a specific language without user opt-in.

Content

No source excerpt is available for this finding.

Missing User Warnings

Low
Category
Not specified by scanner
Confidence
89% confidence
Finding

The script persists a JSON results file containing shot prompts, image URLs, and raw API responses, but the code does not visibly warn users that this data will be written to disk. Since this output may include sensitive prompt content or service response metadata, users should be informed before persistence occurs.

Content

No source excerpt is available for this finding.

Static analysis

No suspicious patterns detected.