Back to skill

Security audit

exam-study-assistant

Security checks for vulnerabilities and agentic risk

Overview

The study helper’s core tutoring functions are ordinary, but it adds an automatic persistent self-learning system that stores user data and can influence future skill behavior without clear consent or boundaries.

Review this before installing if you do not want a study skill to keep local history or preferences. The main exam-planning features are not destructive, but the self-learning module should be disabled or constrained unless you explicitly want learned_patterns.json to store usage notes and preferences and potentially guide future edits to the skill.

Vulnerability Patterns
  • Agent Memory PoisoningWrites attacker-controlled rules into memory that affect later sessions
  • Skill Instruction HijackingAlters the agent's session goals or safety constraints when the skill loads
  • 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)

T02 · Agent Memory Poisoning

Warning
Location
scripts/learner.py:58
Finding

Unvalidated User-Controlled Data Is Stored as Persistent Agent Memory

Content
View full analysis
= THRESHOLD_ERROR: suggestions.append( f"⚠️ 错误「{err}」已出现 {info['count']} 次,建议增加预检/兜底步骤," f"并将经验回写本技能 SKILL.md(lastNote: {info.get('lastNote','')})" ) ``` The associated instructions in `SKILL.md:116-137` state that user preferences are written to `learned_patterns.json`, should be applied on later invocations, and that accumulated experience may be written back into `SKILL.md ...[truncated 3007 chars]
Remediation
View remediation
Vulnerability Patterns
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Excessive AgencyUnrestricted Tool Access, Autonomous Decision Making, Scope Creep
  • Trigger AbuseOverly Broad Trigger, Shadow Command Trigger, Keyword Baiting Trigger
  • MCP Tool PoisoningHidden Instructions, Unicode Deception, Parameter Description Injection
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
Findings (11)

Tp4

High
Category
MCP Tool Poisoning
Confidence
99% confidence
Finding

The skill is presented as an exam-study assistant, but it also introduces a generic self-learning subsystem that records usage, errors, and user preferences and can write to a learned_patterns.json file in a supplied skill directory. This creates hidden persistence and stateful behavior beyond the declared purpose, undermining informed consent and increasing the risk of unauthorized data retention or cross-skill data handling.

Content

No source excerpt is available for this finding.

Vague Triggers

Medium
Category
Not specified by scanner
Confidence
91% confidence
Finding

The activation phrases include generic terms such as “学习计划”, “考试复习”, and “知识点总结”, which are common everyday requests and may cause unintended invocation outside a clearly bounded skill context. The description does not provide exclusion conditions, negative examples, or a narrower invocation scope to distinguish when this skill should versus should not activate.

Content

No source excerpt is available for this finding.

Description-Behavior Mismatch

Medium
Category
Not specified by scanner
Confidence
93% confidence
Finding

The documentation adds a persistent memory system that stores operation counts, error patterns, user preferences, and improvement suggestions across sessions, even though the skill is framed as a study helper. Persistent cross-session storage of behavioral data is security-relevant and privacy-sensitive, especially when not clearly surfaced as part of the skill's primary function.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
94% confidence
Finding

The skill describes writing user preferences and usage history to a local memory file without a clear user warning, consent flow, or retention policy. Silent persistence of personal preferences and interaction history is dangerous because users may disclose sensitive study plans, weaknesses, or exam-related information without realizing it will be stored.

Content

No source excerpt is available for this finding.

Ssd 3

Medium
Category
Not specified by scanner
Confidence
94% confidence
Finding

The instructions explicitly direct persistent storage and reuse of user preferences and usage history across sessions in a local file. This creates a durable memory channel that can accumulate sensitive behavioral data and be reused without fresh user awareness, which is particularly risky in a publicly visible skill with read/write tools.

Content

No source excerpt is available for this finding.

Context-Inappropriate Capability

Medium
Category
Not specified by scanner
Confidence
91% confidence
Finding

The skill instructs the agent to execute a Python script after use for logging, preference storage, insight generation, and reflection. Post-use script execution expands the attack surface and enables side effects unrelated to generating study plans or summaries, particularly when paired with write-capable tools and filesystem access.

Content

No source excerpt is available for this finding.

Description-Behavior Mismatch

Medium
Category
Not specified by scanner
Confidence
93% confidence
Finding

The module is explicitly designed as a generic cross-skill persistence and self-learning component for arbitrary WorkBuddy skills, not a study-assistant-specific feature. That broad capability expands the skill's scope and creates a data collection surface that can be reused across unrelated skills, increasing privacy and misuse risk if invoked on other skill directories.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
97% confidence
Finding

The top-level docstring, usage text, and user-facing descriptions are entirely in Chinese, and the CLI parser description also presents the tool only in Chinese. For a general-purpose module described as usable by any WorkBuddy skill, this imposes a specific language without any opt-in, fallback, or documented region-specific justification.

Content

No source excerpt is available for this finding.

Context-Inappropriate Capability

Medium
Category
Not specified by scanner
Confidence
94% confidence
Finding

The code persistently records per-user preferences, free-form notes, recent operations, and error history to disk for any supplied target skill. In the context of an exam-study assistant, this exceeds the minimally necessary function and can capture sensitive study habits or personal notes without meaningful scoping, consent, retention limits, or isolation.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
90% confidence
Finding

The script writes preferences and free-form notes to learned_patterns.json without any user-facing disclosure, consent flow, or retention policy. Silent local persistence is risky because notes may contain sensitive personal or operational information, and users of a study assistant would not reasonably expect hidden telemetry-like storage.

Content

No source excerpt is available for this finding.

Intent-Code Divergence

Low
Category
Not specified by scanner
Confidence
97% confidence
Finding

The commands say --capability should be filled with examples like '简历优化' and '比价', which are unrelated to exam preparation or study assistance. This conflicts with the rest of the file, which documents an exam-study assistant, and suggests copied documentation that does not match the actual intended skill domain.

Content

No source excerpt is available for this finding.