Back to skill

Security audit

Shopify Helper

Security checks for vulnerabilities and agentic risk

Overview

The Shopify helper mostly provides store-building advice, but it also includes a mismatched local logging utility that can persist whatever users type.

Review this before installing. The Shopify advice script appears non-destructive, but the package also includes a generic local command that stores command arguments and arbitrary entries on disk. Do not pass credentials, customer data, tokens, or sensitive store details to it unless the publisher clarifies and fixes the logging, permissions, and command-scope mismatch.

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

T09 · Insecure Skill Coding Practices

Warning
Location
scripts/script.sh:5
Finding

Undocumented Persistent Storage of Command Arguments Without Restrictive Permissions

Content
View full analysis

Vulnerability Details

File Location: scripts/script.sh, lines 5-7 and 33-73
Vulnerability Type: Plaintext sensitive-data retention and insecure file handling
Risk Level: Medium

Vulnerable Code

bash
DATA_DIR="${SHOPIFY_HELPER_DIR:-${XDG_DATA_HOME:-$HOME/.local/share}/shopify-helper}"
DB="$DATA_DIR/data.log"
mkdir -p "$DATA_DIR"
bash
_log() { echo "$(date '+%m-%d %H:%M') $1: $2" >> "$DATA_DIR/history.log"; }

cmd_run() {
    echo "  Running: $1"
    _log "run" "${1:-}"
}

cmd_config() {
    echo "  Config: $DATA_DIR/config.json"
    _log "config" "${1:-}"
}

cmd_status() {
    echo "  Status: ready"
    _log "status" "${1:-}"
}

cmd_init() {
    echo "  Initialized in $DATA_DIR"
    _log "init" "${1:-}"
}

cmd_list() {
    [ -f "$DB" ] && cat "$DB" || echo "  (empty)"
    _log "list" "${1:-}"
}

cmd_add() {
    echo "$(date +%Y-%m-%d) $*" >> "$DB"; echo "  Added: $*"
    _log "add" "${1:-}"
}

cmd_remove() {
    echo "  Removed: $1"
    _log "remove" "${1:-}"
}

cmd_search() {
    grep -i "$1" "$DB" 2>/dev/null || echo "  Not found: $1"
    _log "search" "${1:-}"
}

cmd_export() {
    [ -f "$DB" ] && cat "$DB" || echo "No data"
    _log "export" "${1:-}"
}

cmd_info() {
    echo "  Version: $VERSION | Data: $DATA_DIR"
    _log "info" "${1:-}"
}

Technical Analysis

The script persistently records raw command arguments in history.log, while the add command stores all supplied arguments in data.log. This behavior is not disclosed in the skill documentation and is unrelated to the documented Shopify advisory commands.

No restrictive umask is established, and the directory and log files are not explicitly assigned owner-only permissions. Their effective permissions therefore depend on the invoking environment's existing umask. On systems with permissive defaults, other local users or processes may be able to read business information, search terms, product details, or secrets accidentally supplied a ...[truncated 1889 chars]

Remediation
View remediation

Remediation Suggestions

  1. Remove scripts/script.sh if the generic storage utility is not required for the documented Shopify skill.
  2. Explicitly disclose any persistent logging, including the stored fields, storage location, retention period, and deletion procedure.
  3. Avoid logging raw user arguments. Store only the minimum operational metadata required, and redact credentials, access tokens, email addresses, and other sensitive values.
  4. Establish restrictive permissions before creating data:
bash
umask 077
install -d -m 0700 -- "$DATA_DIR"
touch -- "$DB" "$DATA_DIR/history.log"
chmod 0600 -- "$DB" "$DATA_DIR/history.log"
  1. Validate and constrain SHOPIFY_HELPER_DIR. Reject empty, unexpected, relative, or untrusted locations where appropriate.
  2. Refuse symbolic-link log targets before writing, and open files using a mechanism that provides no-follow and exclusive-creation protections where available.
  3. Avoid executing the utility with elevated privileges. If elevated operation is unavoidable, use a fixed, administrator-owned data directory that unprivileged users cannot modify.
  4. Add explicit data-retention and secure-deletion commands, and test permissions under different host umask configurations.
Vulnerability Patterns
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Trigger AbuseOverly Broad Trigger, Shadow Command Trigger, Keyword Baiting Trigger
  • MCP Tool PoisoningHidden Instructions, Unicode Deception, Parameter Description Injection
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
Findings (8)

Tp4

High
Category
MCP Tool Poisoning
Confidence
99% confidence
Finding

The declared description presents a Shopify-focused assistant for e-commerce store creation and optimization. However, the code implements a generic shell command-line tool that stores and retrieves arbitrary text entries from local files and logs command usage. It does not interact with Shopify APIs, themes, products, SEO settings, apps, or deployment workflows. Its primary purpose is materially different from the declared Shopify assistant role, so this is a clear description-behavior mismatch.

Content

No source excerpt is available for this finding.

Description-Behavior Mismatch

High
Category
Not specified by scanner
Confidence
98% confidence
Finding

The implementation materially diverges from the declared Shopify-specific purpose and instead behaves as a generic local logging/notes utility. This is dangerous because users may grant trust and provide store-related or sensitive business data under the assumption the skill performs Shopify operations, while the script silently stores data locally and offers unrelated behavior.

Content

No source excerpt is available for this finding.

Intent-Code Divergence

Medium
Category
Not specified by scanner
Confidence
92% confidence
Finding

The script’s own help text advertises a generic 'Multi-purpose utility tool,' which conflicts with the Shopify-focused metadata. Contradictory identity and purpose are a supply-chain trust issue: they can conceal unexpected behavior, mislead reviewers, and make it harder for users to understand what data the tool handles.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
98% confidence
Finding

The script logs command names and arguments to a persistent history file without notifying the user. Because arguments may contain sensitive Shopify-related information, this creates a stealthy audit trail of potentially confidential data that could be read by other local processes, backups, or future users of the machine.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
96% confidence
Finding

The add command persists arbitrary user-supplied input to a local log database without prior disclosure in the header or help text. In a Shopify-assistant context, users may enter product details, credentials, URLs, customer information, or other sensitive business data, causing unintended local data retention and possible later exposure.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
96% confidence
Finding

The script presents itself as a Shopify helper but the visible instructional content is written in Chinese, and there is no indication that users may choose another language. This creates a language/locale policy concern because the skill effectively imposes a specific language without opt-in or documented justification.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

This markdown file presents all user-facing guidance in Chinese, starting with the section headings and continuing through the recommendations. Under the policy rule, forcing a specific language without user opt-in or a documented justification can be a natural-language policy violation.

Content

No source excerpt is available for this finding.

Vague Triggers

Low
Category
Not specified by scanner
Confidence
91% confidence
Finding

The description says "Use when building or optimizing Shopify stores," which is a broad activation condition without explicit boundaries, exclusions, or negative examples. This could overlap with many general ecommerce conversations and does not clearly define when the skill should or should not be invoked.

Content

No source excerpt is available for this finding.

Static analysis

No suspicious patterns detected.