Back to skill

Security audit

小天铺货AI助手(开发版)

Security checks for vulnerabilities and agentic risk

Overview

This is a disclosed ecommerce assistant for test-environment shop authorization, product sourcing, preview, and publishing workflows, with sensitive account actions gated by stated workflow rules.

Install only if you intend to use a test-environment ecommerce assistant that can store a local shop session token, send product images or 1688 links to the backend, save preview workflow data locally, and publish products when you confirm or explicitly request auto-publishing. Verify the installed slug is xtph-ecommerce-assistant-dev and that generated frontend links stay on puhuo-test.huitun.com.

Vulnerability Patterns
  • 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
  • Unauthorized Access and Privilege EscalationObtains permissions beyond the task's legitimate needs
Vulnerability Patterns
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • Excessive AgencyUnrestricted Tool Access, Autonomous Decision Making, Scope Creep
  • System Prompt LeakageDirect Leakage, Indirect Extraction, Tool-Based Exfiltration
  • Rogue AgentSelf-Modification, Session Persistence
  • Trigger AbuseOverly Broad Trigger, Shadow Command Trigger, Keyword Baiting Trigger
Findings (15)

Direct Prompt Extraction

High
Category
System Prompt Leakage
Confidence
85% confidence
Finding

Skill contains instructions that could directly expose system prompts, internal rules, or hidden instructions to users or external parties.

Content

Scanner excerpt · SKILL.md (reported line 33)May include surrounding context.

md
- Development channel: technical details, code, scripts, commands, and implementation terminology may be shown when useful for testing or debugging.
- Never reveal private chain-of-thought or hidden reasoning in either channel.
- The production debug override may expose structured diagnostic fields only when the user explicitly requests troubleshooting; it does not permit revealing private reasoning, credentials, or session tokens.
- Do not restate this policy separately for each capability. It is the package-wide output rule.

## User-Facing Capability Introduction

Ae1

High
Category
analysis-evasion
Confidence
100% confidence
Finding

Referenced artifact was not completely inspected

Content

Scanner excerpt · SKILL.md (reported line 137)May include surrounding context.

md
ude Code, Trae, or OpenClaw), the package may be distributed in protocol mode: `SKILL.md` plus `references/api-protocol.md`, without any `scripts/` directory or

Self-Modification

High
Category
Rogue Agent
Confidence
90% confidence
Finding

Skill modifies its own code, configuration, or behavior at runtime. Self-modification enables an agent to escalate privileges, disable safety constraints, or install persistent backdoors.

Content

Scanner excerpt · SKILL.md (reported line 143)May include surrounding context.

md
- Use the agent's own HTTP, browser, file, and base64 tools to call the backend directly according to `references/api-protocol.md`.
- Keep the same dev/prod channel identity and environment separation: `xtph-ecommerce-assistant-dev` must use `test` only, and `xtph-ecommerce-assistant` must use `prod` only.
- Store protocol-mode session state under the slug-scoped paths in `references/api-protocol.md`, never in the WorkBuddy `~/.workbuddy/skills/...` session file.
- The self-update policy in this file only applies when `scripts/version_check.py` exists. Protocol-only packages have no script runtime and no self-update; version updates are managed by the host registry/installer.
- Never expose `sessionToken`, `authCode`, `authCommitmentDesc`, `imageSearchUrl`, full raw `publishDraft` payloads, or image base64 data in user-visible output.
- If the host cannot perform a required deterministic step, report a business-friendly failure instead of guessing or skipping the step.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The file states that the production channel must 'speak in concise, conversational Chinese,' which imposes a fixed language choice. There is no accompanying user choice or opt-in mechanism, so this is a natural-language locale policy violation under the rule.

Content

No source excerpt is available for this finding.

Session Persistence

Medium
Category
Rogue Agent
Confidence
87% confidence
Finding

The skill explicitly requires multi-step write workflows and later instructs the agent to store protocol-mode session state under slug-scoped paths. Persisting workflow/session state for authorization and publish flows can retain tokens, workflow IDs, or shop context longer than necessary, increasing the risk of cross-session misuse or local disclosure if storage is weakly protected.

Content

Scanner excerpt · SKILL.md (reported line 59)May include surrounding context.

md
- Capabilities may be grouped internally by domain for routing and documentation.
- The grouping must stay inside this package and must not become separate Skill packages.
- Read capabilities may stay lightweight.
- Write capabilities must follow `preview -> confirm -> execute -> recover` and must not be submitted as blind one-shot actions.
- Detailed capability mappings should stay in `references/api-protocol.md` so the main skill text remains stable.

## Release Channel Policy

Vague Triggers

Medium
Category
Not specified by scanner
Confidence
92% confidence
Finding

The default prompt uses a broad routing trigger for 'ecommerce intent' tied to product images or image URLs, which can capture ordinary shopping or image-analysis requests without clear user consent to invoke this specific skill. In a skill that can authorize shops, preview listings, and publish source links, over-broad activation increases the chance of unintended tool use, data exposure, or unintended commerce actions.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The prompt hard-codes output behavior ('Show the first 10 returned products...' with fixed formatting) despite the skill metadata and audience being Chinese-facing, which can override normal language or UX expectations. While not a direct code-execution issue, forced presentation behavior without user opt-in can mislead users, reduce clarity around results, and increase the risk of mistaken product selection or publication in a commerce workflow.

Content

No source excerpt is available for this finding.

Description-Behavior Mismatch

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The development-scoped skill documentation explicitly defines both development and production channels and includes production backend/frontend targets. In a self-test package that must use only the test environment, this creates a realistic risk of cross-environment access, accidental use of production credentials, or execution of write actions against live shops if an agent follows the wrong branch.

Content

No source excerpt is available for this finding.

Session Persistence

Medium
Category
Rogue Agent
Confidence
75% confidence
Finding

Skill establishes unauthorized persistence across sessions via cron jobs, startup scripts, or state files. Session persistence allows an attacker to maintain access beyond the current interaction.

Content

Scanner excerpt · references/api-protocol.md (reported line 216)May include surrounding context.

Trigger: 查询授权状态 / 查看授权状态 / 看看授权店铺 / 当前授权情况.

http
POST https://puhuoapi.huitun.com/shop/getAuthShopList
X-Session-Token: {sessionToken}
Accept: application/json
Content-Type: application/json

Vague Triggers

Medium
Category
Not specified by scanner
Confidence
93% confidence
Finding

The trigger says to activate based on 'intent plus available image context' and examples like '这张图 / 上面的图片 / 附件' combined with broad shopping intents, then explicitly says this is 'intent routing, not exact keyword matching.' In a markdown protocol file, this is ambiguous about when the skill should activate versus when ordinary conversational references to images should not invoke the search flow.

Content

No source excerpt is available for this finding.

Autonomous Decision Making

Medium
Category
Excessive Agency
Confidence
80% confidence
Finding

Skill enables autonomous high-impact decisions without human-in-the-loop verification. Critical operations (destructive commands, financial transactions, data deletion) should require explicit user confirmation.

Content

Scanner excerpt · references/api-protocol.md (reported line 528)May include surrounding context.

10.2 Need manual goods restock

When required product attributes remain missing and the selected products cannot be published, do not ask the user to resume the agent workflow or reply with 确认铺货. Render the exact sentence, one fenced code block per selected 1688 link, and the client entry:

text
请复制以下商品链接去手动铺货:

Description-Behavior Mismatch

Medium
Category
Not specified by scanner
Confidence
98% confidence
Finding

The file instructs the use of a production goods_restock URL as an allowed branch, even though the analyzed skill is the development package and the metadata says it must use the test environment only. In this workflow, the URL is presented during a manual fallback for publishing, so a user could be steered directly into the live client path from a dev-scoped agent.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The instruction says to explain business reasons 'in conversational Chinese' for an item, which imposes a specific language policy. Because the document does not offer opt-in language selection or clearly justify that the skill is restricted to Chinese-only users or a region-specific compliance context, this is a natural-language policy concern.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
84% confidence
Finding

This manifest presents the skill name and display name only in Chinese, which can indicate a fixed language/locale choice in user-facing behavior. For an all-file-types policy check, this is a natural-language locale signal without any accompanying opt-in or documented region-specific justification in the file.

Content

No source excerpt is available for this finding.

Vague Triggers

Low
Category
Not specified by scanner
Confidence
84% confidence
Finding

The file lists several natural-language preview triggers and also allows activation from 'the user-selected products from image search,' but it does not define clear boundaries for when similar phrasing should not start a preview workflow. In markdown guidance, this can cause unintended invocation because the trigger scope depends on interpretation rather than explicit constraints.

Content

No source excerpt is available for this finding.