Back to skill

Security audit

Amazon 价格与 BSR 变化追踪

Security checks for vulnerabilities and agentic risk

Overview

The skill documents a narrow free Amazon price/BSR watch workflow, but the bundled CLI also exposes broader paid AI, account-setting, export, and operations commands that are not disclosed for this skill.

Review before installing. Use only the documented watch commands if you proceed, and avoid running the broader ari.py commands such as analyze, voc, operations, advise, leaderboard, export, or autoconfirm unless you deliberately want those paid or account-changing features. Check your ARI account auto-confirm setting before 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/ari.py:1140
Finding
Remote Quote Response Can Bypass Explicit Confirmation for Paid Analysis<![CDATA[ ## Vulnerability Details **File Location**: `scripts/ari.py`, lines 1140-1167 **Vulnerability Type**: Server-controlled authorization bypass for paid operations **Risk Level**: Medium ### Vulnerable Code ```python quote = request_json("POST", "/api/v1/analysis/quote", q_payload) if not ok(quote): return quote q_data = data_of(quote) or {} auto_confirmed = False if not confirm and q_data.get("autoConfirm") and q_data.get("sufficient"): confirm = True auto_confirmed = True ``` The resulting locally modified confirmation value controls whether the paid request is submitted: ```python payload = {"asin": (asin or "").upper(), "site": site, "outputLanguage": language} if kind == "compare": payload.update({"competitorAsin": (competitor or "").upper(), "competitorSite": competitor_site or site}) path = "/api/v1/analysis/" + kind if kind in SSE_TYPES: out = backfill_report_id(request_sse(path, payload), asin) else: out = request_json("POST", path, payload) ``` An equivalent server-controlled automatic-confirmation mechanism is also present in the combined VOC workflow around `scripts/ari.py:1353-1358`. ### Technical Analysis The CLI presents `--confirm` as the local authorization boundary for paid analysis. However, `run_analysis()` allows fields returned by the remote quote endpoint to change the local `confirm` variable from false to true. Consequently, a command invoked without `--confirm` can proceed beyond the quotation stage and submit a paid analysis request when the server returns both: - `autoConfirm` with a truthy value; and - `sufficient` with a truthy value. Consent for a paid operation should not be inferred solely from mutable remote response data. The response is received from an HTTPS endpoint restricted to the official origin, which mitigates ordinary redirection and network interception attacks. Nevertheless, a service defect, compromised service, incorrect account policy, or unexpected s ...[truncated 1661 chars]
Remediation
<![CDATA[ ## Remediation Suggestions 1. Preserve `--confirm` as an immutable local authorization decision. Never assign `confirm = True` based on fields from a server response. 2. When `--confirm` is absent, always return the quote and terminate before calling any paid analysis endpoint. 3. Remove the equivalent automatic-confirmation path from the combined VOC workflow at `scripts/ari.py:1353-1358`. 4. If automatic confirmation remains a supported feature, require a separate explicit local opt-in stored in protected local configuration. The setting should include: - A clearly defined maximum charge per operation. - An optional cumulative daily or monthly limit. - The permitted operation types. - A straightforward command to disable the feature. 5. Treat server-provided `autoConfirm` fields only as informational account-policy metadata, not as proof of user consent. 6. Add regression tests verifying that every paid endpoint remains unreachable without `--confirm`, regardless of quote-response fields. 7. Update the CLI documentation so its confirmation guarantees accurately reflect implemented behavior. ]]>
Vulnerability Patterns
  • Excessive AgencyUnrestricted Tool Access, Autonomous Decision Making, Scope Creep
  • 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 (52)

Context-Inappropriate Capability

Critical
Confidence
99% confidence
Finding
The manifest says the skill does not use paid LLMs, but run_analysis() quotes and executes multiple paid AI analysis endpoints, including SSE-backed analysis that can consume credits. This is a severe trust and consent violation: an agent expecting a deterministic snapshot tool could trigger chargeable model-backed analysis and exfiltrate product/review data to a remote AI service.

Tp4

High
Category
MCP Tool Poisoning
Confidence
99% confidence
Finding
The skill is presented as a narrowly scoped, deterministic snapshot tracker, but the detected behavior indicates a much broader operational surface including account/config management, watch lifecycle operations, report export, and other workflows. This mismatch is dangerous because users and reviewers may grant trust or secrets based on the declared limited purpose while the skill can perform materially different actions with higher risk.

Ae1

High
Category
analysis-evasion
Content
- 本候选保持 planned。先运行 `python scripts/ari.py watch --help` 确认当前 CLI 已提供这些子命令;若不可用,必须停止并提示升级,不得回退到其他工作流,也不能宣传为立即可用。
Confidence
100% confidence
Finding
Referenced artifact was not completely inspected

Ae1

High
Category
analysis-evasion
Content
- 本候选保持 planned。先运行 `python scripts/ari.py watch --help` 确认当前 CLI 已提供这些子命令;若不可用,必须停止并提示升级,不得回退到其他工作流,也不能宣传为立即可用。
Confidence
100% confidence
Finding
Referenced artifact was not completely inspected

Ae1

High
Category
analysis-evasion
Content
- 本候选保持 planned。先运行 `python scripts/ari.py watch --help` 确认当前 CLI 已提供这些子命令;若不可用,必须停止并提示升级,不得回退到其他工作流,也不能宣传为立即可用。
Confidence
100% confidence
Finding
Referenced artifact was not completely inspected

Ae1

High
Category
analysis-evasion
Content
- 本候选保持 planned。先运行 `python scripts/ari.py watch --help` 确认当前 CLI 已提供这些子命令;若不可用,必须停止并提示升级,不得回退到其他工作流,也不能宣传为立即可用。
Confidence
100% confidence
Finding
Referenced artifact was not completely inspected

Ae1

High
Category
analysis-evasion
Content
- 本候选保持 planned。先运行 `python scripts/ari.py watch --help` 确认当前 CLI 已提供这些子命令;若不可用,必须停止并提示升级,不得回退到其他工作流,也不能宣传为立即可用。
Confidence
100% confidence
Finding
Referenced artifact was not completely inspected

Ae1

High
Category
analysis-evasion
Content
- 本候选保持 planned。先运行 `python scripts/ari.py watch --help` 确认当前 CLI 已提供这些子命令;若不可用,必须停止并提示升级,不得回退到其他工作流,也不能宣传为立即可用。
Confidence
100% confidence
Finding
Referenced artifact was not completely inspected

Ae1

High
Category
analysis-evasion
Content
- 本候选保持 planned。先运行 `python scripts/ari.py watch --help` 确认当前 CLI 已提供这些子命令;若不可用,必须停止并提示升级,不得回退到其他工作流,也不能宣传为立即可用。
Confidence
100% confidence
Finding
Referenced artifact was not completely inspected

Ae1

High
Category
analysis-evasion
Content
- 本候选保持 planned。先运行 `python scripts/ari.py watch --help` 确认当前 CLI 已提供这些子命令;若不可用,必须停止并提示升级,不得回退到其他工作流,也不能宣传为立即可用。
Confidence
100% confidence
Finding
Referenced artifact was not completely inspected

Context-Inappropriate Capability

High
Confidence
96% confidence
Finding
The autoconfirm command modifies account-level behavior for future paid actions, unrelated to snapshot tracking. This changes billing/consent workflow state and can make later operations run without an explicit confirmation step, which is especially risky in a skill already exposing undeclared paid analysis features.

Context-Inappropriate Capability

High
Confidence
97% confidence
Finding
The code supports creation, pausing, resuming, deletion, digests, and event retrieval for scheduled watches, which goes beyond passive reading of saved snapshots. Even if not hourly, this is active monitoring/state management inconsistent with the described narrow snapshot tracker and may lead to unanticipated persistent data collection and account-side automation.

Description-Behavior Mismatch

High
Confidence
99% confidence
Finding
The CLI surface massively exceeds the declared skill scope of deterministic Amazon snapshot price/BSR tracking. It exposes review collection, AI analysis, watch scheduling, operations workflows, exports, alerts, workbench actions, and paid features, which increases the attack surface and can cause an agent or user to invoke capabilities they did not consent to install.

Natural-Language Policy Violations

Medium
Confidence
89% confidence
Finding
该技能说明全文以中文撰写,并要求用户直接发送中文触发语句开始使用,但未说明是否支持其他语言,也未给出语言选择或用户自愿选择中文的机制。按照语言/locale 政策,这构成了默认强制特定语言而缺少 opt-in 的自然语言策略问题。

Lp3

Medium
Category
MCP Least Privilege
Confidence
91% confidence
Finding
The skill exposes operational capabilities involving environment access, file writes, network, and shell execution, but it does not declare any corresponding tool scope or permission boundaries in the skill metadata. This creates an authorization and review gap: consumers and policy layers cannot reliably understand or constrain what the skill may invoke, increasing the chance of unintended command execution or network/API use.

Natural-Language Policy Violations

Medium
Confidence
92% confidence
Finding
The description, summary, display name, and operating instructions are written in Chinese, with no indication that users may choose another language. This can violate a language/locale policy when a skill imposes a specific language without user opt-in or documented justification.

Natural-Language Policy Violations

Medium
Confidence
93% confidence
Finding
The display name, short description, and default prompt all force a specific language presentation, but the file does not mention that the skill is intended only for Chinese-speaking users or provide any language choice. This can violate language or locale policy when users have not opted into that language.

Autonomous Decision Making

Medium
Category
Excessive Agency
Content
emit(balance, args.compact)
        return
    # 免确认策略(1.4.5):告诉 agent 当前用户是「小额直接生成」还是「每次先问」
    auto = request_json("GET", "/api/v1/user/autoconfirm")
    emit({"success": True, "data": {
        "skillVersion": VERSION,
        "release": release,
Confidence
87% confidence
Finding
Exposing and surfacing account auto-confirm policy contributes to autonomous paid execution risk because later commands honor that policy to skip confirmation for chargeable operations. In this skill context, where paid AI features are already undeclared, any mechanism that normalizes or enables no-prompt charging is more dangerous than usual.

Autonomous Decision Making

Medium
Category
Excessive Agency
Content
"release": release,
        "user": data_of(me),
        "balance": data_of(balance),
        "autoConfirm": data_of(auto) if ok(auto) else None,
    }, "links": links()}, args.compact)
Confidence
87% confidence
Finding
Returning autoConfirm state to callers can be used by an agent to decide whether it can proceed with a paid action without another prompt. In a narrowly declared snapshot tracker, that materially increases the chance of silent paid execution outside user expectations.

Autonomous Decision Making

Medium
Category
Excessive Agency
Content
}, "links": links()}, args.compact)


AUTOCONFIRM_MODE_NOTE = {
    "always_ask": "每次付费操作都会先报价、等你确认。",
    "user_limit": "{limit} 积点以内的操作直接生成,超过才问你。",
    "free_small": "免费版 {max} 积点以内的操作直接生成(用的是赠送积点)。",
Confidence
85% confidence
Finding
The AUTOCONFIRM mode table itself is only descriptive, but it documents and supports behavior that allows paid actions without an immediate confirmation prompt. Given the undeclared paid-analysis surface, even supporting text around this workflow contributes to unsafe autonomous billing behavior.

Autonomous Decision Making

Medium
Category
Excessive Agency
Content
}


def cmd_autoconfirm(args):
    """免确认阈值:不带参数=查看;`autoconfirm 50`=50 积点以内不问;`autoconfirm off`=每次都问;`autoconfirm default`=恢复默认。"""
    value = (args.value or "").strip().lower()
    if value:
Confidence
98% confidence
Finding
cmd_autoconfirm actively changes account settings so future paid operations can run without explicit confirmation. That is a direct consent-control bypass enabler in practice, especially because the skill also contains multiple paid remote analysis features that conflict with the manifest.

Autonomous Decision Making

Medium
Category
Excessive Agency
Content
def cmd_autoconfirm(args):
    """免确认阈值:不带参数=查看;`autoconfirm 50`=50 积点以内不问;`autoconfirm off`=每次都问;`autoconfirm default`=恢复默认。"""
    value = (args.value or "").strip().lower()
    if value:
        if value in ("off", "ask", "0"):
Confidence
90% confidence
Finding
This branch processes values that can disable per-action confirmation ('off', threshold values, reset behavior), reinforcing the autonomous billing path. While not exploitable as code injection, it weakens human-in-the-loop safeguards around paid operations.

Autonomous Decision Making

Medium
Category
Excessive Agency
Content
limit = int(value)
            except ValueError:
                emit(error_obj("ARI_BAD_ARGUMENT", 0, "参数不对",
                               "用法:autoconfirm 50(50 积点以内不问)/ autoconfirm off(每次都问)/ autoconfirm default(恢复默认)"),
                     args.compact)
                return
        out = request_json("PUT", "/api/v1/user/autoconfirm", {"limit": limit})
Confidence
98% confidence
Finding
The PUT request to /api/v1/user/autoconfirm mutates server-side account policy, enabling or altering autonomous paid execution. This is a real security/control issue because it changes consent semantics beyond the immediate command and is unrelated to the advertised read-oriented snapshot function.

Autonomous Decision Making

Medium
Category
Excessive Agency
Content
"用法:autoconfirm 50(50 积点以内不问)/ autoconfirm off(每次都问)/ autoconfirm default(恢复默认)"),
                     args.compact)
                return
        out = request_json("PUT", "/api/v1/user/autoconfirm", {"limit": limit})
    else:
        out = request_json("GET", "/api/v1/user/autoconfirm")
    if ok(out) and isinstance(data_of(out), dict):
Confidence
86% confidence
Finding
Reading autoconfirm state is less severe than modifying it, but still facilitates automated decision-making about whether the agent can proceed with billed requests silently. In this misleadingly scoped skill, even read access to that control increases risk.

Autonomous Decision Making

Medium
Category
Excessive Agency
Content
return
        out = request_json("PUT", "/api/v1/user/autoconfirm", {"limit": limit})
    else:
        out = request_json("GET", "/api/v1/user/autoconfirm")
    if ok(out) and isinstance(data_of(out), dict):
        d = data_of(out)
        d["note"] = AUTOCONFIRM_MODE_NOTE.get(d.get("mode"), AUTOCONFIRM_MODE_NOTE["ask"]).format(
Confidence
85% confidence
Finding
Formatting and returning a note about autoconfirm modes is not dangerous on its own, but it supports a workflow where agents can normalize silent billing behavior. The context makes this more sensitive because the skill under-declares its paid remote-analysis capabilities.

Static analysis

No suspicious patterns detected.