T09 · Insecure Skill Coding Practices
- Location
index.ts:49- Finding
Unfiltered Persistent Capture of Conversation Content
- Content
View full analysis
{ if (msg.content.type === "text" && msg.content.text?.trim()) { const timestamp = new Date(msg.timestamp); // 双写:同时写入文件和向量库 await Promise.all([ writeToMarkdown("爸爸", msg.content.text, timestamp), writeToLanceDB("爸爸", msg.content.text, timestamp, api) ]); } }); // 监听助理发出的消息,过滤工具调用和系统消息 api.events.on("outbound-message", async (msg: OutboundMessage) => { if (msg.content.type === "text" && msg.content.text?.trim() && msg.content.text !== "NO_REPLY" && !msg.toolCall) { const timestamp = new Date(); await Promise.all([ writeToMarkdown("张褐", msg.content.text, timestamp), writeToLanceDB("张褐", msg.content.text, timestamp, api) ]); } }); api.logger.info("✅ 记忆自动同步插件启动成功,所有对话将自动双写到记忆文件和LanceDB向量库"); } ``` ### Technical Analysis The plugin subscribes globally to inbound and outbound text-message events and sends every qualifying message to both a Markdown writer and the OpenClaw memory store. The filtering only excludes empty text, tool calls, and the special `NO_REPLY` value. It does not detect credentials, authentication tokens, pr ...[truncated 2013 chars]- Remediation
View remediation
