Back to skill

Security audit

保单照妖镜 - 保单权益保障PK擂台

Security checks for vulnerabilities and agentic risk

Overview

The skill is a coherent insurance-policy comparison helper, but it handles sensitive documents and creates an auto-opened HTML report with unsafe templating and remote JavaScript, so it should be reviewed before use.

Review this skill before installing. Use it only if you are comfortable uploading or extracting insurance policy data, sending insurer/product names to external searches, and creating a persistent local HTML report. Prefer requiring confirmation before searches and file creation, disabling auto-open, escaping all report content, and bundling or integrity-pinning the chart library.

Vulnerability Patterns
  • Skill Instruction HijackingAlters the agent's session goals or safety constraints when the skill loads
  • Remote Payload Retrieval and ExecutionFetches external code whose behavior can change after review
  • 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
  • Embedded Malicious CodeShips malicious scripts inside the skill and executes them locally
Findings (3)

T01 · Skill Instruction Hijacking

Warning
Location
scripts/compare_policies.py:409
Finding

Hard-Coded Commercial Steering When Reputation Data Is Unavailable

Content
View full analysis
Remediation
View remediation

T09 · Insecure Skill Coding Practices

Error
Location
assets/template.html:78
Finding

Stored HTML and JavaScript Injection Through Unescaped Report Placeholders

Content
View full analysis
Policy A
{{POLICY_A_NAME}}
{{POLICY_A_INSURER}}
{{POLICY_A_PREMIUM}} /year
{{POLICY_A_SCORE}}
Policy B
{{POLICY_B_NAME}}
{{POLICY_B_INSURER}}
{{POLICY_B_PREMIUM}} /year
{{POLICY_B_SCORE}}
``` ```html
{{DIMENSIONS_HTML}} {{CLAIM_REPUTATION_HTML}} {{PITFALLS_HTML}} {{RECOMMENDATIONS_HTML}}
``` ```javascript legend: { data: [ 'Policy A - {{POLICY_A_NAME}}', 'Policy B - {{POLICY_B_NAME}}' ] }, series: [{ type: 'radar', data: [ { value: {{RADAR_A_VALUES}}, name: 'Policy A - {{POLICY_A_NAME}}' }, { value: {{RADAR_B_VALUES}}, name: 'Policy B - {{POLICY_B_NAME}}' } ] }] ``` ### Technical Analysis The template places policy-derived values into three distinct parser contexts: 1. HTML text contexts, such as `{{POLICY_A_NAME}}`. 2. Raw HTML contexts, such as `{{PITFALLS_HTML}}`. 3. JavaScript string and expression contexts, such as policy names and radar arrays. No contextual escaping, sanitization, type validation, or Content Security Policy is present. The documented workflow instructs the Agent to replace placeholders and automatically open the resulting file in a browser. HTML escaping alone would not fully remediate the issue because values inserted into ...[truncated 1867 chars]
Remediation
View remediation

T03 · Remote Payload Retrieval and Execution

Warning
Location
assets/template.html:7
Finding

Remote JavaScript Is Executed Without Integrity Verification

Content
View full analysis
``` ### Technical Analysis Every generated report loads and executes JavaScript from a third-party CDN. Although the dependency uses HTTPS and specifies an ECharts version, the template does not include a Subresource Integrity hash. Version pinning constrains the requested package path but does not cryptographically verify the returned bytes. The effective executable content can therefore change after the Skill package has been reviewed if the package artifact, CDN infrastructure, account, or delivery path is compromised. The report also makes an external request merely by being opened. This behavior conflicts with an otherwise local report workflow and is not prominently disclosed to the user. Because the resource is executable code fetched at report-viewing time, the best matching classification is remote payload retrieval and execution. ### Attack Path 1. The comparison workflow generates an HTML report. 2. The report is automatically opened in a browser. 3. The browser requests `echarts.min.js` from the external CDN. 4. The response is accepted without an integrity check. 5. If the remote resource has been compromised, attacker-controlled JavaScript executes in the report page. 6. That JavaScript can access and manipulate report DOM content and initiate additional browser requests. ### Impact Assessment A compromised remote dependency receives the same page-level JavaScript capabilities as the intended chart library. It may: - Read all insurance data rendered in the report. - Modify scores, recommendations, and warnings. - Exfiltrate rendered policy information through network requests. - Display phishing content or redirect the user. - Retrieve and execute additional b ...[truncated 189 chars]
Remediation
View remediation
Vulnerability Patterns
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Trigger AbuseOverly Broad Trigger, Shadow Command Trigger, Keyword Baiting Trigger
  • YARA SignaturesMalware Match, Webshell Match, Cryptominer Match
  • MCP Least PrivilegeUnderdeclared Capability, Wildcard Permission, Missing Permission Declaration
  • MCP Tool PoisoningHidden Instructions, Unicode Deception, Parameter Description Injection
Findings (13)

Tp2

High
Category
MCP Tool Poisoning
Confidence
85% confidence
Finding

Mixing characters from multiple Unicode scripts in a single identifier is a common technique to create visually ambiguous tool names.

Content

No source excerpt is available for this finding.

Tp4

High
Category
MCP Tool Poisoning
Confidence
97% confidence
Finding

The documented behavior promises OCR, policy parsing, real-time reputation searches, and visual report generation, but the analyzed capability does not implement those features. This mismatch is dangerous because users and orchestrators may make trust decisions based on false assumptions, causing sensitive insurance documents to be handled in ways not actually supported or audited, and undermining security review of the real behavior.

Content

No source excerpt is available for this finding.

Vague Triggers

High
Category
Not specified by scanner
Confidence
97% confidence
Finding

The trigger conditions are so broad that ordinary insurance questions may invoke the skill unexpectedly, increasing the chance that users disclose policy documents or personal insurance details without intending to activate document-processing logic. Over-broad activation expands the attack surface and can lead to unintended data handling.

Content

No source excerpt is available for this finding.

YARA rule 'agent_skill_mcp_tool_poisoning_metadata': MCP/tool metadata poisoning indicators in tool schemas or skill manifests [agent_skills]

High
Category
YARA Match
Confidence
80% confidence
Finding

YARA rule matched a hack tool or exploit indicator (offensive tools, reconnaissance, privilege escalation, or exploit frameworks).

Content

Scanner excerpt · scripts/compare_policies.py (reported line 425)May include surrounding context.

python
.append(f"{prefix} 🔴 有投诉 **以各种理由拒赔**")

    # 生成场景建议
    recommendations = []

    ded_a = policy_a.get("dimensions", {}).get("deductible_and_waiting", {}).get("medical_deductible", 999)
    ded_b = policy_b.get("dimensions", {}).get("deductible_and_waiting", {}).get("medical_deductible", 999)
    if ded_a == 0 and ded_b > 0:
        recommendations.append(("👨‍💻", "如果你是 **办公室上班族** → 选保单A,0免赔,日常小意外最实用"))
    elif ded_b == 0 and ded_a > 0:
        recommendations.append(("👨‍💻", "如果你是 **办公室上班族** → 选保单B,0免赔,日常小意外最实用"))

    traffic_a = policy_a.get("dimensions", {}).get("coverage_scope", {}).get("traffic_extra", {})
    traffic_b = policy_b.get("dimensions", {}).get("coverage_scope", {}).get("traffic_extra", {})
    a_traffic_max = max((v.get("amount") or 0 for v in traffic_a.values() if isinstance(v, dict)), default=0)
    b_traffic_max

Undeclared Tool Scope

Medium
Category
MCP Least Privilege
Confidence
90% confidence
Finding

The skill describes file-writing behavior (saving an HTML report to the user's desktop) but does not declare any tool scope or permissions boundary. This creates an authorization and transparency gap: a host may permit broader file operations than users expect, and reviewers cannot verify that filesystem access is intentionally constrained.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
83% confidence
Finding

文件标题、描述、流程、示例和注意事项均以中文固定呈现,并在 L131 要求“所有术语需提供白话解释”,但没有说明是否支持其他语言或允许用户选择输出语言。对于通用技能,这种隐含的单一语言约束可能构成语言/locale 策略问题。

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
88% confidence
Finding

The skill proposes real-time searches across external sites for claim reputation but does not clearly disclose that insurer/product-related queries will be sent to third-party services. Even if the query is not highly sensitive, external transmission can leak user intent, business interest, or document-derived entities and may violate privacy expectations or enterprise network policy.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

Saving an HTML report to the desktop and automatically opening it without an explicit prompt is risky because it performs local side effects on the user's system and may expose sensitive policy data in a persistent, easily discoverable location. Auto-opening generated HTML also increases exposure to unsafe rendering behaviors if any untrusted content is embedded in the report.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
96% confidence
Finding

The HTML document explicitly sets lang="zh-CN", and the visible interface text throughout the template is only in Simplified Chinese. This indicates a fixed language/locale experience without any user opt-in or documented justification, which matches the policy-violation category for forced language or locale.

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 title and all operational guidance are written exclusively in Chinese, with no indication that other languages are supported or that Chinese is a region-specific requirement. Under the policy rule for language or locale constraints, this is a natural-language policy issue because the skill appears to require a specific language without user opt-in.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
91% confidence
Finding

The skill explicitly directs real-time searches across social media, complaint platforms, and regulator sites to assess claim reputation, but the configuration shown does not require a user-facing disclosure or consent flow before external data access occurs. In a policy-analysis workflow that may involve insurer/product names derived from uploaded documents, this can surprise users, expand data exposure to third parties, and create privacy/compliance risk even if only partial identifiers are queried.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
98% confidence
Finding

The schema title, field descriptions, and terminology mapping are entirely written in Chinese, and the file defines output content such as explanatory text and notes in Chinese only. Because the file provides no opt-in, alternative locale, or stated region-specific justification, it appears to impose a specific language/locale policy on users.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
91% confidence
Finding

This code file contains user-facing natural-language descriptions and output strings exclusively in Chinese, including the module description and CLI help text. Under the policy rule for language/locale, forcing a specific language without user opt-in can be a natural-language policy violation when no locale choice or justification is provided.

Content

No source excerpt is available for this finding.