Back to skill

Security audit

Dan Koe Writer

Security checks for vulnerabilities and agentic risk

Overview

The skill is a coherent Chinese writing helper, but its article-fetching script can browse arbitrary user-supplied URLs without network safeguards and feeds untrusted content directly into model prompts.

Install only if you are comfortable with a writing helper that may run a browser against URLs you provide. Avoid feeding it untrusted links, localhost/private-network URLs, or sensitive local files, and review any extracted JSON before reusing it in future prompts or knowledge files.

Vulnerability Patterns
  • Skill Instruction HijackingAlters the agent's session goals or safety constraints when the skill loads
  • Insecure Skill Coding PracticesFinds exploitable flaws such as hardcoded secrets or command injection
  • Agent Memory PoisoningWrites attacker-controlled rules into memory that affect later sessions
  • 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 (2)

T09 · Insecure Skill Coding Practices

Warning
Location
scripts/goldmine.py:190
Finding

Unrestricted Browser Navigation Enables Server-Side Request Forgery

Content
View full analysis
tuple: """从 URL 获取内容""" try: from playwright.sync_api import sync_playwright with sync_playwright() as p: browser = p.chromium.launch() page = browser.new_page() page.goto(url, wait_until="networkidle", timeout=30000) page.wait_for_timeout(2000) content = page.evaluate("document.getElementById('js_content')?.innerText || ''") title = page.title() browser.close() if not content: return None, None return content, title except ImportError: print("错误: 需要安装 playwright (pip install playwright && playwright install chromium)") return None, None except Exception as e: print(f"抓取失败: {e}") return None, None ``` The untrusted URL is accepted and passed to this function without validation: ```python parser.add_argument("url", nargs="?", help="要拆解的内容URL") ``` ```python elif args.url: content, title = fetch_content_from_url(args.url) if not content: sys.exit(1) source_name = source_name or title print(f"成功抓取: {title}") ``` ### Technical Analysis The script passes a user-controlled URL directly to Playwright's `page.goto()` method. It does not validate: - The URL scheme. - The requested hostname. - Whether the hostname resolves to a loopback, private, link-local, or otherwise restricted address. - Redirect destinations. - The response content type or size. - Whether the destination belongs to the documented WeChat domain. A headless browser request originates from the environment running the Skill and therefore inherits that environment's network reachability. An attacker who ca ...[truncated 2180 chars]
Remediation
View remediation

T01 · Skill Instruction Hijacking

Warning
Location
scripts/goldmine.py:28
Finding

Untrusted Article Content Is Embedded Verbatim into an Agent Prompt

Content
View full analysis
str: """获取用于 LLM 提取的 prompt""" return BUILDING_BLOCKS_TEMPLATE.format(content=content) ``` The content can originate from a local file, direct text, or a remote page: ```pyt ...[truncated 3797 chars]
Remediation
View remediation
Vulnerability Patterns
  • System Prompt LeakageDirect Leakage, Indirect Extraction, Tool-Based Exfiltration
  • 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
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
Findings (21)

Tp4

High
Category
MCP Tool Poisoning
Confidence
91% confidence
Finding

The skill description and usage instructions overstate capabilities and omit important behavior, especially external fetching from user-supplied URLs and reliance on an external agent/model to complete processing. This mismatch is dangerous because reviewers or orchestrators may approve or invoke the skill under incorrect assumptions, enabling network access and content processing paths that were not transparently declared.

Content

No source excerpt is available for this finding.

Direct Prompt Extraction

High
Category
System Prompt Leakage
Confidence
85% confidence
Finding

Skill contains instructions that could directly expose system prompts, internal rules, or hidden instructions to users or external parties.

Content

Scanner excerpt · scripts/write.py (reported line 244)May include surrounding context.

python
"tags": ["标签1", "标签2"]
}}"""

    return prompt


def format_context_as_markdown(context: dict, platform: str, length: int) -> str:

Undeclared Tool Scope

Medium
Category
MCP Least Privilege
Confidence
84% confidence
Finding

The skill documents executable scripts that read local files and imply writing or maintaining a local knowledge base, but it does not declare any explicit tool scope or permissions boundaries. In an agent ecosystem, missing scope declarations can cause the agent to invoke file-capable behaviors more broadly than intended, increasing the risk of unintended file access or modification.

Content

No source excerpt is available for this finding.

Vague Triggers

Medium
Category
Not specified by scanner
Confidence
94% confidence
Finding

The manifest description lists broad activation scenarios such as '用户需要写作方向或创意灵感' and '用户要生成完整的公众号/小红书/推特文章', which overlap with common writing requests and do not clearly distinguish when this specific skill should or should not activate. There are no explicit trigger phrases, scope constraints, or negative examples to prevent unintended invocation for general writing help.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
84% confidence
Finding

The natural-language description is presented entirely as a Chinese-language writing tool and frames outputs around Chinese platforms like 公众号 and 小红书 without stating that language is optional or user-selectable. This can constitute a language/locale policy issue because the skill appears to prescribe a specific language context without explicit user opt-in.

Content

No source excerpt is available for this finding.

Vague Triggers

Medium
Category
Not specified by scanner
Confidence
92% confidence
Finding

The template defines "激活词/触发语" as resonance-inducing keywords without specifying where, when, or how these terms should activate the skill. Broad everyday words in the examples make unintended invocation more likely because there are no exclusion conditions or negative examples.

Content

No source excerpt is available for this finding.

Vague Triggers

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The listed trigger words such as "不确定" and "未知" are generic conversational terms rather than narrow invocation phrases. Without contextual limits, these triggers overlap heavily with normal user speech and create ambiguity about intended activation.

Content

No source excerpt is available for this finding.

Vague Triggers

Medium
Category
Not specified by scanner
Confidence
94% confidence
Finding

Terms like "忙碌", "效率", and "没时间" are broad productivity expressions common in ordinary conversation. The file provides no constraints, negative examples, or boundary conditions to distinguish true activation from incidental mention.

Content

No source excerpt is available for this finding.

Vague Triggers

Medium
Category
Not specified by scanner
Confidence
93% confidence
Finding

Keywords such as "方向", "焦点", and "选择" are highly general and likely to appear in many unrelated interactions. Because the document does not define trigger scope, they could lead to unintended matching or invocation.

Content

No source excerpt is available for this finding.

Vague Triggers

Medium
Category
Not specified by scanner
Confidence
91% confidence
Finding

Phrases like "行动力" and "学太多" are common descriptive language and are not sufficiently unique to a narrow activation scenario. The absence of any exclusion rules or trigger context makes the invocation criteria vague.

Content

No source excerpt is available for this finding.

Vague Triggers

Medium
Category
Not specified by scanner
Confidence
90% confidence
Finding

The trigger list includes very general terms such as "成长" and "我是谁", which can occur in many benign discussions. With no stated context or negative examples, the document leaves activation semantics overly broad.

Content

No source excerpt is available for this finding.

Vague Triggers

Medium
Category
Not specified by scanner
Confidence
88% confidence
Finding

The trigger terms "浅层", "低估", and "效率" are generic concepts that could match a wide variety of unrelated content. The file does not provide constraints or examples to clarify intended activation boundaries.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
87% confidence
Finding

This markdown file contains instructional content largely in Chinese, with only limited English labeling, and does not indicate that the user can choose another language. Under the policy, forcing a specific language without user opt-in is a natural-language policy concern unless the locale restriction is clearly documented and justified.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
91% confidence
Finding

The file’s natural-language instructions and labels are entirely in Chinese, and there is no indication that users may choose another language or that the skill is intentionally limited to a Chinese-speaking audience. Under the policy, forcing a specific language without user opt-in is a natural-language policy violation.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The file’s user-facing docstring, CLI descriptions, and embedded extraction template are all written as mandatory Chinese instructions, indicating the skill is designed to operate in a fixed language. The policy only permits this when the skill offers a language/locale choice or clearly documents a justified regional constraint, which is not present here.

Content

No source excerpt is available for this finding.

Intent-Code Divergence

Medium
Category
Not specified by scanner
Confidence
97% confidence
Finding

The output text tells users to run python goldmine.py --load-json blocks.json, implying the script supports loading extracted JSON and saving it to the knowledge base. However, no --load-json argument is defined in the parser and no corresponding implementation exists anywhere in the file, so the documented workflow contradicts actual behavior.

Content

No source excerpt is available for this finding.

Intent-Code Divergence

Medium
Category
Not specified by scanner
Confidence
98% confidence
Finding

The interactive guidance says step 4 is to use --load-json to save results to the knowledge base and shows it in the example flow. In reality, the parser only accepts URL/text/file input and output flags; there is no --load-json option or save-to-knowledge-base path, so the inline operational instructions conflict with the implemented code.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
96% confidence
Finding

This code file contains natural-language instructions, help text, and runtime output entirely in Chinese, including the module docstring and user-facing CLI descriptions. The file does not offer a language selection option or document a justified locale restriction, which conflicts with the policy against forcing a specific language without user opt-in.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
94% confidence
Finding

The generated prompt is entirely written in Chinese and directs the agent to produce the article and JSON fields in Chinese-formatted content, while the script provides no option for users to select another language. This is a natural-language locale constraint that applies across all uses of the skill and is not documented as a justified region-specific limitation.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
87% confidence
Finding

This markdown content includes untranslated English terms such as "passion" and "life design" within otherwise Chinese guidance, which can impose a language preference without user opt-in. The file does not state that it is intended for bilingual users or offer an alternative fully localized version.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
86% confidence
Finding

This markdown file presents core headings and examples in Chinese while also embedding English phrases, but it does not state whether the skill is intended specifically for Chinese-speaking users or offer a language/locale choice. Under the policy, forcing or assuming a specific language without user opt-in can be a natural-language policy issue.

Content

No source excerpt is available for this finding.