Back to skill

Security audit

计算机行业转行规划助手

Security checks for vulnerabilities and agentic risk

Overview

This career-planning skill is coherent, but it creates an executable local HTML report from personal answers without clear consent or sanitization and loads third-party JavaScript.

Review this skill before installing if reports may contain sensitive career or personal details, be shared, or be opened in a networked browser. Prefer adding explicit user consent before report creation, escaping or sanitizing all inserted values, bundling Chart.js locally or using SRI, and warning users that the HTML report persists data in the workspace.

Vulnerability Patterns
  • Insecure DependenciesIntroduces malicious components through unsafe dependency sources
  • 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
Findings (2)

T09 · Insecure Skill Coding Practices

Warning
Location
SKILL.md:383
Finding

Unescaped User Input Is Inserted into Executable HTML Reports

Content
View full analysis
Java后端开发...` | | `{{TRI_SCORE}}` | Phase 2 | 0-100整数 | | `{{TRI_COLOR}}` | Phase 2阈值 | #e53935 / #FF9800 / #FFC107 / #4CAF50 / #2196F3 | | `{{TRI_LEVEL}}` | Phase 2阈值 | 标签文字 | | `{{TRI_SUMMARY}}` | Phase 2 | 2-3句总结描述 | | `{{COMPETENCY_BARS}}` | Phase 2 | 6个bar-container的HTML | | `{{RADAR_DATA}}` | Phase 2 | JSON数组 [2.8, 3.5, 2.0, ...] | | `{{RADAR_TARGET}}` | Phase 3 Top方向要求 | JSON数组 | | `{{DIRECTION_CARDS}}` | Phase 3 | 前6-8个方向卡片的HTML | | `{{TOP_DIRECTION}}` | Phase 3 | 匹配度最高的方向名 | | `{{GAP_ANALYSIS_ROWS}}` | Phase 4 | 6行的HTML table rows | | `{{QUARTERLY_PLAN}}` | Phase 5 | 4个timeline-quarter的HTML | | `{{LEARNING_RESOURCES}}` | 根据Top方向生成 | 4-6个resource-item的HTML | | `{{RISK_WARNINGS}}` | 全局分析 | 3-5个warning-box的HTML | ``` Those values are inserted into active HTML contexts without any documented escaping or sanitization: ```html 计算机行业转行规划报告 - {{REPORT_TITLE}} ``` ```html
{{PROFILE_TAGS}}
``` ```html

{{TRI_SUMMARY}}

``` ```html
{{DIRECTION_CARDS}}
``` ```html {{GAP_ANALYSIS_ROWS}} ``` ```html
{{QUARTERLY_PLAN}}
``` ```html
Remediation
View remediation
` as `>` - `"` as `"` - `'` as `'` 2. Do not construct HTML fragments by concatenating questionnaire answers. Use a template engine with automatic escaping or create elements through safe DOM APIs such as `textContent`. 3. Treat each placeholder according to its context: - Escape `REPORT_TITLE`, `REPORT_DATE`, `TRI_LEVEL`, `TRI_SUMMARY`, and `TOP_DIRECTION` as text. - Validate `TRI_SCORE` as an integer in the range 0-100. - Validate radar data as finite numeric arrays with exactly six entries in the range 0-5. - Allowlist color values rather than accepting arbitrary CSS. - Sanitize intentionally generated HTML fragments with a strict allowlist. 4. Add a restrictive Content Security Policy. Prefer a policy that blocks inline scripts and event handlers, such as: ```html ``` 5. Add automated tests using payloads that attempt to escape title, text, table, attribute, JSON, CSS, and script contexts. Confirm that generated reports display payloads as text rather than executing them. ]]>

T08 · Insecure Dependencies

Note
Location
assets/report_template.html:7
Finding

Externally Hosted JavaScript Is Loaded Without Subresource Integrity

Content
View full analysis
``` ### Technical Analysis The generated report downloads and executes Chart.js from a third-party CDN whenever the report is opened with network access. Although the dependency uses HTTPS and specifies version `4.4.0`, the script tag does not include a Subresource Integrity hash. Without integrity verification, the browser cannot confirm that the returned file is identical to the reviewed dependency. A compromise of the CDN, package publication channel, or delivery path could therefore cause modified JavaScript to execute in generated reports. Opening the report also creates an external request to jsDelivr, disclosing standard request metadata such as the viewer's IP address, user-agent information, and request time. ### Attack Path 1. The Skill generates an HTML report containing the external script reference. 2. A user opens the report while connected to the Internet. 3. The browser requests Chart.js from jsDelivr. 4. If the CDN response or upstream package artifact has been compromised, the browser receives modified JavaScript. 5. Because no integrity hash is present, the browser accepts and executes the modified script. 6. The malicious dependency can manipulate report content and perform actions available to JavaScript in the report's browser context. ### Impact Assessment A compromised dependency could execute arbitrary browser-side JavaScript in every affected report that loads it. This could permit: - Reading and modifying the report DOM. - Falsifying scores, recommendations, and warnings. - Displaying phishing content or malicious redirects. - Sending report content or browser metadata to external systems, subject to browser security restrictions. No ev ...[truncated 249 chars]
Remediation
View remediation
``` The hash must be generated from the exact production artifact and independently verified before release. 3. Apply a restrictive Content Security Policy that limits script sources to the bundled asset or the explicitly approved CDN. 4. Pin and periodically review the exact dependency version and artifact checksum. 5. Document that opening the report may make a request to jsDelivr. Where privacy or offline operation is important, provide a fully self-contained report with no external network dependencies. ]]>
Vulnerability Patterns
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • Excessive AgencyUnrestricted Tool Access, Autonomous Decision Making, Scope Creep
  • Trigger AbuseOverly Broad Trigger, Shadow Command Trigger, Keyword Baiting Trigger
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
Findings (9)

Vague Triggers

Medium
Category
Not specified by scanner
Confidence
93% confidence
Finding

The trigger list is very broad and includes generic phrases such as 'IT转行' and '转管理', which can cause the skill to activate in conversations that are only loosely related to career-transition planning. Unintended invocation can lead to inappropriate context switching and unnecessary collection or processing of sensitive career information from users who did not explicitly request this workflow.

Content

No source excerpt is available for this finding.

Vague Triggers

Medium
Category
Not specified by scanner
Confidence
90% confidence
Finding

The 'When to Use' section defines activation scenarios in broad terms like career anxiety, salary ceiling, or exploring possibilities, but does not define when the skill should not activate. In an agent setting, this can cause over-eager routing into a long 30-question workflow and prompt for personal/professional details even when the user's request would be better handled by lighter guidance.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The skill instructs the agent to write a generated HTML file into the workspace without an explicit user-facing warning or consent step. File creation is a side effect that may surprise users, can persist sensitive career data locally, and may expose private information if the workspace is shared, synced, or later reused.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
98% confidence
Finding

The instruction “所有沟通使用简体中文” imposes a fixed language policy on all interactions. This is a natural-language policy issue because the skill does not provide opt-in, fallback language options, or a documented reason that the tool must be Chinese-only.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The HTML document explicitly sets lang="zh-CN", and the visible report content is written entirely in Simplified Chinese. This imposes a specific language/locale on all users without any opt-in, alternative language selection, or documented regional constraint, which matches the policy-violation category for forced language settings.

Content

No source excerpt is available for this finding.

Context-Inappropriate Capability

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The template loads Chart.js from a third-party CDN, which introduces remote code execution in the browser whenever the report is opened. If the CDN, dependency, or delivery path is compromised, arbitrary JavaScript will run in the context of the generated report; this is especially unnecessary for an otherwise local HTML report and also creates a privacy/network dependency.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
88% confidence
Finding

SQP-3 applies to all file types and covers language or locale policy violations. This document presents all operational guidance in Chinese and does not state that Chinese is optional, user-selected, or required for a region-specific audience, which can amount to forcing a specific language without opt-in.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
96% confidence
Finding

This markdown file contains all user-facing instructions and templates in Chinese, but it does not indicate that the user can choose another language or that the skill is intentionally limited to a Chinese-speaking audience. Under the natural-language policy rule, forcing a specific language without user opt-in is a policy concern.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
86% confidence
Finding

SQP-3 applies to all file types and covers language or locale policy violations. This markdown content presents all guidance in Chinese only, with no user opt-in, alternative language option, or explanation that the skill is region-specific.

Content

No source excerpt is available for this finding.

Static analysis

No suspicious patterns detected.