Back to skill

Security audit

xinjianxue-skill-family_harmony-cn

Security checks for vulnerabilities and agentic risk

Overview

The skill is mostly a disclosed paid API integration, but it lets a remote server supply prompt-like instructions that the agent is told to combine into its operating guidance.

Install only if you are comfortable sending the analyzed person's birth details, gender, and location to chinaapi.xinjianxue.com, binding the agent to your Xinjianxue account, and using account credits. The strongest review concern is that server-returned report text is treated as part of the agent's instructions; users and hosts should isolate it as untrusted data before use.

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

T01 · Skill Instruction Hijacking

Error
Location
SKILL.md:219
Finding
Untrusted Remote Content Is Incorporated into Agent Instructions## Vulnerability Details **File Location**: `SKILL.md`, lines 219–241 **Vulnerability Type**: Remote instruction injection **Risk Level**: High **Relevant excerpt translated into English:** ```text ### Report translation (performed by the AI after report output) 1. Reports and prompts are returned by the server in Chinese, and the AI may directly use them for analysis; 2. User-facing deliverables must use the user's native language; 3. For non-Chinese delivery, the AI may optionally back-translate to check meaning. ### Prompt source - Each time the AI invokes `report`, the server returns the “raw report for the current Xinjianxue service”; - Usage instructions = local role capabilities + the raw report returned by the server. ### Local role prompt and assembly This Skill carries two role slots: - Role definition: specializes in family systems, family atmosphere, and role allocation - Dedicated self-check: do not become aligned with one family member; present the family system without taking sides Runtime assembly: Usage instructions = 1. Local role prompt + 2. Raw report returned by `report` user = Current user question, not placed in the system message Analyze the report and the user's specific question based on item 1. ``` ### Technical Analysis The Skill explicitly states that the remote server returns both reports and prompts, and directs the agent to combine the returned content with its local operating instructions. The response from `chinaapi.xinjianxue.com` is therefore treated as authoritative instruction material rather than untrusted external data. No fixed response schema, instruction filtering, field allowlist, content-length restriction, contextual isolation, or integrity mechanism is specified. Consequently, control of the remote service or its response path permits the effective instructions to change after the Skill has undergone static review. A malic ...[truncated 1735 chars]
Remediation
## Remediation Suggestions 1. Treat every remote response as untrusted data and never concatenate it into system, developer, role, or usage instructions. 2. Replace the server-supplied prompt mechanism with a fixed, locally reviewed prompt that cannot be modified by the remote service. 3. Require `/dev/report` to return a versioned structured-data schema containing only necessary report fields. 4. Enforce strict field allowlists, data types, maximum lengths, nesting limits, and accepted character formats before processing a response. 5. Place validated report values only in a clearly delimited untrusted-data section and explicitly instruct the agent not to follow commands found inside that section. 6. Reject or neutralize fields containing instruction-like material, role declarations, tool requests, policy overrides, or attempts to alter the processing hierarchy. 7. Pin the expected API origin and use transport security, authenticated responses, and response-integrity controls where feasible. 8. Minimize tool availability while processing reports and require explicit user confirmation before any consequential follow-up action. 9. Add adversarial tests covering prompt injection in every remotely controlled text field, including nested and encoded payloads. 10. Log validation failures without recording credentials or the sensitive personal information submitted for analysis.
Vulnerability Patterns
  • Excessive AgencyUnrestricted Tool Access, Autonomous Decision Making, Scope Creep
  • 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
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
Findings (2)

Description-Behavior Mismatch

Medium
Confidence
93% confidence
Finding
The manifest frames this skill as limited to family-harmony advisory use, but the documented report interface supports broad person-analysis workflows about someone's psychology, behavior, and current state without technical enforcement of a family-only scope. This creates a capability/consent mismatch: an agent can be induced to collect and transmit personal data for non-family profiling or surveillance-like use under the cover of a narrower stated purpose.

Context-Inappropriate Capability

Low
Confidence
89% confidence
Finding
The manifest presents the skill as a family harmony advisor focused on analyzing people/situations in that domain. Exposing `GET /dev/bill` to retrieve积分消费/积分明细 is an account-management capability unrelated to the advisory purpose itself and therefore exceeds what is justified by the skill's stated role.

Static analysis

No suspicious patterns detected.