T08 · Insecure Dependencies
- Location
scripts/build_payload.py:152- Finding
Automatic Installation of Unpinned Third-Party Packages at Runtime
- Content
View full analysis
- Remediation
View remediation
Security audit
Security checks for vulnerabilities and agentic risk
The skill is mainly a video-editing workflow, but it uses broad local and network authority with under-disclosed external processing and runtime package installation.
Review this skill before installing. Use it only for videos you are comfortable sending to external AI/media services, run it in an isolated environment, avoid --break-system-packages, require explicit approval before draft creation or uploads, and do not use confidential media unless the remote-service behavior is fully understood.
scripts/build_payload.py:152Automatic Installation of Unpinned Third-Party Packages at Runtime
scripts/run_clip_pipeline.py:238Model-Controlled Content Is Written to an HTML Preview Without Escaping
{h.get("hook","")}
scripts/run_clip_pipeline.py:204Unvalidated Server-Provided Download URL Enables SSRF and Unbounded Downloads
scripts/run_clip_pipeline.py:66Remote Media and Transcript Disclosure Is Inconsistent With the Documented Privacy Boundary
This mismatch specifically matters because it hides use of external services and different output behaviors than advertised, including external API dependence and different artifact generation. In a media-processing skill, undeclared third-party processing can expose user content, prompts, or metadata to outside services without clear consent.
This mismatch specifically matters because it hides use of external services and different output behaviors than advertised, including external API dependence and different artifact generation. In a media-processing skill, undeclared third-party processing can expose user content, prompts, or metadata to outside services without clear consent.
This mismatch specifically matters because it hides use of external services and different output behaviors than advertised, including external API dependence and different artifact generation. In a media-processing skill, undeclared third-party processing can expose user content, prompts, or metadata to outside services without clear consent.
This mismatch specifically matters because it hides use of external services and different output behaviors than advertised, including external API dependence and different artifact generation. In a media-processing skill, undeclared third-party processing can expose user content, prompts, or metadata to outside services without clear consent.
This mismatch specifically matters because it hides use of external services and different output behaviors than advertised, including external API dependence and different artifact generation. In a media-processing skill, undeclared third-party processing can expose user content, prompts, or metadata to outside services without clear consent.
This code calls Anthropic's API even though the skill metadata only declares local Whisper, Qwen-VL-Plus, and edge-tts. The hidden external model dependency causes undisclosed data transmission and expands the trust boundary, especially because prompts may include movie names, character data, and event descriptions derived from user content.
The code dynamically installs a package at runtime for a feature that is not essential to safe execution of the stated skill and does so without isolation or verification. This introduces supply-chain risk, environment tampering, and operational instability that are disproportionate to the skill's video-editing purpose.
The skill declares no explicit tool/permission scope while its instructions require filesystem access, environment variable access, shell execution, and network use. In an agent environment, that mismatch can grant the model broad operational latitude without clear guardrails, increasing the chance of unintended file access, command execution, or data exfiltration.
The invocation triggers are very broad and overlap with ordinary conversation about videos, subtitles, narration, and editing. That increases the chance the skill activates unexpectedly and gains access to shell, files, network, or local media-processing behavior in contexts where the user did not intend to invoke such a powerful workflow.
The documentation first states that every run must produce exactly four files in the output directory: narration MP3s, subtitles.srt, clip MP4s, and draft_content.json. Later, Step 7 explicitly says a valid importable draft requires two draft files, draft_meta_info.json and draft_content.json, which makes the earlier 'exactly 4 files' contract inaccurate and contradictory.
The file states requirements and user prompts in Chinese and defaults the narration voice to zh-CN-XiaoxiaoNeural, while the narration prompt also mandates a specific Chinese stylistic output. There is no explicit language-choice step or opt-in allowing users to select another language or locale.
The instruction to show all clips with no truncation, even for large inputs, can force very large model outputs and excessive token consumption. In agent settings this can create denial-of-service style failures, context flooding, cost amplification, and reduced visibility of important warnings or approval details.
**Rules for this display:**
- Show ALL clips, no truncation — even if there are 20+ clips
- Each clip box must contain: stage, source timestamp range, estimated duration, full narration text, output filenames
- Show project name WITH conflict suffix (e.g. `误判(1)`) so user sees the final name before committing
- Wait for explicit user approval before proceeding to Step 4
Data is being sent to an external URL. This could be legitimate telemetry or data exfiltration. Manual review is recommended.
}
}
resp = requests.post(f"{api_base}/api/v1/generate", json=payload, timeout=60)
resp.raise_for_status()
result = resp.json()
The code automatically runs pip install at runtime with '--break-system-packages' if openai is missing. This creates a supply-chain and environment-integrity risk because execution can modify the host Python environment and fetch remote code without explicit user consent or deployment-time pinning.
from openai import OpenAI
except ImportError:
import subprocess, sys
subprocess.run([sys.executable, "-m", "pip", "install", "openai",
"--break-system-packages", "-q"], check=True)
from openai import OpenAI
subprocess module calls execute external commands. Without careful input validation, this enables command injection.
def extract_frame(video_path: str, timestamp: float, output_path: str):
"""Extract a single frame from the video at `timestamp` seconds."""
subprocess.run([
"ffmpeg", "-y", "-ss", str(timestamp),
"-i", video_path, "-vframes", "1",
"-q:v", "2", output_path
The skill advertises clip analysis and CapCut draft generation, but this section also renders a final MP4. That scope expansion means the skill performs additional file-processing actions beyond its declared behavior, increasing attack surface and creating a capability mismatch that can surprise users and reviewers.
The concat render path invokes ffmpeg with '-safe 0' on a generated concat file, disabling ffmpeg's path safety checks. Because clip paths flow into concat.txt and the skill handles user-supplied media workflows, this increases exposure to unsafe file references and risky ffmpeg processing of untrusted inputs.
f.write(f"file '{os.path.abspath(p)}'\n")
output_path = os.path.join(output_dir, "output_video.mp4")
subprocess.run([
"ffmpeg", "-y",
"-f", "concat", "-safe", "0", "-i", concat_path,
"-vf", f"scale={original_width}:{original_height}"
The prompt hard-codes Chinese instructions and output requirements, including Chinese stylistic references and length measured in Chinese characters, with no option for the user to choose language or locale. This is a natural-language policy violation because it enforces a specific language without explicit opt-in or documented regional justification.
The Anthropic request sends generated prompt content to an external service without any visible user-facing disclosure or consent flow. In this skill context, the prompt may embed details extracted from uploaded video content, making the undisclosed transmission a privacy and compliance issue.
The code transmits content to https://api.anthropic.com/, creating an external data egress path not reflected in the declared skill description. Because the request is built from narration prompt content derived from user media context, this can expose sensitive or copyrighted material to a third party.
}).encode()
req = urllib.request.Request(
"https://api.anthropic.com/v1/messages",
data=payload,
headers={"Content-Type": "application/json"},
method="POST"
The skill enumerates local JianYing/CapCut draft directories to detect naming conflicts, which exceeds the minimally necessary access for clip analysis. Probing local application data reveals information about the user's installed software and project names, creating unnecessary privacy exposure and filesystem access beyond the advertised core function.
Skill enables autonomous high-impact decisions without human-in-the-loop verification. Critical operations (destructive commands, financial transactions, data deletion) should require explicit user confirmation.
"""
draft_dir = next((d for d in JIANYING_DRAFT_DIRS if os.path.isdir(d)), None)
if not draft_dir:
return base_name # draft dir not found, proceed without checking
existing = set(os.listdir(draft_dir))
if base_name not in existing:
The function performs state-changing MCP operations (create_draft, add_video, add_audio, add_text, add_subtitle, save_draft) immediately when called, while the only approval control is a comment and a separate preview helper that is never enforced. In an agent setting, this can cause unintended project creation or modification from ambiguous prompts, prompt-injection-influenced workflows, or accidental invocation without explicit user consent.
VOICE_DEFAULT is hard-coded to zh-CN-XiaoxiaoNeural, and the script also includes Chinese fallback/output text, which establishes a default language/locale choice. There is no visible user opt-in, locale selection flow, or documentation justifying why Chinese is mandatory for this skill.
Allowing the skill to install packages dynamically at runtime is broader than necessary for video editing and gives the skill the ability to fetch and execute new code on demand. In an agent setting, that materially increases risk because execution behavior can change after deployment without review.
No suspicious patterns detected.