Back to skill

Security audit

task-time-manager

Security checks for vulnerabilities and agentic risk

Overview

The skill is a useful task-planning assistant, but it also asks the agent to maintain persistent behavioral memory and modify the skill over time without clear user control.

Review this skill before installing. Its planning features are straightforward, but its learning system stores behavioral history and preferences locally and tells the agent to reuse them and potentially update the skill file. Install only if you are comfortable with persistent local memory, and prefer a version that makes memory opt-in, limits stored fields, validates preferences, and requires confirmation before editing skill instructions.

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

Unvalidated Persistent Preferences Can Poison Future Agent Behavior

Content
View full analysis

Vulnerability Details

File Location: SKILL.md:111-117, SKILL.md:126-130, scripts/learner.py:85-101
Vulnerability Type: Persistent agent memory poisoning through unrestricted preference storage
Risk Level: Medium

Vulnerable Code

SKILL.md:111-117:

markdown
# 记录用户偏好(下次直接使用)
python scripts/learner.py prefer <本技能目录> --key 输出语言 --val 中文
# 查看累计洞察(高频能力 / 反复错误)
python scripts/learner.py insight <本技能目录>
# 自动复盘(错误≥3次 或 操作≥10次 时给出改进建议)
python scripts/learner.py reflect <本技能目录>

SKILL.md:126-130:

markdown
- **重要用户偏好** → 写入 `learned_patterns.json`,下次调用直接采用,减少重复询问。

> 越用越懂你:第一次用是通用能力,第十次用已沉淀为你专属的最佳实践。

scripts/learner.py:85-101:

python
def record_preference(skill_dir, key, value):
    data = load_learning(skill_dir)
    data["preferences"][key] = value
    save_learning(skill_dir, data)
    return data

def get_insights(skill_dir):
    data = load_learning(skill_dir)
    caps = sorted(data["capabilityStats"].items(), key=lambda kv: kv[1]["count"], reverse=True)
    errors = sorted(data["errorPatterns"].items(), key=lambda kv: kv[1]["count"], reverse=True)
    return {
        "totalOps": data["totalOps"],
        "topCapabilities": [(k, v["count"]) for k, v in caps[:5]],
        "recurringErrors": [(k, v["count"]) for k, v in errors[:5]],
        "preferences": data["preferences"],
    }

Technical Analysis

The prefer command accepts arbitrary strings for both the preference key and value. record_preference() stores those strings verbatim in the persistent learned_patterns.json file without:

  • A schema or allowlist of supported preference keys.
  • Type validation or constrained value sets.
  • Length or control-character restrictions.
  • Detection or rejection of instruction-like content.
  • Trust metadata identifying the value as untrusted user data.
  • Separation between benign settings and instructions prese ...[truncated 2201 chars]
Remediation
View remediation

Remediation Suggestions

  1. Define a strict allowlist of supported preference keys, such as output language, date format, workday start time, and response detail level.
  2. Assign each allowed key a data type and constrained value set. For example, accept output language only from a fixed enumeration rather than as arbitrary text.
  3. Reject unknown keys, multiline values, control characters, markup, instruction-like phrases, and values exceeding conservative length limits.
  4. Treat every persisted value as untrusted data. When inserting it into agent context, quote and delimit it as data and explicitly state that it must not override system, developer, safety, or current-user instructions.
  5. Do not automatically apply free-form preferences in future sessions. Require confirmation before first reuse or whenever a preference could materially alter behavior.
  6. Store provenance metadata for each preference, including creation time, source, confirmation status, and expected type.
  7. Separate structured settings from notes and historical records. Never use error notes, operation notes, or other free-form history as behavioral instructions.
  8. Provide commands to inspect, revoke, and reset stored preferences.
  9. Add tests proving that malicious values are rejected or handled only as quoted data, including prompt-injection text, multiline content, oversized values, and attempts to override safety constraints.
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 (12)

Tp4

High
Category
MCP Tool Poisoning
Confidence
97% confidence
Finding

The skill is presented as a task/time-management assistant, but it also introduces a generic self-learning and persistence subsystem that records usage, preferences, and error history across runs. This hidden expansion of scope increases privacy and integrity risk because users and platform operators may authorize the skill for planning help without realizing it also performs cross-session behavioral tracking and potentially self-modifying workflow updates.

Content

No source excerpt is available for this finding.

Missing User Warnings

High
Category
Not specified by scanner
Confidence
97% confidence
Finding

The documentation describes automatically writing memory files and even writing learned behavior back into SKILL.md, yet it does not clearly warn the user that their interactions may persist or that the skill may modify its own definition. Undisclosed persistence and self-modification are dangerous because they can silently retain sensitive data, alter future behavior, and undermine trust, reviewability, and change control.

Content

No source excerpt is available for this finding.

Vague Triggers

Medium
Category
Not specified by scanner
Confidence
96% confidence
Finding

L008 将“计划”“效率提升”等宽泛短语列为触发词,这些表达在日常对话中非常常见,缺少足够的领域限定,容易与普通交流重叠。文档也未提供排除条件或负例,无法清晰界定何时应触发该技能、何时不应触发。

Content

No source excerpt is available for this finding.

Description-Behavior Mismatch

Medium
Category
Not specified by scanner
Confidence
94% confidence
Finding

The documented self-learning system stores user preferences and usage history in local memory files, which creates persistent state beyond what a user would expect from a simple task-planning assistant. Even without overt exfiltration, this can expose sensitive behavioral data across sessions, future outputs, or other components that can read the same workspace.

Content

No source excerpt is available for this finding.

Context-Inappropriate Capability

Medium
Category
Not specified by scanner
Confidence
92% confidence
Finding

The skill instructs invocation of a Bash/Python learner module to maintain behavioral memory and insights, but that capability is not necessary for producing task plans and introduces unnecessary execution and persistence surfaces. Adding script-driven state management increases the chance of unintended file writes, data retention, and misuse of tool permissions relative to the skill's stated purpose.

Content

No source excerpt is available for this finding.

Ssd 3

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

Persisting user preferences, usage history, notes, and error patterns in plain local memory instructions risks carrying sensitive user-provided information into later sessions or outputs. In a productivity skill, inputs may include schedules, goals, work items, deadlines, and personal habits, making cross-session leakage particularly plausible and contextually sensitive.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
87% confidence
Finding

L118 的示例直接将“输出语言”偏好写为“中文”,而文档整体也以中文为默认输出语境,未说明用户可自由选择语言或需征得同意后设置。按照语言/locale 政策,技能不应在无明确 opt-in 的情况下强制或默认固定某一输出语言。

Content

No source excerpt is available for this finding.

Description-Behavior Mismatch

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The manifest presents this skill as a task and time management assistant focused on to-dos, planning, Pomodoro, GTD, OKR, habits, and efficiency review. This file instead implements a reusable, skill-agnostic telemetry and preference-learning subsystem for any WorkBuddy skill, including recording usage/failures and generating optimization suggestions, which is broader than the stated task-management functionality.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
89% confidence
Finding

The module's user-facing natural-language description and CLI messaging are entirely in Chinese, with no indication that other languages are supported or that the user can opt into this locale. Under the stated policy, forcing a specific language without user choice is a natural-language policy violation.

Content

No source excerpt is available for this finding.

Context-Inappropriate Capability

Medium
Category
Not specified by scanner
Confidence
94% confidence
Finding

This code persistently stores per-user operation history, error notes, and preferences to disk in learned_patterns.json without any minimization, retention controls, or access protections. In a task/time-management skill, those notes and preferences can easily contain sensitive personal productivity habits, schedules, or work context, creating a privacy and local data exposure risk.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
96% confidence
Finding

The module writes user preference and behavior data to local disk without any explicit warning or consent flow. Silent persistence undermines user expectations and can expose sensitive work patterns or notes to other local users, backups, or forensic recovery, especially because the saved JSON is human-readable.

Content

No source excerpt is available for this finding.

Intent-Code Divergence

Low
Category
Not specified by scanner
Confidence
95% confidence
Finding

The file is documented as a task and time management skill, but the inline examples for --capability use resume optimization and price comparison, which belong to different skill domains. This creates direct intent confusion in the documentation about what the code/module is meant to support.

Content

No source excerpt is available for this finding.