Back to skill

Security audit

AI电商专家|抖音电商 图片视频全内容

Security checks for vulnerabilities and agentic risk

Overview

The skill appears to support the stated ecommerce content workflow, but it runs a mutable external npm package and forwards the full local environment to it.

Review before installing. Use only in an environment where sending product materials and prompts to IMIVA is acceptable, avoid running it with unrelated secrets in the environment, and prefer a pinned/reviewed MCP package version with a minimized environment allowlist.

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

T08 · Insecure Dependencies

Error
Location
scripts/imiva_mcp.py:14
Finding

Automatic Execution of an Unpinned npm Package

Content
View full analysis
Remediation
View remediation

T09 · Insecure Skill Coding Practices

Error
Location
scripts/imiva_mcp.py:50
Finding

Third-Party Child Process Inherits the Complete Parent Environment

Content
View full analysis
dict: npx, token = require_runtime() env = os.environ.copy() env["MCP_TOKEN"] = token env["API_URL"] = os.environ.get("IMIVA_API_URL", os.environ.get("API_URL", DEFAULT_API_URL)) proc = subprocess.Popen( [npx, "-y", PACKAGE], stdin=subprocess.PIPE, stdout=subprocess.PIPE, stderr=subprocess.PIPE, text=True, bufsize=1, env=env, ) ``` ### Technical Analysis The helper copies the entire parent environment using `os.environ.copy()` and passes it to the npm package. Only a limited set of variables is necessary for the declared workflow, principally the executable search path, `MCP_TOKEN`, and the API endpoint. Agent and development environments commonly contain unrelated secrets, including cloud access keys, source-control tokens, CI credentials, proxy credentials, database connection strings, and tokens for other services. Any code executed by the child process can enumerate these values without requiring further permissions. This exposure is especially significant because the child is retrieved through the unpinned `@latest` dependency described in the preceding finding. If that dependency is compromised, all inherited environment secrets become immediately available to attacker-controlled code. The API endpoint is also accepted directly from `IMIVA_API_URL` or `API_URL` without enforcing HTTPS or validating the destination against a trusted hostname. This enables environment-level configuration to redirect the MCP client away from the documented IMIVA endpoint. Whether credentials are transmitted to that destination depends on the downstream package's implementation, but the helper provides both the endpoint and token to that process. ...[truncated 1619 chars]
Remediation
View remediation
Vulnerability Patterns
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • 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
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
Findings (9)

Env Variable Harvesting

High
Category
Data Exfiltration
Confidence
60% confidence
Finding

Code enumerates, copies, or searches environment variables for secrets. Bulk environment access can collect credentials unrelated to the skill's stated purpose.

Content

Scanner excerpt · scripts/imiva_mcp.py (reported line 51)May include surrounding context.

python
def invoke(method: str, params: dict | None = None) -> dict:
    npx, token = require_runtime()
    env = os.environ.copy()
    env["MCP_TOKEN"] = token
    env["API_URL"] = os.environ.get("IMIVA_API_URL", os.environ.get("API_URL", DEFAULT_API_URL))
    proc = subprocess.Popen(

Undeclared Tool Scope

Medium
Category
MCP Least Privilege
Confidence
90% confidence
Finding

The skill includes shell commands, environment-variable handling, and file-path based operations, but it does not declare a restrictive tool scope such as allowed-tools or permissions. In an agent environment, that increases the chance the skill can access broader local resources or execute helper commands than users expect, especially because it instructs use of local files and token-bearing environment variables.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
92% confidence
Finding

Line L054 states the skill is especially suitable for Chinese users, which establishes a language/locale preference in the skill’s natural-language instructions. The file does not offer an alternative language option or make this an explicit user opt-in, so it conflicts with the policy against forcing a specific language or locale without choice.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
89% confidence
Finding

The display name, description, and default prompt are entirely in Chinese and direct use of a specific Chinese e-commerce context, with no indication that users can choose another language or locale. This can violate language/locale policy when the skill is presented to users who have not opted into Chinese-language interaction.

Content

No source excerpt is available for this finding.

Vague Triggers

Medium
Category
Not specified by scanner
Confidence
92% confidence
Finding

The skill enables implicit invocation but does not define any narrow activation boundaries, so it may be auto-selected in conversations where the user did not explicitly request this ecommerce workflow. Because the skill can trigger downstream MCP-backed content generation behavior, overly broad invocation increases the chance of unintended tool use, surprise data handling, or confusing the user about why the skill was activated.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
87% confidence
Finding

The script passes MCP_TOKEN and tool-call arguments to an external MCP process that then communicates with a remote API, but the code does not clearly warn the user that credentials and potentially sensitive content will leave the local environment. In an ecommerce-content workflow, inputs may include proprietary product assets, marketing plans, or customer-adjacent business data, making silent transmission more sensitive.

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

python
env = os.environ.copy()
    env["MCP_TOKEN"] = token
    env["API_URL"] = os.environ.get("IMIVA_API_URL", os.environ.get("API_URL", DEFAULT_API_URL))
    proc = subprocess.Popen(
        [npx, "-y", PACKAGE],
        stdin=subprocess.PIPE,
        stdout=subprocess.PIPE,

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
93% confidence
Finding

This script executes a remote npm package (npx -y @infimind/ecom-content-cli@latest) without any interactive confirmation or in-code warning. That creates a supply-chain trust issue: users may not realize they are fetching and running code from the npm ecosystem, and @latest allows behavior to change over time without review.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
95% confidence
Finding

The script's error messages and CLI description/help strings are written in Chinese, and there is no indication that the user can select another language or that the tool is intentionally limited to a Chinese-speaking audience. This can violate language/locale policy where user-facing output should not force a specific language without opt-in or clear justification.

Content

No source excerpt is available for this finding.