Back to skill

Security audit

TagMemory

Security checks for vulnerabilities and agentic risk

Overview

This local memory skill does not show data exfiltration, but it needs Review because it can persist and alter personal memories with weak confirmation controls.

Review carefully before installing. This skill keeps long-term memories on disk under the user’s OpenClaw skill area and may store personal or project details in plaintext. Do not use it for secrets or confidential data unless you are comfortable with local retention. Before use, remove the packaged pending_summary.json, require explicit confirmation for summary archival and replacements, avoid default-confirm behavior, and add a recoverable or confirmed update path for verified memories.

Vulnerability Patterns
  • Agent Memory PoisoningWrites attacker-controlled rules into memory that affect later sessions
  • 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
  • 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 (3)

T02 · Agent Memory Poisoning

Error
Location
src/deduplication.py:81
Finding

Verified memories can be silently replaced through similarity-based deduplication

Content
View full analysis
best_score: best_score = similarity best_match = { "id": m.id, "content": m.content, "similarity": similarity, "verified": m.verified } ``` ```python # src/deduplication.py:154-164 else: # Highly similar, but not identical return { "should_store": True, "reason": f"Similar but contains new content ({dup_check['best_match']['similarity']:.1%})", "existing_memory": dup_check["best_match"], "action": "update" } ``` The corresponding source code uses a localized reason string, but the control flow and returned values shown above are unchanged. ```python # src/cli.py:68-69 if should['action'] == 'update' and should.get('existing_memory'): skill.db.delete(should['existing_memory']['id']) ``` The same destructive update behavior is repeated in the non-JSON CLI path: ```python # src/cli.py:279-280 if should['action'] == 'update' and should.get('existing_memory'): skill.db.delete(should['existing_memory']['id']) ``` ### Technical Analysis The deduplication manager compares new content against existing verified memories using a Jaccard word-set similarity calculation. If the best similarity score reaches the configured threshold of `0.8`, the new content is treated as an update rather than a separate memory. Th ...[truncated 2172 chars]
Remediation
View remediation

T02 · Agent Memory Poisoning

Warning
Location
data/pending_summary.json:1
Finding

Bundled summary state can be promoted into verified persistent memory without explicit confirmation

Content
View full analysis
7 else summary.period, ...[truncated 2341 chars]
Remediation
View remediation

T09 · Insecure Skill Coding Practices

Warning
Location
src/database.py:50
Finding

Sensitive long-term memory is stored in plaintext without restrictive file permissions

Content
View full analysis
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 Least PrivilegeUnderdeclared Capability, Wildcard Permission, Missing Permission Declaration
  • MCP Tool PoisoningHidden Instructions, Unicode Deception, Parameter Description Injection
Findings (28)

Tp4

High
Category
MCP Tool Poisoning
Confidence
95% confidence
Finding

The declared description presents a fairly complete long-term memory system with storage triggers, retrieval, summaries, confirmation, proactive checking, BM25 search, time filtering, and human review. The supplied code chunk is much narrower: it is primarily a deduplication/storage helper plus simple intent extraction and auto-tagging. While parts of the description are partially supported—such as tag support and detecting some '记住...' style inputs—the major advertised capabilities are absent from this code. The code does not implement querying past memories, BM25, time-range search, periodic summarization, or a real human-review workflow. Therefore the description materially overstates what this code chunk actually does.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
89% confidence
Finding

The markdown shows commands for storing arbitrary user memories, and the examples include user preferences and personal/project facts. Although it mentions local storage and no cloud upload, it does not warn users that sensitive personal information may be written to a persistent local SQLite database and retained over time.

Content

No source excerpt is available for this finding.

Undeclared Tool Scope

Medium
Category
MCP Least Privilege
Confidence
87% confidence
Finding

The skill instructs the agent to invoke a local CLI that stores persistent memory, which implies file-write capability, but the manifest does not declare any tool scope or allowed-tools restrictions. This creates a permission-boundary problem: an agent or runtime may execute broader filesystem-affecting actions than users or reviewers can infer from the metadata, reducing transparency and weakening sandbox enforcement.

Content

No source excerpt is available for this finding.

Vague Triggers

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

Using broad natural-language triggers like '记住...' and '我之前...' can cause the agent to store or retrieve persistent memory based on ambiguous conversational text, including sensitive data the user did not intend to save long-term. In a memory skill, ambiguous activation is especially risky because it affects persistent personal information and may create privacy violations or unintended data retention.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The skill persistently stores user memories, including preferences, decisions, people, and project details, but the description does not prominently warn users that sensitive personal or confidential information may be retained locally. In the context of a long-term memory system, lack of a clear storage warning materially increases privacy risk because users may disclose secrets, personal data, or business information without informed consent.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
89% confidence
Finding

The tag list uses only Chinese-language labels in configuration, which imposes a specific language on the skill's tagging behavior. There is no accompanying indication that the user can choose another language or that the skill is intentionally limited to a Chinese-language context.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The manifest clearly describes persistent long-term memory storage and management, but it does not include any user-facing warning about retention, review, or deletion consequences. In a memory skill, silent persistence can lead users to disclose sensitive personal data without informed consent, increasing privacy and data-handling risk.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
92% confidence
Finding

The skill exposes delete actions through verification tools, but the manifest does not warn that these operations may permanently remove stored memories. Users could trigger deletion during confirmation workflows without understanding the finality, causing loss of important records or manipulation of memory state.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
93% confidence
Finding

The module automatically creates a persistent SQLite database under the user's home directory and stores long-term memory content without any consent, notice, retention control, or encryption. In a memory skill, this is especially sensitive because stored records may contain personal preferences, history, or other private user data, increasing privacy and data exposure risk if the host is shared or compromised.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
98% confidence
Finding

The module description, user-facing messages, and intent extraction patterns are all written specifically for Chinese phrases such as 记住 and 我偏好, which constrains the skill to a single language. The file does not offer a language/locale choice or document a justified region-specific limitation, so this is a language-policy concern.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

When similarity-based deduplication decides an item should be updated, the code deletes the existing memory before inserting the new one, with no confirmation, rollback, or transactional protection. In a long-term memory skill, this can silently destroy previously verified user data due to imperfect similarity matching or insertion failures, causing integrity loss and making user memories tamper-prone.

Content

No source excerpt is available for this finding.

Context-Inappropriate Capability

Medium
Category
Not specified by scanner
Confidence
88% confidence
Finding

The manifest describes a tagged long-term memory system with storage, query, summarization, and verification behavior. In this file, the implementation launches an external interpreter via child_process.spawn to handle all operations, which introduces code-execution/process-spawning capability beyond the stated functional scope of a memory skill.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
87% confidence
Finding

This code launches an external Python process via child_process.spawn, which is a safety-relevant operation for code files under the missing-user-warnings rule. The file contains only an implementation comment and no user-facing prompt, disclosure, or warning indicating that the skill executes a subprocess.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
96% confidence
Finding

The module title, class docstrings, CLI help, and all user-facing messages in this file are written in Chinese, with no indication that other languages are supported or that Chinese is an opt-in preference. Under the policy, forcing a specific language without user choice is a natural-language policy concern.

Content

No source excerpt is available for this finding.

Description-Behavior Mismatch

Medium
Category
Not specified by scanner
Confidence
91% confidence
Finding

The manifest says the skill supports 时间范围查询, but memory_summary_request invokes memory_query with an empty query and only a time_range. In memory_query, L116-L117 reject calls where both query and tags are empty, so the advertised time-range-only lookup path does not actually work here.

Content

No source excerpt is available for this finding.

Description-Behavior Mismatch

Medium
Category
Not specified by scanner
Confidence
94% confidence
Finding

The manifest says the skill can generate summaries for specified time periods, but when period is provided as a month-like value, the code calls generate_summary_draft(days=30) rather than filtering to that month. It only overwrites summary.period afterward, which changes the label without ensuring the underlying content matches the requested period.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
76% confidence
Finding

archive_summary inserts multiple new memory records derived from prior conversation content, which is a persistence operation affecting user data. The broader file mentions confirmation conceptually, but this function performs the write with no local confirmation prompt, warning, or disclosure describing that confirmed summaries will be stored as new memories.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
88% confidence
Finding

This code persists a structured summary of prior conversations to disk in pending_summary.json, which can affect user privacy and local data handling. Although the module asks for confirmation before archival, there is no explicit disclosure in save_draft itself that user-derived content will be written to a file before that confirmation step.

Content

No source excerpt is available for this finding.

Intent-Code Divergence

Medium
Category
Not specified by scanner
Confidence
96% confidence
Finding

The CLI demo auto-sets feedback to "确认" and proceeds to archive the generated summary, bypassing the documented human confirmation step. In a memory skill handling conversation-derived personal data, this can cause unreviewed or incorrect summaries to be persisted as verified memories, undermining consent and data integrity.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

This Python file contains natural-language descriptions and user-facing strings exclusively in Chinese, indicating the skill is designed to communicate in a specific language by default. The policy forbids forcing a specific language or locale unless the user is given a choice or the constraint is clearly justified and documented.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
82% confidence
Finding

The skill documentation is entirely in Chinese and does not indicate whether other languages are supported or whether Chinese is required for a specific justified reason. Under the stated policy, forcing a specific language without user opt-in can be a natural-language policy concern.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
82% confidence
Finding

The manifest’s human-readable descriptions are consistently written in Chinese, with no indication that other languages are supported or that the user can opt into this locale. The policy explicitly calls out forced language or locale choices as a natural-language policy concern unless the constraint is documented and justified.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
97% confidence
Finding

This code file contains natural-language strings and documentation in Chinese throughout the CLI, beginning with the module docstring. Under the policy, forcing a specific language without user opt-in is a locale/language policy violation unless the tool is clearly documented as region-specific, which is not shown here.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
95% confidence
Finding

The natural-language text in the module docstring and command-line output is entirely in Chinese, which imposes a specific language on users without any opt-in or alternative. The policy scope includes natural-language strings in code files, so this constitutes a locale/language policy issue.

Content

No source excerpt is available for this finding.

Intent-Code Divergence

Low
Category
Not specified by scanner
Confidence
88% confidence
Finding

The docstring states '生成指定时间段的总结', implying the summary content is derived from the requested period. In the non-range branch, the implementation generates a generic 30-day draft and merely sets summary.period, which contradicts the documented behavior.

Content

No source excerpt is available for this finding.

Static analysis

Detected: suspicious.dangerous_exec

Shell command execution detected (child_process).

Critical
Code
suspicious.dangerous_exec
Location
src/index.js:16