T09 · Insecure Skill Coding Practices
- Location
index.js:15- Finding
Process-Global Confirmation State Allows Cross-Session Data Contamination
- Content
View full analysis
- Remediation
View remediation
Security audit
Security checks for vulnerabilities and agentic risk
This note-writing skill is mostly purpose-aligned, but it writes to a fixed local folder and requests extra messaging and scheduled-execution authority that its documentation does not clearly disclose.
Review before installing. Use it only if you are comfortable with it creating and appending Markdown files under /Users/macbook/Documents/OC_club, and prefer a revised version that uses a configurable vault path, removes message.send and the cron trigger unless implemented, avoids import-time writes, scopes confirmation state per user/session, and accurately documents the remote Mermaid dependency or bundles it locally.
index.js:15Process-Global Confirmation State Allows Cross-Session Data Contamination
metadata.json:8Skill Requests Unnecessary Messaging and Scheduled-Execution Capabilities
index.js:7Module Import Causes Unsolicited Writes to a Hard-Coded User Directory
smart-auto-note.html:6Bundled HTML Executes a Remote Third-Party Script Without Integrity Verification
该技能描述与代码存在明显不一致。首先,“语义智能识别自动分类”暗示较强的语义分析能力,但代码中的 classify() 和 classifyArchive() 仅依赖硬编码关键词包含判断,不属于通常意义上的语义智能识别。其次,描述称写入 Obsidian 笔记,但代码只是向 /Users/macbook/Documents/OC_club 下的若干 Markdown 文件追加内容,没有任何 Obsidian 插件、API、vault 交互或应用集成逻辑,因此更准确地说是写本地 Markdown 文件,而不是明确的 Obsidian 集成。最后,描述称“支持待办自动归档”,虽然代码有 doArchive()、pendingArchiveState 和归档格式化逻辑,但 main() 中并没有设置 pendingArchiveState 或检测待办完成并触发归档,因此这项能力在当前代码片段中并未真正实现。整体来看,技能的核心宣称比实际实现更强,且包含未接通的功能,应判定为描述与行为不匹配。
The natural-language content of the skill is entirely in Chinese and describes direct natural-language triggering, but nowhere offers the user a language/locale option or states that the skill is intentionally limited to a Chinese-speaking context. Under the policy, forcing a specific language without user opt-in is a locale-policy violation.
Natural-language strings throughout the skill, including categories, prompts, file names, and status messages, are fixed in Chinese with no mechanism for language selection. This imposes a specific language/locale on all users rather than offering a choice or documenting a justified locale restriction.
The implementation operates on fixed local Markdown paths under a specific filesystem directory rather than interacting with Obsidian as an application or vault abstraction. It also defines archive helpers and state, but the main flow never sets pendingArchiveState or invokes archive logic from todo completion, so the claimed '待办自动归档' capability is not actually implemented.
The skill automatically creates and appends to user files in a hard-coded personal directory without an explicit first-run consent prompt or clear disclosure at execution time. In an agent setting, silent file modification can lead to unintended persistence, privacy issues, and unauthorized alteration of personal notes, especially when ordinary chat text is treated as writeable content.
The page declares lang="zh-CN", and the visible UI text throughout the document is exclusively Chinese. Under the policy, forcing a specific language without user opt-in or a documented justification is a natural-language policy violation.
The page explicitly claims 'zero third-party dependencies' and 'no external interfaces' while importing Mermaid from a remote CDN, so the documentation is materially misleading. That remote script creates a supply-chain and network dependency: if the CDN, package, or transit path is compromised, arbitrary JavaScript can run in the page context.
The comment '主入口 (纯净版)' and nearby notes suggest a simplified but coherent feature set, yet the archive confirmation state machine is still present without any code path that populates pendingArchiveState. This creates misleading documentation about effective behavior because the code advertises archive handling in comments and structure but cannot perform it in practice.
The manifest includes natural-language comments exclusively in Chinese such as '保留这个,这是官方推送通道' and '新增:OpenClaw 内置 Cron 定时触发器', which impose a specific language context without offering any language choice or documenting a region-specific need. This matches the policy category for language or locale constraints appearing in natural-language content.
The HTML file loads executable JavaScript from a third-party CDN even though its purpose is only to render a static rules diagram. While this may be for convenience, any remote script execution expands the attack surface and could be abused through CDN compromise, dependency hijacking, or unexpected script changes.