Back to skill

Security audit

AI大模型专家|农业企业AI图片视频营销

Security checks for vulnerabilities and agentic risk

Overview

The skill largely matches its AI-HIVE agriculture marketing purpose, but it should be reviewed because its scripts handle API keys and downloaded files with unsafe scoping that could expose credentials or overwrite local files in adverse conditions.

Review this skill before installing if you will use a real AI-HIVE key or private media. Prefer environment variables over --api-key, do not set AI_HIVE_BASE_URL or --base-url unless you fully trust the endpoint, use a low-privilege API key, and run downloads in a contained output directory. Treat all agriculture origin, testing, nutrition, efficacy, pricing, and authorization claims as requiring human verification before publication.

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

T09 · Insecure Skill Coding Practices

Error
Location
scripts/imagegen.py:393
Finding

Server-Controlled Task Metadata Permits Output-Directory Traversal

Content
View full analysis
Remediation
View remediation

T09 · Insecure Skill Coding Practices

Error
Location
scripts/imagegen.py:91
Finding

Custom Base URL Can Redirect the AI-HIVE Bearer Credential to an Untrusted Server

Content
View full analysis
Remediation
View remediation

T09 · Insecure Skill Coding Practices

Warning
Location
scripts/imagegen.py:579
Finding

API Key Accepted Through Command-Line Arguments

Content
View full analysis
Remediation
View remediation

T08 · Insecure Dependencies

Note
Location
scripts/imagegen.py:7
Finding

Unpinned Third-Party Dependency Installation Guidance

Content
View full analysis
Remediation
View remediation
Vulnerability Patterns
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • Excessive AgencyUnrestricted Tool Access, Autonomous Decision Making, Scope Creep
  • Trigger AbuseOverly Broad Trigger, Shadow Command Trigger, Keyword Baiting Trigger
  • Behavioral ASTexec() Call, eval() Call, Dynamic Import
  • MCP Least PrivilegeUnderdeclared Capability, Wildcard Permission, Missing Permission Declaration
Findings (21)

Tp4

High
Category
MCP Tool Poisoning
Confidence
98% confidence
Finding

The skill asserts strong factual and authenticity boundaries for agricultural claims, but static analysis indicates there is no actual fact-checking, compliance enforcement, or provenance control in code. In this context, that is especially risky because agricultural origin, variety, process, testing, nutrition, and efficacy claims can affect consumer trust, regulatory exposure, and commercial decisions while the skill gives a false impression of safety enforcement.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
94% confidence
Finding

The skill asserts strong factual and authenticity boundaries for agricultural claims, but static analysis indicates there is no actual fact-checking, compliance enforcement, or provenance control in code. In this context, that is especially risky because agricultural origin, variety, process, testing, nutrition, and efficacy claims can affect consumer trust, regulatory exposure, and commercial decisions while the skill gives a false impression of safety enforcement.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
97% confidence
Finding

The skill asserts strong factual and authenticity boundaries for agricultural claims, but static analysis indicates there is no actual fact-checking, compliance enforcement, or provenance control in code. In this context, that is especially risky because agricultural origin, variety, process, testing, nutrition, and efficacy claims can affect consumer trust, regulatory exposure, and commercial decisions while the skill gives a false impression of safety enforcement.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
94% confidence
Finding

The skill asserts strong factual and authenticity boundaries for agricultural claims, but static analysis indicates there is no actual fact-checking, compliance enforcement, or provenance control in code. In this context, that is especially risky because agricultural origin, variety, process, testing, nutrition, and efficacy claims can affect consumer trust, regulatory exposure, and commercial decisions while the skill gives a false impression of safety enforcement.

Content

No source excerpt is available for this finding.

Undeclared Tool Scope

Medium
Category
MCP Least Privilege
Confidence
92% confidence
Finding

The skill advertises executable commands and code paths that imply access to environment variables, filesystem, network, and shell, but it does not declare any explicit tool scope or allowed-tools boundary. That creates an over-privileged integration surface where an agent may invoke capabilities broader than users would reasonably expect, increasing the chance of unintended file access, secret exposure, or command execution.

Content

No source excerpt is available for this finding.

Vague Triggers

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The activation text is very broad and overlaps with common marketing, image, and video requests, making accidental invocation likely. Overbroad triggering is dangerous because it can route ordinary user tasks into a more privileged skill path involving external services, file handling, or code execution without clear need.

Content

No source excerpt is available for this finding.

Vague Triggers

Medium
Category
Not specified by scanner
Confidence
88% confidence
Finding

The usage scenarios rely on ambiguous conditions like broad industry and capability keywords without hard boundaries, which can cause the skill to activate in contexts far outside its intended scope. Because the skill also references uploads, external model calls, and task execution, ambiguous triggering increases the risk of unnecessary data sharing, unintended charges, or misuse of privileged operations.

Content

No source excerpt is available for this finding.

Vague Triggers

Medium
Category
Not specified by scanner
Confidence
88% confidence
Finding

The default prompt is broadly phrased and can cause the skill to be invoked for a wide range of agriculture, image, video, and marketing requests without clear user intent boundaries. Because the skill also performs operational AI-HIVE actions such as querying models, uploading reference assets, saving price snapshots, routing by cost/speed, and recording task IDs, over-broad invocation increases the chance of unintended tool use, unnecessary data handling, or surprising autonomous behavior.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

Forcing Chinese output in the default prompt without checking the user's language preference can override user intent and reduce transparency, especially for multilingual or non-Chinese users. In security terms this is mainly a trust and usability issue: users may misunderstand generated plans or operational instructions, which is more concerning here because the skill may guide media generation and workflow actions.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The file presents all instructions and policy text only in Chinese, which can amount to a language/locale policy violation when no user opt-in or alternative language support is offered. There is no indication that the skill is intentionally limited to a Chinese-speaking or region-specific audience as a documented exception.

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

python
def run(args: list[str]) -> None:
    print(" ".join(args))
    subprocess.run(args, check=True)


def main() -> None:

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
94% confidence
Finding

The module docstring and user-facing interface are written as a Chinese-only tool description, and the script consistently presents prompts and operational text in Chinese. Under the stated policy, forcing a specific language without user opt-in is a natural-language policy violation unless the locale constraint is explicitly justified, which it is not here.

Content

No source excerpt is available for this finding.

Description-Behavior Mismatch

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The file contains a broader generic CLI with user-info, models, chat, image, video, task, and upload commands, while the declared skill is a specialized agriculture marketing image/video skill. This expands the callable surface beyond the manifest and can enable unintended account inspection or generic model use if the script is invoked outside the narrowed skill entrypoint.

Content

No source excerpt is available for this finding.

Context-Inappropriate Capability

Medium
Category
Not specified by scanner
Confidence
97% confidence
Finding

The skill exposes a task path that can call account-oriented functionality such as user-info/wallet retrieval in the same module even though that capability is not justified by the skill purpose. In an agent environment, hidden or adjacent account-inspection features increase the risk of unnecessary data access and scope creep with the user's API credentials.

Content

No source excerpt is available for this finding.

Context-Inappropriate Capability

Medium
Category
Not specified by scanner
Confidence
96% confidence
Finding

The module implements generic multimodal chat capability unrelated to the specialized agriculture marketing image/video workflow. That broad capability can be repurposed to send arbitrary prompts and uploaded media to external models, creating unreviewed data egress and behavior outside the declared scope of the skill.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
96% confidence
Finding

The skill embeds all core business context in Chinese string literals, including industry, mode, focus, channels, and policy boundary, with no indication that the user can opt into another language or locale. This is a natural-language policy concern because it effectively forces a specific language context rather than documenting a justified region-specific constraint or offering a choice.

Content

No source excerpt is available for this finding.

Description-Behavior Mismatch

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The manifest describes a domain-specific skill for agricultural company image/video marketing workflows, while this file implements a general-purpose AI Hive CLI including text chat, model listing, user-info, image generation, and generic media upload. Those broader capabilities go beyond the stated specialized marketing-video purpose and are not necessary implementation details for the declared skill intent.

Content

No source excerpt is available for this finding.

Context-Inappropriate Capability

Medium
Category
Not specified by scanner
Confidence
93% confidence
Finding

The manifest centers on creating and managing agricultural marketing image/video content, model selection, routing, task tracking, and asset handling. Fetching user account information and wallet balance is an account-management capability unrelated to that content-production purpose.

Content

No source excerpt is available for this finding.

Intent-Code Divergence

Low
Category
Not specified by scanner
Confidence
84% confidence
Finding

The top-level docstring describes the file as a general-purpose AI Hive tool covering text chat, image generation, video generation, model query, upload, and task polling. In contrast, the actual __main__ entrypoint uses skill_main() and a narrowed parser exposing only generate, task, upload, and init for a packaged image skill, creating contradictory intent documentation within the file.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
89% confidence
Finding

This code file contains user-facing natural-language text exclusively in Chinese in the module docstring and throughout the CLI UX. That creates a language/locale constraint without offering the user a choice or documenting that the skill is intentionally region-specific.

Content

No source excerpt is available for this finding.

Context-Inappropriate Capability

Low
Category
Not specified by scanner
Confidence
84% confidence
Finding

The manifest discusses AI-HIVE model querying, media upload, pricing snapshots, routing, polling, and task recording, but does not mention browser launching or source-attribution telemetry via the skill name in a URL. This is an auxiliary onboarding/attribution capability rather than a direct requirement of the agricultural marketing task.

Content

No source excerpt is available for this finding.