Back to skill

Security audit

AI Video Gen CN

Security checks for vulnerabilities and agentic risk

Overview

The skill mostly does what it claims, but it sends prompts/media to external AI services and has an implemented provider mismatch that can route a Runway request to LumaAI.

Install only if you are comfortable sending creative prompts, narration text, local media paths, and generated assets to configured third-party AI providers. Be especially careful with the Runway option because this version sends that path to LumaAI instead. Use a virtual environment, avoid sensitive or regulated input, pin dependencies before production use, and run the FFmpeg helper only in trusted directories with trusted filenames.

Vulnerability Patterns
  • Insecure DependenciesIntroduces malicious components through unsafe dependency sources
  • 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
Findings (3)

T08 · Insecure Dependencies

Warning
Location
requirements.txt:1
Finding

Unbounded Third-Party Dependency Versions Create Supply-Chain Risk

Content
View full analysis
=1.0.0 replicate>=0.20.0 requests>=2.31.0 pillow>=10.0.0 python-dotenv>=1.0.0 ``` ### Technical Analysis All dependencies use minimum-version constraints without upper bounds, exact version pins, or package hashes. Consequently, a future installation can retrieve package versions that were never reviewed with this Skill. Because Python packages may execute code during installation and are imported by the runtime scripts, a compromised upstream release could execute arbitrary code with the privileges of the user installing or running the Skill. The audit found no evidence that the currently named packages are malicious; the vulnerability is the absence of reproducible, integrity-verified dependency resolution. ### Attack Path 1. An attacker compromises the publisher account, distribution process, or release infrastructure of one of the permitted dependencies. 2. The attacker publishes a malicious version greater than or equal to the minimum version specified here. 3. A user follows the documented command `pip install -r requirements.txt`. 4. `pip` resolves and installs the malicious future version because it satisfies the declared constraint. 5. Malicious installation hooks or imported package code execute with the installing or running user's privileges. ### Impact Assessment Successful exploitation could allow arbitrary code execution within the Python installation context. The attacker could access files, environment variables, API credentials, and network resources available to the affected user. This does not directly grant elevated operating-system privileges unless the installation is performed from an elevated account. ]]>
Remediation
View remediation
--hash=sha256: replicate== --hash=sha256: requests== --hash=sha256: pillow== --hash=sha256: python-dotenv== --hash=sha256: ``` ]]>

T09 · Insecure Skill Coding Practices

Warning
Location
images_to_video.py:26
Finding

Predictable Temporary Manifest Allows File Clobbering and Concurrent-Execution Races

Content
View full analysis
Remediation
View remediation

T09 · Insecure Skill Coding Practices

Warning
Location
images_to_video.py:26
Finding

Image Filenames Can Inject FFmpeg Concat Manifest Directives

Content
View full analysis
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
  • Taint TrackingDirect Taint Flow, Variable-Mediated Taint Flow, Credential Exfiltration Chain
  • MCP Least PrivilegeUnderdeclared Capability, Wildcard Permission, Missing Permission Declaration
Findings (37)

Tainted flow: 'image_url' from os.getenv (line 49, credential/environment) → requests.get (network output)

Critical
Category
Data Flow
Confidence
90% confidence
Finding

Credentials or environment variables flow to a network sink. This is a high-confidence indicator of credential exfiltration.

Content

Scanner excerpt · generate_video.py (reported line 53)May include surrounding context.

python
# Download image
        img_path = self.output_dir / f"image_{int(time.time())}.png"
        img_data = requests.get(image_url).content
        with open(img_path, 'wb') as f:
            f.write(img_data)

Tainted flow: 'headers' from os.getenv (line 94, credential/environment) → requests.post (network output)

Critical
Category
Data Flow
Confidence
90% confidence
Finding

Credentials or environment variables flow to a network sink. This is a high-confidence indicator of credential exfiltration.

Content

Scanner excerpt · generate_video.py (reported line 106)May include surrounding context.

python
"prompt": prompt or "animate this image"
        }
        
        response = requests.post(
            "https://api.lumalabs.ai/dream-machine/v1/generations",
            headers=headers,
            json=data

Tainted flow: 'headers' from os.getenv (line 94, credential/environment) → requests.get (network output)

Critical
Category
Data Flow
Confidence
90% confidence
Finding

Credentials or environment variables flow to a network sink. This is a high-confidence indicator of credential exfiltration.

Content

Scanner excerpt · generate_video.py (reported line 119)May include surrounding context.

python
# Poll for completion
        while True:
            status = requests.get(
                f"https://api.lumalabs.ai/dream-machine/v1/generations/{generation_id}",
                headers=headers
            ).json()

Credential Access

High
Category
Privilege Escalation
Confidence
70% confidence
Finding

Code accesses credential files (SSH keys, AWS credentials, etc.). This could indicate credential theft attempts.

Content

Scanner excerpt · QUICK_START.md (reported line 16)May include surrounding context.

md
1. Go to https://lumalabs.ai
2. Sign up (has free tier!)
3. Get API key from dashboard

**Cost:** FREE for first 30 videos/month

Credential Access

High
Category
Privilege Escalation
Confidence
60% confidence
Finding

Code accesses credential files (SSH keys, AWS credentials, etc.). This could indicate credential theft attempts.

Content

Scanner excerpt · QUICK_START.md (reported line 26)May include surrounding context.

bash
cd skills/ai-video-gen
copy .env.example .env

Edit .env and add:

Credential Access

High
Category
Privilege Escalation
Confidence
60% confidence
Finding

Code accesses credential files (SSH keys, AWS credentials, etc.). This could indicate credential theft attempts.

Content

Scanner excerpt · README.md (reported line 28)May include surrounding context.

bash
cd skills/ai-video-gen
copy .env.example .env

Edit .env and add:

Credential Access

High
Category
Privilege Escalation
Confidence
60% confidence
Finding

Code accesses credential files (SSH keys, AWS credentials, etc.). This could indicate credential theft attempts.

Content

Scanner excerpt · README.md (reported line 29)May include surrounding context.

bash
copy .env.example .env
notepad .env

Minimum required:

Tp4

High
Category
MCP Tool Poisoning
Confidence
97% confidence
Finding

The overall primary purpose matches the description: this is indeed an AI video generation tool that performs image generation, video synthesis, optional voice-over, and final editing/combination. External services and local file output are consistent with that purpose. However, there is a material accuracy issue in the claimed supported providers: Runway support is not present despite being advertised, and the code explicitly says 'Runway support coming soon.' This makes the description overstate implemented capabilities. The mismatch is not about malicious or unrelated behavior, but about inaccurate representation of supported integrations.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
97% confidence
Finding

The declared description presents a broad end-to-end AI video generation system with multiple model providers and media-production stages. The supplied code only performs a narrow FFmpeg wrapper function: it validates input image paths, writes a concat file list, and invokes FFmpeg to stitch the images into a video. That is related to video creation, but it is materially narrower than the declared purpose and lacks the core advertised AI capabilities and integrations. Therefore, the description does not accurately represent what this code chunk actually does.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The quick-start directs users to submit prompts and optional voiceover text to OpenAI and LumaAI, but it does not warn that this content is transmitted to third-party services. Users may unknowingly send sensitive business, personal, or regulated data to external processors, creating privacy, compliance, and data-handling risk.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
92% confidence
Finding

The README instructs users to configure third-party AI/video/voice providers and describes per-video pricing, but it does not clearly warn that prompts, narration text, images, and possibly generated media will be transmitted to external services. In a skill that automates end-to-end content generation, this omission can cause unintentional disclosure of sensitive data and unexpected charges if users assume processing is local or do not understand billing implications.

Content

No source excerpt is available for this finding.

Undeclared Tool Scope

Medium
Category
MCP Least Privilege
Confidence
86% confidence
Finding

The skill advertises commands and integrations that require environment access, network calls, shell execution, and file writes, but it does not declare any explicit tool scope or permission boundaries. In an agent setting, this can cause overbroad execution authority and make it harder for users or policy engines to understand what the skill may access or modify.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
94% confidence
Finding

The documentation encourages use of third-party AI APIs with prompts, images, narration text, and possibly video content, but it does not disclose that user data may be transmitted to external services. This creates a privacy and data-governance risk, especially if users supply sensitive content under the assumption processing is local.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The script sends arbitrary user-provided --text content to OpenAI's TTS API, but it does not clearly warn users at the point of use that their text will be transmitted to a third-party service. In a video-generation skill, prompts or narration text may contain private, proprietary, or regulated information, so this can cause unintended data disclosure.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
93% confidence
Finding

User prompts and optional voiceover text are transmitted to multiple external AI providers, yet the script provides no meaningful disclosure or consent mechanism beyond progress logging. In this skill context, prompts and narration may contain proprietary, personal, or otherwise sensitive material, so silent transmission increases privacy and compliance risk.

Content

No source excerpt is available for this finding.

External Transmission

Medium
Category
Data Exfiltration
Confidence
70% 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 · generate_video.py (reported line 106)May include surrounding context.

python
"prompt": prompt or "animate this image"
        }
        
        response = requests.post(
            "https://api.lumalabs.ai/dream-machine/v1/generations",
            headers=headers,
            json=data

External Transmission

Medium
Category
Data Exfiltration
Confidence
80% 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 · generate_video.py (reported line 106)May include surrounding context.

python
"prompt": prompt or "animate this image"
        }
        
        response = requests.post(
            "https://api.lumalabs.ai/dream-machine/v1/generations",
            headers=headers,
            json=data

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 · generate_video.py (reported line 107)May include surrounding context.

python
}
        
        response = requests.post(
            "https://api.lumalabs.ai/dream-machine/v1/generations",
            headers=headers,
            json=data
        )

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 · generate_video.py (reported line 120)May include surrounding context.

python
}
        
        response = requests.post(
            "https://api.lumalabs.ai/dream-machine/v1/generations",
            headers=headers,
            json=data
        )

Tainted flow: 'generation_id' from requests.post (line 115, network input) → requests.get (network output)

Medium
Category
Data Flow
Confidence
65% confidence
Finding

Data from a source is assigned to a variable that is later passed to a sink, creating a variable-mediated taint flow.

Content

Scanner excerpt · generate_video.py (reported line 119)May include surrounding context.

python
# Poll for completion
        while True:
            status = requests.get(
                f"https://api.lumalabs.ai/dream-machine/v1/generations/{generation_id}",
                headers=headers
            ).json()

Tainted flow: 'video_url' from requests.get (line 125, network input) → requests.get (network output)

Medium
Category
Data Flow
Confidence
80% confidence
Finding

The code blindly follows a video URL obtained from a prior network response and downloads its content without validating the scheme, hostname, size, or content type. If the upstream service or response path is compromised, this can turn the script into a server-side fetch primitive and may enable unexpected internal or malicious resource access, especially in environments with network reachability to sensitive systems.

Content

Scanner excerpt · generate_video.py (reported line 135)May include surrounding context.

python
# Download video
        video_path = self.output_dir / f"video_{int(time.time())}.mp4"
        video_data = requests.get(video_url).content
        with open(video_path, 'wb') as f:
            f.write(video_data)

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 · generate_video.py (reported line 180)May include surrounding context.

python
output_path
        ]
        
        result = subprocess.run(cmd, capture_output=True, text=True)
        
        if result.returncode != 0:
            raise Exception(f"FFmpeg error: {result.stderr}")

Intent-Code Divergence

Medium
Category
Not specified by scanner
Confidence
98% confidence
Finding

The CLI claims to support Runway but silently falls back to LumaAI, causing prompts and image-derived data to be sent to a different third-party service than the user selected. In a tool that transmits potentially sensitive creative prompts and media externally, this mismatch undermines informed consent and can violate user expectations, privacy requirements, or vendor restrictions.

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 · add_voiceover.py (reported line 70)May include surrounding context.

python
]
    
    try:
        result = subprocess.run(cmd, capture_output=True, text=True, check=True)
        print(f"✅ Video created: {output_path}")
        return output_path
    except subprocess.CalledProcessError as e:

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 · images_to_video.py (reported line 47)May include surrounding context.

python
]
    
    try:
        result = subprocess.run(cmd, capture_output=True, text=True, check=True)
        print(f"✅ Video created: {output_path}")
        return output_path
    except subprocess.CalledProcessError as e:

Static analysis

No suspicious patterns detected.