Back to skill

Security audit

AI电商专家|食品饮料电商图片视频

Security checks for vulnerabilities and agentic risk

Overview

The skill is purpose-aligned for IMIVA ecommerce content generation, but it needs review because it runs an unpinned remote npm package and forwards the full local environment to it.

Install only if you trust the IMIVA/npm package path and are comfortable running downloaded code locally. Prefer a pinned package version, run it in a restricted environment, provide a narrowly scoped revocable MCP token, and avoid invoking it from shells that contain unrelated cloud, repository, or production secrets.

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

Unpinned npm Dependency Enables Mutable Remote Code Execution

Content
View full analysis
Remediation
View remediation

T09 · Insecure Skill Coding Practices

Warning
Location
scripts/imiva_mcp.py:51
Finding

Child Process Receives the Entire Parent Environment and Supports an Unrestricted Credential Destination

Content
View full analysis
Remediation
View remediation
Vulnerability Patterns
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Supply ChainUnpinned Dependencies, External Script Fetching, Obfuscated Code
  • 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 (8)

Env Variable Harvesting

High
Category
Data Exfiltration
Confidence
88% confidence
Finding

os.environ.copy() forwards the entire parent environment into the spawned npm process, not just the intended token and API URL. If the remote package or any dependency is malicious or compromised, it may read unrelated secrets from inherited variables such as cloud credentials, CI tokens, proxies, or internal endpoints.

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
91% confidence
Finding

The skill documents shell commands, environment-variable use, and local file access patterns, but it does not declare any explicit tool scope such as allowed-tools or permissions. In an agent environment, that increases the chance the skill is invoked with broader-than-necessary capabilities, enabling unintended file reads, shell execution, or exposure of sensitive environment data if the runtime does not sandbox strictly.

Content

No source excerpt is available for this finding.

Vague Triggers

Medium
Category
Not specified by scanner
Confidence
90% confidence
Finding

The description contains broad English routing text such as 'Use this skill for IMIVA ecommerce content...' that can match many generic ecommerce requests. Overbroad trigger phrasing can cause accidental skill selection, leading the agent to inappropriately access local files, invoke external services, or steer users into this workflow when a narrower skill would be safer and more appropriate.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
81% confidence
Finding

The metadata sets language: zh-CN, and the document later emphasizes it is for "中文用户". This indicates a language/locale constraint in the skill's natural-language behavior, but the file does not offer user opt-in or explain a necessary region-specific reason for enforcing that language scope.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
87% confidence
Finding

The code reads MCP_TOKEN from the environment and then passes it into the spawned subprocess environment. Although the token is required for functionality, this file does not include a user-facing warning, comment, or documentation note explaining that a credential will be consumed and exposed to the child process.

Content

No source excerpt is available for this finding.

subprocess module call

Medium
Category
Dangerous Code Execution
Confidence
91% confidence
Finding

The code launches npx -y @infimind/ecom-content-cli@latest, which can fetch and execute a remote npm package at runtime. Using the mutable latest tag means the exact code executed is not pinned or reviewed in advance, creating a software supply-chain execution risk if the package or dependency chain is compromised.

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
95% confidence
Finding

This subprocess execution path silently invokes a remote npm package without warning the operator that code may be downloaded and run from the network. In a security-sensitive enterprise skill, hidden remote code execution significantly increases trust and supply-chain risk, especially because the package spec uses @latest.

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 command descriptions are written in Chinese, and there is no indication that language selection is configurable or that the tool is intentionally limited to Chinese-speaking users. This can violate language/locale policy where skills should not force a specific language without user opt-in or explicit justification.

Content

No source excerpt is available for this finding.