Back to skill

Security audit

local hacker news index page, markdown news frontend

Security checks for vulnerabilities and agentic risk

Overview

This skill is a simple local Markdown-to-HTML news converter, with some bounded quality and link-safety caveats but no hidden persistence, exfiltration, or privilege-seeking behavior.

Install only if you want a Chinese-oriented local news-page generator. Avoid converting untrusted Markdown, or review generated links before opening/clicking the HTML because unsupported schemes such as javascript: are not filtered.

Vulnerability Patterns
  • 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
  • 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 (1)

T09 · Insecure Skill Coding Practices

Warning
Location
scripts/hnews.py:243
Finding

Unvalidated URL Schemes in Generated HTML Links

Content
View full analysis
Remediation
View remediation
str: url = raw_url.strip() parsed = urlsplit(url) if parsed.scheme.lower() not in {'https', 'http'}: raise ValueError(f'Unsupported URL scheme: {parsed.scheme or "missing"}') if not parsed.netloc: raise ValueError('The URL must contain a valid host') return url ``` Apply validation when parsing each item: ```python try: url = validate_news_url(m.group(3)) except ValueError as exc: print(f'Warning: skipping unsafe URL: {exc}', file=sys.stderr) i += 1 continue ``` At the rendering boundary, retain contextual escaping: ```python url = html_mod.escape(item['url'], quote=True) ``` A defense-in-depth policy can also be emitted in the document head: ```html ``` The exact policy should be tested against supported browsers and the intended standalone-file workflow. ]]>
Vulnerability Patterns
  • Trigger AbuseOverly Broad Trigger, Shadow Command Trigger, Keyword Baiting Trigger
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
  • Supply ChainUnpinned Dependencies, External Script Fetching, Obfuscated Code
Findings (3)

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
90% confidence
Finding

The natural-language instructions, usage description, and trigger guidance are all presented only in Chinese, with no indication that the user can choose another language or that the skill is intentionally region-specific. Under the stated policy, forcing a specific language without user opt-in is a locale-policy concern.

Content

No source excerpt is available for this finding.

Vague Triggers

Medium
Category
Not specified by scanner
Confidence
96% confidence
Finding

The trigger condition uses broad phrases like “生成新闻网页” and “hnews” without clear scoping to this specific Markdown-to-HTML news conversion task. In an agent environment, that can cause the skill to activate in unrelated contexts, leading to unintended file handling or output generation when the user did not explicitly request this tool.

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 HTML hard-codes lang="zh-CN", which imposes a specific language/locale on all output. The file also uses Chinese-only UI strings throughout, but does not offer any user opt-in or locale selection, matching the policy concern for forced language/locale behavior.

Content

No source excerpt is available for this finding.