Back to skill

Security audit

xinjianxue-skill-classmate_qa-cn

Security checks for vulnerabilities and agentic risk

Overview

This skill is a disclosed paid API integration for classmate-relationship advice, with sensitive data and credential handling explained to the user.

Before installing, users should be comfortable sharing sensitive profile details with the Xinjianxue API and binding the assistant to their Xinjianxue account with a one-time authorization code. Treat the resulting license and api_key as secrets, and expect the skill to mention vendor credit options if the account lacks trial credits.

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

Warning
Location
SKILL.md:257
Finding

Mandatory Third-Party Promotional Output Through Skill Instruction Hijacking

Content
View full analysis

Vulnerability Details

File Location: SKILL.md, lines 257–272
Vulnerability Type: Mandatory response manipulation and third-party promotion
Risk Level: Medium

Vulnerable Code Snippet

The following is an English translation of the complete relevant source segment:

markdown
## §8. Error Response Handling Table (perform the prescribed action upon receipt; do not improvise)

| Response message | Meaning | AI action |
| --- | --- | --- |
| `Please apply for a Xinjianxue AI Assistant business license first` | No license supplied | Proceed to Step 1 to apply |
| `License application failed; please apply again` | Invalid license format or license not found | Apply for a new license; invalidate the old one |
| `The license has not been bound to an account: ...` | License exists but is unbound | Stop and request an AI authorization code from the user |
| `Missing api_key (dual authentication requires both...)` | Only the license was supplied | Supply both credential headers; also include them in the report body |
| `api_key is invalid` | The API key does not exist | Tell the user to contact support through the mini-program; do not retry |
| `api_key is frozen` / `api_key was deleted; please apply again` | Account frozen or credential deleted | Tell the user to contact support through the mini-program |
| `The license and api_key do not belong to the same account; dual authentication failed` | Credentials do not match | State that the AI credentials are misconfigured and direct the user to support |
| `This license is already bound to another account and cannot be rebound...` | License bound elsewhere | Apply for a new license and bind it with the current user's authorization code |
| `This account has already been bound by another AI assistant...` | Account already bound | State that one account can be bound only once and direct the user to support |
| `The AI authorization code is invalid; ask the user to ve
...[truncated 2983 chars]
Remediation
View remediation

Remediation Suggestions

  1. Remove the instruction that the agent must follow the response table without discretion.
  2. Replace the insufficient-credit action with neutral wording, such as: “The external service reports that the account has insufficient credits, so the report cannot be generated.”
  3. Do not require the agent to promote invitations, social-media sharing, or any third-party application.
  4. If reward options are retained, clearly label them as optional vendor-provided promotions and disclose that they are not necessary to continue using the host assistant.
  5. Present promotional options only when the user explicitly asks how to obtain additional credits.
  6. Preserve the host agent's higher-priority safety, neutrality, and response policies by stating that all Skill instructions are subordinate to those policies.
  7. Add a review boundary preventing remote API status messages from selecting promotional or behavior-changing response templates.
Vulnerability Patterns
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
  • Supply ChainUnpinned Dependencies, External Script Fetching, Obfuscated Code
  • Excessive AgencyUnrestricted Tool Access, Autonomous Decision Making, Scope Creep