T02 · Agent Memory Poisoning
- Location
scripts/learner.py:72- Finding
Persistent Storage of Untrusted Preferences and Operational Notes Can Poison Future Agent Behavior
- Content
View full analysis
- Remediation
View remediation
Security audit
Security checks for vulnerabilities and agentic risk
The skill is a plausible video-creation assistant, but it adds automatic persistent learning and possible self-modification without clear consent, scoping, or review.
Review this skill before installing. Its video-creation functions are normal, but the automatic learning system can keep local records of your preferences and notes and may lead an agent to edit the skill instructions over time. Install only if you are comfortable with that persistence, and prefer a version that disables learning by default or requires explicit approval before storing data or changing SKILL.md.
scripts/learner.py:72Persistent Storage of Untrusted Preferences and Operational Notes Can Poison Future Agent Behavior
scripts/learner.py:27Unrestricted Output Directory and Symbolic-Link Following Allow Arbitrary File Overwrite Within Process Permissions
The skill is presented as a video-creation assistant, but it also introduces a generic self-learning and persistence mechanism that records usage history, errors, and user preferences. This expands behavior beyond the declared purpose and can mislead users and reviewers about data handling and operational scope, increasing privacy and trust risk.
The listed trigger words include generic phrases such as “短视频”, “分镜”, and “视频创作”, which can appear in many ordinary user requests and may cause unintended invocation. The file does not provide exclusion conditions, negative examples, or narrower context defining when the skill should or should not activate.
The skill adds a persistent memory subsystem that stores user preferences and usage history even though that capability is not necessary for core video-script generation. Unnecessary retention increases the attack surface for privacy leakage, cross-session profiling, and unintended reuse of prior user data.
The skill states that it persists user preferences and usage history to a local memory file without any clear user-facing warning, consent flow, or retention explanation. Hidden or poorly disclosed retention is dangerous because users may reveal preferences, workflows, or sensitive notes assuming the interaction is ephemeral.
The instructions explicitly persist user preferences, usage history, errors, and notes into a local natural-language memory file. Such files can easily accumulate sensitive or identifying information and may later be exposed, reused in unrelated contexts, or leaked through subsequent prompts or file access.
The file's primary behavior is persistent self-learning and usage tracking rather than the video scripting/storyboarding functions promised by the skill manifest. This mismatch increases security concern because users invoking a content-creation assistant would not reasonably expect long-term behavioral logging, making hidden telemetry-like behavior more risky in context.
The module persists arbitrary user preferences, notes, error types, and operational history to disk in a generic cross-skill store, but the advertised skill is a video-creation assistant rather than a telemetry or personalization service. This creates unnecessary data collection and retention risk: free-form notes may contain sensitive user data, and the generic design makes it easy to accumulate unrelated information across skills without clear scope limitation or consent.
The natural-language interface and usage instructions are entirely Chinese, which effectively forces a specific language for users and integrators. The file does not offer an alternative language, opt-in, or justification for a Chinese-only locale restriction.
The code writes preferences and usage history directly to learned_patterns.json without any user-facing notice, consent, or runtime disclosure; comments and docstrings are not an adequate privacy control. Because fields like note, error, and preferences are arbitrary strings, the file can silently capture personal, proprietary, or sensitive workflow information and retain it on disk.
The surrounding document is for a video creation assistant, but the inline Bash examples instruct recording capabilities like '简历优化' and '比价'. These examples actively contradict the skill's stated domain and suggest the embedded learner module was copied from a different skill, creating intent-code/documentation divergence.