Back to skill

Security audit

企业级 Web UAT 验收测试

Security checks for vulnerabilities and agentic risk

Overview

The skill is a coherent enterprise UAT workflow, but its bundled HTML report template can render copied test content as active browser content if used without escaping.

Review before installing if you plan to generate HTML reports. Use a generator that escapes all scalar fields, sanitizes any rich blocks, validates URLs, and keeps secrets, personal data, cookies, and tokens out of evidence. The UAT workflow itself has sensible authorization boundaries for high-risk actions.

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
assets/report-template.html:96
Finding
Unescaped Template Placeholders Permit HTML and Script Injection in Generated Reports<![CDATA[ ## Vulnerability Details **File Location**: `assets/report-template.html`, lines 96–117 **Vulnerability Type**: Unescaped HTML template injection **Risk Level**: Medium ### Vulnerable Code ```html <section class="tab active" id="module-1"> <h2>{{MODULE_NAME}}</h2> <p><strong>Module conclusion:</strong>{{MODULE_CONCLUSION}}</p> <h3>Covered submenus</h3> <p>{{COVERED_MENUS}}</p> <h3>Formal issues</h3> <div class="issue formal"> <span class="badge danger">Formal ISSUE</span> <strong>{{ISSUE_ID}}|{{ISSUE_TITLE}}</strong> <p><strong>URL:</strong>{{PAGE_URL}}</p> <p><strong>Reproduction steps:</strong>{{REPRO_STEPS}}</p> <p><strong>Expected result:</strong>{{EXPECTED}}</p> <p><strong>Actual result:</strong>{{ACTUAL}}</p> <p><strong>Evidence:</strong>{{EVIDENCE_REF}}</p> </div> {{FORMAL_ISSUE_BLOCKS}} ``` Additional raw block placeholders, including `{{MODULE_TAB_BUTTONS}}`, `{{EVIDENCE_FIGURES}}`, and `{{MODULE_SECTIONS}}`, occur elsewhere in the same template and increase the exposed rendering surface. ### Technical Analysis The HTML report template places scalar values and generated content blocks directly into executable HTML contexts. The project does not define contextual output encoding, a strict HTML sanitizer, or a trusted rendering boundary for these placeholders. UAT data can originate from an application being tested, including page titles, displayed messages, URLs, issue descriptions, actual results, and evidence captions. Such values must be treated as untrusted. If report generation replaces a placeholder verbatim, attacker-controlled markup can become active HTML. For example, a tested application could display content containing an element with an event handler. If that content is copied into `{{ACTUAL}}`, `{{ISSUE_TITLE}}`, or another placeholder without encoding, the browser may execute it when a reviewer opens the generated report. Whole-block placeholders are especially sensitive becaus ...[truncated 1461 chars]
Remediation
<![CDATA[ ## Remediation Suggestions 1. Apply contextual HTML escaping to every scalar placeholder, including project names, conclusions, module names, issue titles, URLs, reproduction steps, expected results, actual results, and evidence references. 2. Treat all content copied from the tested application as untrusted, even when it appears to be ordinary text. 3. Generate repeated tables, issue blocks, tabs, and evidence figures through a templating engine with automatic escaping enabled by default. 4. Where rich HTML is required, sanitize it with a strict allowlist that permits only necessary formatting elements and safe attributes. 5. Explicitly reject: - `script`, `iframe`, `object`, `embed`, and active SVG content; - inline event-handler attributes such as `onclick` and `onerror`; - `javascript:` and other dangerous URL schemes; - inline styles or elements capable of deceptive document overlays, unless strictly required. 6. Validate URL placeholders and allow only expected schemes such as `https`, or render URLs as escaped plain text. 7. Add a restrictive Content Security Policy, preferably disallowing inline scripts. Move the existing tab-handling script to a trusted local script file if necessary. 8. Add automated tests using payloads in every placeholder to verify that generated reports render them as inert text. 9. Document the trust boundary and require sanitization before any value is inserted into whole-block placeholders. ]]>
Vulnerability Patterns
  • 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
  • Excessive AgencyUnrestricted Tool Access, Autonomous Decision Making, Scope Creep
Findings (5)

Natural-Language Policy Violations

Medium
Confidence
95% confidence
Finding
The skill content is written entirely in Chinese and does not state that language selection is optional or configurable. Under the policy, forcing a specific language without user opt-in is a natural-language locale violation unless the regional constraint is explicitly documented and justified.

Natural-Language Policy Violations

Medium
Confidence
93% confidence
Finding
The HTML declares `lang="zh-CN"` and the report title/content labels are written in Simplified Chinese, which imposes a specific language/locale in the generated artifact. The file does not indicate any user opt-in, configurability, or region-specific justification for this locale restriction.

Natural-Language Policy Violations

Medium
Confidence
87% confidence
Finding
The document title and all template content are written entirely in Chinese, which constitutes a language-specific instruction artifact without any indication that users may choose another language or that the constraint is region-specific. Under the policy, forcing a specific language without user opt-in or clear justification is a natural-language policy violation.

Natural-Language Policy Violations

Medium
Confidence
89% confidence
Finding
The title and entire standard are written as mandatory operating guidance in Chinese, with no indication that users may choose another language or that the standard is limited to a China-specific or Chinese-only compliance context. Under the policy, forcing a specific language without opt-in or documented justification is a natural-language locale violation.

Natural-Language Policy Violations

Low
Confidence
95% confidence
Finding
This markdown file contains user-facing instructions only in Chinese, which can amount to a language/locale policy issue when no opt-in or alternative language is provided. The file does not state that it is intended solely for a Chinese-speaking or region-specific audience.

Static analysis

No suspicious patterns detected.