T09 · Insecure Skill Coding Practices
- Location
scripts/videogen.py:101- Finding
Bearer API Key Can Be Forwarded to an Untrusted Custom Base URL
- Content
View full analysis
- Remediation
View remediation
Security audit
Security checks for vulnerabilities and agentic risk
The skill is not clearly malicious, but it can use an AI-HIVE API key to upload, generate, poll, and download media, which is broader and more sensitive than the analyzer branding suggests.
Review this before installing. Use a limited AI-HIVE API key, avoid custom base URLs unless you fully control the endpoint, and require explicit confirmation before any upload or generation because those actions may expose media and consume paid credits. Do not paste real API keys into chat logs or project files.
scripts/videogen.py:101Bearer API Key Can Be Forwarded to an Untrusted Custom Base URL
scripts/videogen.py:6Third-Party Dependency Is Installed Without Version or Integrity Pinning
This mismatch is more security-relevant because the skill is presented as a subtitle/copy analysis assistant while apparently enabling broader AI-HIVE account and media operations such as account info retrieval, model/pricing queries, uploads, and downloads. If users invoke it expecting low-risk text analysis, the hidden expansion into networked account/resource actions can lead to unintended data disclosure, billing exposure, or external content transfer.
This mismatch is more security-relevant because the skill is presented as a subtitle/copy analysis assistant while apparently enabling broader AI-HIVE account and media operations such as account info retrieval, model/pricing queries, uploads, and downloads. If users invoke it expecting low-risk text analysis, the hidden expansion into networked account/resource actions can lead to unintended data disclosure, billing exposure, or external content transfer.
This mismatch is more security-relevant because the skill is presented as a subtitle/copy analysis assistant while apparently enabling broader AI-HIVE account and media operations such as account info retrieval, model/pricing queries, uploads, and downloads. If users invoke it expecting low-risk text analysis, the hidden expansion into networked account/resource actions can lead to unintended data disclosure, billing exposure, or external content transfer.
The file is presented as a caption/copy analysis skill, but the implementation is a general AI Hive client for chat, image, and video generation. This mismatch can mislead users and higher-level agents into invoking media generation, uploads, browser opening, polling, and file download behaviors they did not intend to authorize, expanding the skill's effective capability surface.
The embedded configuration brands the tool as a viral-caption/copy analyzer but binds only to text-to-video, image-to-video, and reference-to-video models. This is a capability deception issue: consumers may trust the branding and hand over prompts or assets expecting analysis, while the code actually submits them to media-generation services.
The skill-specific entrypoint routes the primary generate action into video generation rather than subtitle/copy analysis. In an agent ecosystem, this is dangerous because orchestration may select the skill based on its advertised analysis purpose, yet execution triggers remote content generation and associated side effects.
The skill advertises and demonstrates capabilities that imply network access, shell execution, file I/O, and environment-variable use, but it declares no explicit tool scope or permission boundary. That creates an authorization ambiguity where a caller or host may grant broader capabilities than users expect, increasing the chance of unintended external calls, local file access, or secret handling during skill execution.
The default prompt explicitly instructs the skill to produce a "production-ready Chinese workflow," which imposes a language choice regardless of user preference. This is a natural-language policy concern because the file does not offer an alternative language option or document that the locale restriction is intentional and user-approved.
allow_implicit_invocation: true lets the platform auto-activate this skill without a tightly scoped trigger boundary. Because the skill is capable of generating production-ready workflows and runnable AI-HIVE commands, broad implicit activation increases the chance of unintended execution paths, overbroad prompt capture, or misuse in contexts the user did not clearly authorize.
The skill’s natural-language identifiers and defaults are entirely in Chinese, including the description, argument description, skill name, and search aliases, with no indication that users can choose another language. This can violate language/locale policy when a skill implicitly constrains interaction to one language without explicit opt-in or documented justification.
subprocess module calls execute external commands. Without careful input validation, this enables command injection.
def run(args: list[str]) -> None:
print(" ".join(args))
subprocess.run(args, check=True)
def main() -> None:
The manifest describes a skill focused on analyzing and rewriting subtitles, spoken copy, CTA text, and optionally using AI-HIVE APIs for asset-generation workflows. This script instead performs direct local video-editing operations such as trimming, aspect-ratio conversion, muting audio, loudness normalization, and concatenation via ffmpeg, which are production media-processing capabilities not justified by the stated text/caption-analysis role.
The module docstring is written entirely in Chinese and presents the tool as a general-purpose skill, while user-facing prompts and guidance throughout the file are also fixed in Chinese. For a broadly scoped skill, this creates a language/locale constraint without offering the user any language choice or documenting that the skill is region-specific.
The parser description claims subtitle/copy decomposition while the code labels itself as a raw video skill and exposes video-generation commands. Although primarily a trust and integrity issue rather than code execution, this inconsistency increases the chance of unsafe invocation and unintended data transfer in automated tool selection contexts.
This code writes a JSON file to a user-supplied path and will overwrite existing content at that location, but there is no confirmation prompt, warning message, or explanatory comment/docstring disclosing that behavior. Because file modification is a safety-relevant operation in code files, users should be clearly informed before or during execution.
The skill creates an output directory and downloads generated media files into it automatically. Although the code shows download progress, it does not clearly warn the user beforehand in a docstring/comment/help text that running generation will write files under the default Downloads path.