Back to skill

Security audit

Xianyu Team Optimizer

Security checks for vulnerabilities and agentic risk

Overview

This skill locally optimizes game team groupings from a user-provided roster and shows no hidden data access or persistence, though unusually large inputs could make its script slow.

Install this only if you want a Chinese-language helper for this specific game/team-optimization workflow. Use normal roster-sized inputs and avoid feeding untrusted or extremely large JSON lists, since the optimizer may take a long time on pathological data.

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/optimizer.py:62
Finding

Unbounded Combinatorial Search Enables Resource Exhaustion

Content
View full analysis
best_val: best_val = total best_plan = [(tier, list(team))] + rest_plan memo[avail_fs] = (best_val, best_plan) return (best_val, best_plan) return solve(frozenset(range(n))) ``` ```python def optimize(players, tiers=None, max_stars=MAX_STARS): if tiers is None: tiers = DEFAULT_TIERS[:] tiers_desc = sorted(set(tiers), reverse=True) stars = [p["stars"] for p in players] n = len(players) # Optimal plan if n <= 35: best_val, best_plan = _solve_optimal(stars, tiers_desc, n) else: best_val, best_plan = _solve_greedy(stars, tiers_desc, n) ``` ```python def main(): if len(sys.argv) > 1: with open(sys.argv[1], "r", encoding="utf-8") as f: data = json.load(f) else: data = json.load(sys.stdin) players = data.get("players", data if isinstance(data, list) else []) tiers = data.get("tiers", DEFAULT_TIERS) max_stars = data.get ...[truncated 3030 chars]
Remediation
View remediation
Vulnerability Patterns
  • Trigger AbuseOverly Broad Trigger, Shadow Command Trigger, Keyword Baiting Trigger
  • MCP Least PrivilegeUnderdeclared Capability, Wildcard Permission, Missing Permission Declaration
  • 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 (3)

Undeclared Tool Scope

Medium
Category
MCP Least Privilege
Confidence
70% confidence
Finding

Without declared permissions the skill's intent is opaque and cannot be validated.

Content

No source excerpt is available for this finding.

Vague Triggers

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The trigger conditions are broad enough to activate on generic phrases like '怎么分组' or '帮我排一下队' when a pasted list vaguely mentions stars or grouping, which can cause accidental invocation outside the intended game-specific context. Over-broad routing increases the chance that unrelated user content is parsed as structured roster data, leading to incorrect handling, user confusion, or unintended access to pasted group/member information.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
90% confidence
Finding

This code file contains natural-language documentation entirely in Chinese, including the title, usage description, and output semantics. Under the stated policy, forcing a specific language without user opt-in can be a locale-policy violation when no alternative or justification is provided.

Content

No source excerpt is available for this finding.

Static analysis

No suspicious patterns detected.