Back to skill

Security audit

AI大模型专家|Amazon 亚马逊 电商图片生成与编辑

Security checks for vulnerabilities and agentic risk

Overview

The skill mostly matches an AI-HIVE image-generation workflow, but it handles API keys and media uploads with overly broad endpoint control that users should review before installing.

Review this skill before installing. Use it only with the official AI-HIVE endpoint, avoid setting --base-url or AI_HIVE_BASE_URL unless you fully trust the endpoint, and do not upload sensitive local files. Expect API-key storage under ~/.ai-hive/config.json, paid AI-HIVE task submission, reference-media uploads, polling, and result downloads to ~/Downloads/AiHive by default.

Vulnerability Patterns
  • 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
  • Embedded Malicious CodeShips malicious scripts inside the skill and executes them locally
Findings (2)

T09 · Insecure Skill Coding Practices

Error
Location
scripts/imagegen.py:90
Finding

Bearer Credential Disclosure Through an Unrestricted API Base URL

Content
View full analysis
Remediation
View remediation

T09 · Insecure Skill Coding Practices

Error
Location
scripts/imagegen.py:276
Finding

Unvalidated Server-Directed Upload and Download Destinations

Content
View full analysis
Remediation
View remediation
Vulnerability Patterns
  • Trigger AbuseOverly Broad Trigger, Shadow Command Trigger, Keyword Baiting Trigger
  • MCP Least PrivilegeUnderdeclared Capability, Wildcard Permission, Missing Permission Declaration
  • MCP Tool PoisoningHidden Instructions, Unicode Deception, Parameter Description Injection
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
Findings (10)

Description-Behavior Mismatch

High
Category
Not specified by scanner
Confidence
97% confidence
Finding

The implementation supports video generation with image, video, audio, and frame uploads despite the skill being scoped to image generation/editing. In this context, undeclared multimodal/video capability materially increases risk because it broadens what content can be uploaded, processed, and exfiltrated, and may circumvent safety, billing, or approval controls intended only for image workflows.

Content

No source excerpt is available for this finding.

Description-Behavior Mismatch

High
Category
Not specified by scanner
Confidence
96% confidence
Finding

The CLI exposes chat and video subcommands directly, making the out-of-scope capabilities readily accessible rather than merely dormant code. Because this is an agent skill, exposed commands outside the declared purpose are more dangerous: orchestrators or users may call them assuming the skill is limited to image editing, undermining least privilege and any review based on the manifest.

Content

No source excerpt is available for this finding.

Undeclared Tool Scope

Medium
Category
MCP Least Privilege
Confidence
93% confidence
Finding

The skill advertises and operationalizes code paths that can read environment data, write local files, access the network, and invoke shell commands, yet it declares no explicit tool scope or permission boundaries. In an agent setting, this creates an authority mismatch: the skill can trigger sensitive side effects without transparent least-privilege constraints, increasing the chance of secret exposure, unintended filesystem modification, or arbitrary external requests if the skill is invoked unexpectedly.

Content

No source excerpt is available for this finding.

Vague Triggers

Medium
Category
Not specified by scanner
Confidence
91% confidence
Finding

The description uses very broad trigger language spanning generic AI models, AIGC, ecommerce, advertising, image/video production, and workflow tasks, which can cause the agent to invoke this skill for loosely related requests. Over-broad routing is dangerous because this skill performs networked uploads, task submission, polling, downloads, and local config writes, so accidental invocation can lead to unintended data transfer or paid API actions.

Content

No source excerpt is available for this finding.

Vague Triggers

Medium
Category
Not specified by scanner
Confidence
90% confidence
Finding

The search-intent section is intentionally expansive, listing many platforms, model brands, tools, and adjacent content-generation scenarios without tight activation criteria. This increases the likelihood that the skill is selected for comparison-shopping or generic creative requests and then gains access to local media, credentials, network operations, or billing-backed task execution in contexts the user did not intend.

Content

No source excerpt is available for this finding.

Description-Behavior Mismatch

Medium
Category
Not specified by scanner
Confidence
94% confidence
Finding

The module docstring advertises a broader general-purpose AI tool, including chat, video generation, model querying, upload, and polling, while the declared skill is specifically for Amazon e-commerce image generation/editing. This capability/scope mismatch is dangerous because it can mislead integrators, bypass policy gating tied to the manifest, and expose users to features that were not reviewed for this skill context.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
96% confidence
Finding

This code file's docstrings, prompts, help text, and status messages are written exclusively in Chinese, which imposes a specific language/locale on all users. The file does not offer any language selection, fallback, or documented justification for the locale restriction.

Content

No source excerpt is available for this finding.

Description-Behavior Mismatch

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The code includes a text-chat API path and command handler even though the skill is presented as an image-generation/editing tool. Hidden or undeclared capabilities are risky because they can be invoked outside expected review boundaries, creating policy-evasion opportunities and expanding data exposure beyond what users and operators expect.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
95% confidence
Finding

The metadata sets language: zh-CN, which indicates a fixed language/locale preference. The file does not offer a user language choice or document a region-specific necessity that would justify enforcing this locale.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
93% confidence
Finding

The sample API key value includes Chinese text ('请替换为你的APIKey'), which imposes a specific language in user-facing configuration content. This can violate language/locale policy when the file does not offer a language choice or explain a locale-specific requirement.

Content

No source excerpt is available for this finding.