Back to skill

Security audit

shop-app-research

Security checks for vulnerabilities and agentic risk

Overview

The skill mostly matches its stated Shop.app research purpose, but its helper can make broader authenticated Crawlora API calls than the documented read-only endpoints require.

Review this skill before installing if you use a Crawlora key with paid credits or broader account authority. The fixed API host and disclosed key handling are good signs, but the helper should ideally be tightened to GET-only and exact documented endpoint shapes before routine use.

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/crawlora.sh:41
Finding
Overbroad API Route and HTTP Method Allowlist<![CDATA[ ## Vulnerability Details **File Location**: `scripts/crawlora.sh`, lines 41–72 **Vulnerability Type**: Overbroad authenticated API access caused by permissive wildcard routing and unnecessary HTTP methods **Risk Level**: Medium ### Vulnerable Code ```bash case "$method" in GET|POST) ;; *) echo "only GET and POST are supported by the shop-app-research skill" >&2 exit 2 ;; esac # Reject path syntax that could smuggle a route through a shell glob check. case "$path" in ""|*[?#%]*|*..*|*//* ) echo "invalid path for the shop-app-research skill" >&2 exit 2 ;; esac case "$path" in /shop-app/analysis) ;; /shop-app/categories) ;; /shop-app/products/*) ;; /shop-app/products/*/related) ;; /shop-app/products/*/reviews) ;; /shop-app/products/*/shop) ;; /shop-app/products/*/variant) ;; /shop-app/products/*/variants) ;; /shop-app/search) ;; /shop-app/shops/*) ;; /shop-app/shops/*/collections/*/products) ;; /shop-app/shops/*/locations) ;; /shop-app/shops/*/products) ;; /shop-app/shops/*/reviews) ;; /shop-app/shops/*/typeahead) ;; /shop-app/suggestions) ;; *) echo "path is not in the shop-app-research skill catalog" >&2 exit 2 ;; esac ``` ### Technical Analysis The documented Shop.app catalog contains only GET endpoints, but the helper permits both `GET` and `POST`. Allowing POST therefore exceeds the HTTP privileges required for the Skill's declared read-only public-data research functionality. The route validation also uses Bash glob patterns that are broader than the documented endpoints: - `/shop-app/products/*` - `/shop-app/shops/*` In Bash `case` matching, `*` can match slash characters and arbitrarily many path segments. As a result, `/shop-app/products/*` accepts any nested route beneath `/shop-app/products/`, while `/shop-app/shops/*` accepts any nested route beneath `/shop-app/shops/`. The later, more specific patterns do not narrow these broad matches. The helper subsequent ...[truncated 2390 chars]
Remediation
<![CDATA[ ## Remediation Suggestions 1. Restrict the helper to GET requests unless a documented endpoint explicitly requires another method: ```bash if [ "$method" != "GET" ]; then echo "only GET is supported by the shop-app-research skill" >&2 exit 2 fi ``` 2. Replace broad shell globs with anchored, segment-aware regular expressions. Ensure product IDs, shop handles, and collection IDs each occupy exactly one path segment. 3. Validate the route against explicit endpoint shapes, for example: ```bash if [[ "$path" =~ ^/shop-app/(analysis|categories|search|suggestions)$ ]] || [[ "$path" =~ ^/shop-app/products/[^/]+$ ]] || [[ "$path" =~ ^/shop-app/products/[^/]+/(related|reviews|shop|variant|variants)$ ]] || [[ "$path" =~ ^/shop-app/shops/[^/]+$ ]] || [[ "$path" =~ ^/shop-app/shops/[^/]+/(locations|products|reviews|typeahead)$ ]] || [[ "$path" =~ ^/shop-app/shops/[^/]+/collections/[^/]+/products$ ]]; then : else echo "path is not in the shop-app-research skill catalog" >&2 exit 2 fi ``` 4. Apply conservative character allowlists and length limits to dynamic path segments where the API's identifier formats are known. 5. Add negative tests confirming rejection of: - POST requests. - Extra nested path segments. - Undocumented routes under product and shop prefixes. - Empty identifiers and malformed handles. - Query strings embedded directly in the path. 6. Retain the existing fixed HTTPS base URL, mode-600 temporary curl configuration, cleanup trap, and `@` rejection because these are useful defense-in-depth controls. ]]>
Vulnerability Patterns
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
  • MCP Least PrivilegeUnderdeclared Capability, Wildcard Permission, Missing Permission Declaration
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • Supply ChainUnpinned Dependencies, External Script Fetching, Obfuscated Code
Findings (8)

Lp3

Medium
Category
MCP Least Privilege
Confidence
88% confidence
Finding
The skill instructs use of a shell helper (`scripts/crawlora.sh`) and therefore has code-execution capability, but it does not declare any explicit tool scope such as allowed tools or permissions. That creates an avoidable trust gap: an agent may invoke shell access more broadly than intended, increasing the chance of unintended command execution or misuse in environments where shell is powerful.

External Transmission

Medium
Category
Data Exfiltration
Content
#!/usr/bin/env bash
# Crawlora REST helper — minimal, dependency-free (curl only).
# Calls https://api.crawlora.net/api/v1 with your Crawlora API key.
# Get a free key (2,000 credits/mo, no card) at https://crawlora.net?utm_source=github&utm_medium=referral&utm_campaign=crawlora-skills.
#
Confidence
70% confidence
Finding
Data is being sent to an external URL. This could be legitimate telemetry or data exfiltration. Manual review is recommended.

External Transmission

Medium
Category
Data Exfiltration
Content
#!/usr/bin/env bash
# Crawlora REST helper — minimal, dependency-free (curl only).
# Calls https://api.crawlora.net/api/v1 with your Crawlora API key.
# Get a free key (2,000 credits/mo, no card) at https://crawlora.net?utm_source=github&utm_medium=referral&utm_campaign=crawlora-skills.
#
# Usage:
Confidence
60% confidence
Finding
Data is being sent to an external URL. This could be legitimate telemetry or data exfiltration. Manual review is recommended.

External Transmission

Medium
Category
Data Exfiltration
Content
#!/usr/bin/env bash
# Crawlora REST helper — minimal, dependency-free (curl only).
# Calls https://api.crawlora.net/api/v1 with your Crawlora API key.
# Get a free key (2,000 credits/mo, no card) at https://crawlora.net?utm_source=github&utm_medium=referral&utm_campaign=crawlora-skills.
#
# Usage:
Confidence
60% confidence
Finding
Data is being sent to an external URL. This could be legitimate telemetry or data exfiltration. Manual review is recommended.

External Transmission

Medium
Category
Data Exfiltration
Content
#!/usr/bin/env bash
# Crawlora REST helper — minimal, dependency-free (curl only).
# Calls https://api.crawlora.net/api/v1 with your Crawlora API key.
# Get a free key (2,000 credits/mo, no card) at https://crawlora.net?utm_source=github&utm_medium=referral&utm_campaign=crawlora-skills.
#
# Usage:
Confidence
60% confidence
Finding
Data is being sent to an external URL. This could be legitimate telemetry or data exfiltration. Manual review is recommended.

External Transmission

Medium
Category
Data Exfiltration
Content
#!/usr/bin/env bash
# Crawlora REST helper — minimal, dependency-free (curl only).
# Calls https://api.crawlora.net/api/v1 with your Crawlora API key.
# Get a free key (2,000 credits/mo, no card) at https://crawlora.net?utm_source=github&utm_medium=referral&utm_campaign=crawlora-skills.
#
# Usage:
Confidence
60% confidence
Finding
Data is being sent to an external URL. This could be legitimate telemetry or data exfiltration. Manual review is recommended.

Sudo/Root Execution

Medium
Category
Privilege Escalation
Content
# Keep the API key out of the curl process command line. A private temporary
# config supplies the header and is removed automatically on exit.
curl_config="$(mktemp "${TMPDIR:-/tmp}/crawlora-curl.XXXXXX")"
chmod 600 "$curl_config"
trap 'rm -f "$curl_config"' EXIT
printf 'header = "x-api-key: %s"\n' "$CRAWLORA_API_KEY" >"$curl_config"
auth=(--config "$curl_config")
Confidence
80% confidence
Finding
Commands invoke sudo or root privileges. Verify this elevated access is necessary and justified.

External Transmission

Medium
Category
Data Exfiltration
Content
[ -n "$body" ] || body='{}'
  # Stream the body on stdin so curl never interprets a user value as its
  # @file shorthand (and cannot read local files supplied in a request body).
  printf '%s' "$body" | curl -fsS -X "$method" "${auth[@]}" \
    -H "Content-Type: application/json" --data-binary @- "${base}${path}"
fi
Confidence
70% confidence
Finding
Data is being sent to an external URL. This could be legitimate telemetry or data exfiltration. Manual review is recommended.

Static analysis

No suspicious patterns detected.