Back to skill

Security audit

分还是不分·Mean Girl关系诊断

Security checks for vulnerabilities and agentic risk

Overview

This skill is mostly a disclosed breakup-advice assistant, but it handles intimate chats and creates/sends rendered files using unsafe local-server and storage steps.

Review this skill before installing. It may analyze private relationship chats and produce a shareable diagnostic image, but its rendering instructions can leave sensitive content in /tmp, expose a local HTTP server, and store/send the generated image without clear cleanup or consent controls.

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/render.md:20
Finding

Temporary Directory Exposed Through an Unrestricted HTTP Server

Content
View full analysis

Vulnerability Details

File Location: scripts/render.md, lines 20–23
Vulnerability Type: Unsafe temporary-file serving and excessive network exposure
Risk Level: Medium

Vulnerable Code

bash
cd /tmp && python3 -m http.server 18800 &

Technical Analysis

The rendering instructions start Python's built-in HTTP server from the shared /tmp directory. By default, python3 -m http.server listens on all available network interfaces rather than only the loopback interface. It also provides directory listings and serves every readable file beneath its working directory.

The generated /tmp/breakup_card.html may contain sensitive relationship details, quoted conversations, or content extracted from private chat screenshots. Serving all of /tmp unnecessarily exposes both that report and unrelated temporary files belonging to other processes or users.

The server is launched in the background and the documented workflow does not retain its process ID or stop it after the screenshot is generated. Consequently, the exposure can continue after rendering is complete. Repeated executions can also leave unmanaged processes or encounter predictable-port conflicts.

Attack Path

  1. A user submits sensitive relationship information or private chat records to the Skill.
  2. The Skill incorporates that information into /tmp/breakup_card.html.
  3. The rendering workflow changes its working directory to /tmp.
  4. It launches an HTTP server on the predictable TCP port 18800, listening on all interfaces by default.
  5. An attacker with network access to the host connects to http://HOST:18800/.
  6. The attacker uses the directory listing to identify and download breakup_card.html or other readable temporary files.
  7. Because the server is not terminated by the workflow, the attacker may retain access after the rendering operation has finished.

This exploitation path depends on port 18800 being reachable from an attacker-controlled network ...[truncated 859 chars]

Remediation
View remediation

Remediation Suggestions

  1. Avoid starting an HTTP server. Load the generated document directly through a local file URL:

    python
    from pathlib import Path
    page.goto(Path("/tmp/breakup_card.html").as_uri(), wait_until="load")
    
  2. Use a private temporary directory. Create a unique directory with owner-only permissions rather than placing sensitive output directly in shared /tmp:

    bash
    workdir="$(mktemp -d)"
    chmod 700 "$workdir"
    
  3. If HTTP is unavoidable, bind only to loopback and serve only the private rendering directory:

    bash
    cd "$workdir"
    python3 -m http.server 18800 --bind 127.0.0.1 &
    server_pid=$!
    
  4. Terminate the server deterministically. Record the process ID and install cleanup handling before rendering:

    bash
    trap 'kill "$server_pid" 2>/dev/null; rm -rf "$workdir"' EXIT
    
  5. Prefer an ephemeral port instead of the fixed port 18800, and pass the selected local URL directly to Playwright.

  6. Remove sensitive artifacts after delivery, including the HTML, screenshot, and copied media file when retention is not explicitly required.

  7. Apply restrictive permissions such as 0600 to generated HTML and image files, and ensure no untrusted content can introduce external resource requests during rendering.

Vulnerability Patterns
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Excessive AgencyUnrestricted Tool Access, Autonomous Decision Making, Scope Creep
  • Trigger AbuseOverly Broad Trigger, Shadow Command Trigger, Keyword Baiting Trigger
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
Findings (9)

Vague Triggers

High
Category
Not specified by scanner
Confidence
97% confidence
Finding

The trigger criteria are intentionally expansive and allow activation on vague, ordinary emotional venting or any pasted relationship chat logs without clear user consent boundaries or specificity checks. In a sensitive domain like relationship advice, this can cause the system to intervene too readily, infer intimate context from private communications, and deliver high-stakes advice when the user may only be expressing feelings rather than explicitly requesting analysis.

Content

No source excerpt is available for this finding.

Vague Triggers

High
Category
Not specified by scanner
Confidence
96% confidence
Finding

The trigger conditions are so broad that ordinary relationship complaints or any pasted two-person conversation can invoke the skill, which increases the chance of unintended activation on sensitive emotional or interpersonal content. In context, this is more dangerous because the skill gives forceful breakup-oriented analysis in a harsh persona, so accidental routing can materially influence vulnerable users and expose private communications to unnecessary processing.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Medium
Category
Not specified by scanner
Confidence
85% confidence
Finding

The description and all prescribed outputs are written as a fixed Chinese 'Mean Girl 闺蜜' experience, with no indication that users may choose another language or locale. Under the stated policy, forcing a specific language without user opt-in is a natural-language policy concern unless the locale restriction is explicitly justified.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
94% confidence
Finding

The skill instructs the agent to ingest screenshot or pasted chat records and analyze them without warning users that the content may contain sensitive personal data about themselves or third parties. This creates a privacy risk because intimate messages, identifiers, and third-party statements may be processed unexpectedly, especially in a relationship-advice context where users often share highly sensitive content impulsively.

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 hard-requires a Chinese-only 'Mean Girl' persona and explicitly instructs the agent to use sharp, insulting language without any user opt-in. In a sensitive breakup/relationship context, this can cause avoidable emotional harm, alienate users who did not request that tone, and reduce the model's ability to adapt to safety-sensitive situations such as distress, coercion, or abuse disclosures.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
94% confidence
Finding

The instructions direct the agent to write files under /tmp and launch a local HTTP server without any user-facing disclosure. In the context of intimate relationship analysis, undisclosed filesystem and service operations are risky because they process sensitive personal content in ways the user would not reasonably expect.

Content

No source excerpt is available for this finding.

Context-Inappropriate Capability

Medium
Category
Not specified by scanner
Confidence
95% confidence
Finding

The skill instructs the agent to start a local HTTP server and drive a browser via Playwright even though the stated purpose is relationship analysis. That expands the runtime attack surface, introduces unnecessary code execution and network-listening behavior, and could expose sensitive user-derived content through local services or browser processing without a clear need.

Content

No source excerpt is available for this finding.

Context-Inappropriate Capability

Medium
Category
Not specified by scanner
Confidence
96% confidence
Finding

Copying generated content into a persistent platform media directory and sending it through a messaging action exceeds the skill's described analysis-only role. Because relationship content is highly sensitive, this creates a real risk of unintended retention and transmission of private user data beyond the immediate analysis flow.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
97% confidence
Finding

The skill copies generated media into a persistent application directory and sends it, but does not disclose either storage or transmission to the user. Since the skill is triggered by chats, screenshots, and relationship narratives, this could silently retain and share highly sensitive personal data, making the context more dangerous than a generic rendering task.

Content

No source excerpt is available for this finding.