T09 · Insecure Skill Coding Practices
- Location
scripts/videogen.py:91- Finding
Arbitrary API Base URL Can Expose the AI-HIVE Bearer Credential
- Content
View full analysis
- Remediation
View remediation
Security audit
Security checks for vulnerabilities and agentic risk
The skill is mostly a disclosed AI-HIVE video-generation workflow, but it has a real API-key handling risk that users should review before installing.
Install only if you trust the AI-HIVE workflow and are comfortable storing an API key locally. Do not set AI_HIVE_BASE_URL or --base-url to anything except the intended AI-HIVE HTTPS endpoint, and rotate the API key if it may have been used with an untrusted endpoint.
scripts/videogen.py:91Arbitrary API Base URL Can Expose the AI-HIVE Bearer Credential
This mismatch is more security-relevant because it includes undeclared behaviors such as account/wallet retrieval, model enumeration, browser-based API key setup, and local credential storage. Undeclared credential handling and account-data access expand the attack surface and can lead users to expose secrets or authorize actions they did not reasonably expect from the skill.
This mismatch is more security-relevant because it includes undeclared behaviors such as account/wallet retrieval, model enumeration, browser-based API key setup, and local credential storage. Undeclared credential handling and account-data access expand the attack surface and can lead users to expose secrets or authorize actions they did not reasonably expect from the skill.
This mismatch is more security-relevant because it includes undeclared behaviors such as account/wallet retrieval, model enumeration, browser-based API key setup, and local credential storage. Undeclared credential handling and account-data access expand the attack surface and can lead users to expose secrets or authorize actions they did not reasonably expect from the skill.
The skill advertises code-driven operations involving environment variables, local files, networking, and shell commands, but it declares no explicit tool scope or permission boundaries. In an agent environment, this increases the chance that the skill can trigger broader-than-expected file/system/network actions without clear operator review, especially because it also references API keys, local paths, ffmpeg, and remote API usage.
The natural-language instruction in the default prompt says to produce a "production-ready Chinese workflow," which imposes a specific language choice by default. This is a language/locale policy issue because the file does not offer the user an explicit choice or opt-in for Chinese output.
The file hard-codes Chinese-language skill descriptions, CLI metadata, and search aliases such as '爆款视频原创复刻工作台|AI-HIVE' and related Chinese trigger terms. There is no indication that users can choose another language or that this locale restriction is documented as an explicit region-specific requirement, which makes this a natural-language policy concern.
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 module docstring states it wraps text chat, image generation, video generation, model queries, media upload, and task polling as a general AI capability tool, and the code implements corresponding commands such as chat and image. The manifest describes a specialized skill for authorized viral-video original remake workflows centered on analysis, creative adaptation, generation, and delivery via AI-HIVE, not a broad general-purpose chat/image tool.
The module docstring presents the skill entirely in Chinese as the default interaction language, and the rest of the user-facing strings follow that same fixed locale. For a general-purpose skill, this constitutes a language/locale constraint that is not presented as optional or region-specific.
The get_user_info endpoint and the user-info CLI command retrieve user information and wallet balance, as reflected again in the parser help text. Account/balance inspection is ancillary platform administration functionality and is not part of the manifest’s described purpose of producing authorized original-remake video deliverables.
The generated SKILL_CONFIG hard-codes Chinese-language discovery and presentation metadata for the skill, which can force a specific language experience in activation and display. There is no indication that the user can choose another language or that this is a region-limited skill.
The code implements model listing and filtering, and exposes it through the models command. While internal model lookup for generation may be expected, a user-facing capability to enumerate the full platform model catalog is broader than the manifest’s narrowly described remake workstation behavior.