Back to skill

Security audit

meta-reflection-replanner

Security checks for vulnerabilities and agentic risk

Overview

The skill is not destructive or exfiltrating data, but it asks the agent to keep persistent learning state and potentially rewrite its own instructions without enough scoping or user control.

Install only if you are comfortable with a skill recording usage history and preferences locally for reuse across sessions. Before using it, remove or disable the instruction to rewrite SKILL.md automatically, treat learned_patterns.json as untrusted data, and inspect or delete that file periodically.

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:6
Finding

Unvalidated Persistent Memory Can Poison Future Agent Sessions

Content
View full analysis
--capability 简历优化 # 记录一次失败/异常 python scripts/learner.py record <本技能目录> --capability 简历优化 --fail --error 格式识别失败 --note "用户上传了非标准文件" # 记录用户偏好(下次直接使用) python scripts/learner.py prefer <本技能目录> --key 输出语言 --val 中文 # 查看累计洞察(高频能力 / 反复错误) python scripts/learner.py insight <本技能目录> # 自动复盘(错误≥3次 或 操作≥10次 时给出改进建议) python scripts/learner.py reflect <本技能目录> ``` ### 迭代规则 - **错误累计 ≥3 次** → 主动增加预检/兜底步骤,并将经验回写本 SKILL.md。 - **操作数 ≥10 次** → 分析高频能力优先打磨示例与质量,低频能力评估精简或合并。 - **重要用户偏好** → 写入 `learned_patterns.json`,下次调用直接采用,减少重复询问。 ``` `scripts/learner.py:6-17`: ```python def load(): try: return json.load(open(MEM, encoding="utf-8")) except Exception: return {"total_ops": 0, "total_fails": 0, "patterns": []} def record(op_ok=True, note=""): d = load(); d["total_ops"] += 1 if not op_ok: d["total_fails"] += 1 if note: d.setdefault("patterns", []).append(note) json.dump(d, open(MEM, "w", encoding="utf-8"), ensure_ascii=False, indent=2) return d ``` ### Technical Analysis The learner accepts arbitrary text from a command-line argument and appends it directly to the persistent `patterns` collection. It applies no schema validation, content filtering, provenance tracking, trust separation, length restriction, or authorization check. The Skill instructions state that persisted preferences should be applied during later invocations and that accumulated experience may be written back into `SKILL.md`. Consequently, untrusted free-form content can cross th ...[truncated 2486 chars]
Remediation
View remediation
Vulnerability Patterns
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • MCP Least PrivilegeUnderdeclared Capability, Wildcard Permission, Missing Permission Declaration
  • MCP Tool PoisoningHidden Instructions, Unicode Deception, Parameter Description Injection
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
Findings (10)

Tp4

High
Category
MCP Tool Poisoning
Confidence
96% confidence
Finding

The skill makes expansive claims about self-verification, self-reflection, orchestration, and continuous self-evolution that are not implemented in the provided artifact, while it does include persistence behavior. This mismatch can mislead operators into granting trust, autonomy, or access under false assumptions, which is a security concern because capabilities and risks are inaccurately represented.

Content

No source excerpt is available for this finding.

Undeclared Tool Scope

Medium
Category
MCP Least Privilege
Confidence
92% confidence
Finding

The skill instructs use of a local script that records data and writes persistent state (learned_patterns.json) but declares no tool scope or permission boundary. That creates a hidden capability gap: an agent or reviewer may believe this is documentation-only while the skill operationally depends on file writes, increasing the risk of unexpected persistence or policy bypass.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The skill states that it automatically reviews usage, accumulates experience, and improves over time, but does not clearly warn that user-related preferences and activity may be persistently stored. This undermines informed consent and can lead to silent retention of potentially sensitive behavioral data across sessions.

Content

No source excerpt is available for this finding.

Ssd 3

Medium
Category
Not specified by scanner
Confidence
97% confidence
Finding

The skill instructs persistent collection and reuse of user preferences and usage history across sessions as part of its normal operation. In this context, persistence is more dangerous because the skill markets itself as an autonomous self-evolving meta-skill, which can normalize broad memory collection without clear boundaries, consent, or data minimization.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
96% confidence
Finding

The instructions explicitly direct the agent to write user preferences into learned_patterns.json for future reuse, but do not warn that this is persistent cross-session storage of personal preference data. Without transparency and consent controls, the skill may collect and retain user metadata in a way users do not expect.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
81% confidence
Finding

The natural-language example sets 输出语言 --val 中文, which nudges the skill toward a fixed language/locale behavior. Because the document does not offer an explicit user language choice or justify a Chinese-only constraint, this can violate the language/locale policy requirement.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
92% confidence
Finding

The only natural-language description in the file is written in Chinese, indicating a language-specific skill behavior or documentation without offering any language choice. Under the policy, forcing a specific language without user opt-in is a natural-language policy violation unless the locale constraint is explicitly justified.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
88% confidence
Finding

This markdown file uses Chinese throughout, including the title and all descriptive content, but does not state that the skill is intended only for Chinese-speaking users or offer any language choice. Per the policy, forcing a specific language without user opt-in can be a natural-language policy violation.

Content

No source excerpt is available for this finding.

Description-Behavior Mismatch

Low
Category
Not specified by scanner
Confidence
90% confidence
Finding

The manifest describes an advanced meta-skill with self-verification, self-reflection, orchestration, and continuous self-evolution. In this file, the implemented behavior is limited to counting operations/failures and appending notes into a local JSON file, which is much narrower than the claimed capability. This is a semantic mismatch between the advertised behavior and the actual operation present here.

Content

No source excerpt is available for this finding.

Missing User Warnings

Low
Category
Not specified by scanner
Confidence
83% confidence
Finding

This code writes persistent data to learned_patterns.json, which affects local user/workspace state. While the module docstring describes recording calls and outcomes, there is no user-facing confirmation, print/log notice before the write, or inline warning at the write site explaining that execution will modify a file.

Content

No source excerpt is available for this finding.