Back to skill

Security audit

ecg-diagnosis

Security checks for vulnerabilities and agentic risk

Overview

This ECG skill handles sensitive medical images but under-discloses third-party upload, browser persistence, and path-safety risks, so users should review it carefully before installing.

Install only if you are comfortable sending ECG images, patient names in filenames, age, and sex to the hard-coded third-party website. Prefer not to use this with real patient data unless the publisher adds explicit consent, domain and retention disclosures, strict path and filename validation, non-persistent browser sessions, and a shell-safe invocation method.

Vulnerability Patterns
  • Unauthorized Access and Privilege EscalationObtains permissions beyond the task's legitimate needs
  • 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 (4)

other

Error
Location
scripts/ecg_diagnosis.py:84
Finding

Undisclosed Transmission of Personally Identifiable Medical Data

Content
View full analysis
Remediation
View remediation

T05 · Unauthorized Access and Privilege Escalation

Error
Location
scripts/ecg_diagnosis.py:74
Finding

Path Traversal Allows Arbitrary Readable Local Files to Be Uploaded

Content
View full analysis
Remediation
View remediation

T09 · Insecure Skill Coding Practices

Error
Location
SKILL.md:26
Finding

Shell Command Construction with User-Controlled Paths and Filenames

Content
View full analysis
Remediation
View remediation

T09 · Insecure Skill Coding Practices

Warning
Location
scripts/ecg_diagnosis.py:55
Finding

Persistent Browser Profile Stores Session Data in the User-Selected Medical Folder

Content
View full analysis
Remediation
View remediation
Vulnerability Patterns
  • 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
  • Behavioral ASTexec() Call, eval() Call, Dynamic Import
  • MCP Tool PoisoningHidden Instructions, Unicode Deception, Parameter Description Injection
Findings (10)

Tp4

High
Category
MCP Tool Poisoning
Confidence
96% confidence
Finding

The skill advertises a local ECG-processing workflow with filename auditing, but the static analysis indicates materially different behavior: browser automation, third-party web access, file upload, scraping, and Excel export. That mismatch is dangerous because users may provide sensitive medical images and PII under the belief data stays local, while the actual implementation could exfiltrate ECG images and derived diagnoses to an external service without informed consent.

Content

No source excerpt is available for this finding.

Description-Behavior Mismatch

High
Category
Not specified by scanner
Confidence
98% confidence
Finding

The skill metadata claims a local ECG assistant, but the code automates a browser to upload ECG images and derived patient metadata to an external website for diagnosis. This is dangerous because sensitive medical data leaves the local environment without clear disclosure or consent, creating confidentiality, compliance, and third-party retention risks.

Content

No source excerpt is available for this finding.

Missing User Warnings

High
Category
Not specified by scanner
Confidence
99% confidence
Finding

The workflow uploads ECG images plus age and gender to a third-party website without any explicit warning, privacy notice, or confirmation step. Because ECG data is highly sensitive health information, undisclosed transmission materially increases privacy, regulatory, and breach exposure.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
90% confidence
Finding

The filename audit requires embedding age, sex, and name in the image filename, which is personally identifiable and health-adjacent metadata, yet the skill provides no privacy warning or minimization guidance. In this context, collecting and parsing PII from filenames is especially dangerous because those names may be logged, uploaded, stored in shell history, or transmitted to external services alongside ECG images.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
92% confidence
Finding

The skill mandates execution of a local Python script but does not present a clear user-facing warning or consent step before subprocess execution. This is risky because running local scripts can access files, network resources, browsers, and local environment state, especially concerning here given the medical-data context and the static indication of hidden remote interactions.

Content

No source excerpt is available for this finding.

Vague Triggers

Medium
Category
Not specified by scanner
Confidence
89% confidence
Finding

The trigger logic gives a single example request, '帮我处理文件夹 D:\ECG 中的图', but does not specify whether semantically similar everyday requests should also activate the skill or what requests should not. This lack of clear boundaries can cause ambiguous invocation behavior in a manifest-style markdown skill description.

Content

No source excerpt is available for this finding.

Context-Inappropriate Capability

Medium
Category
Not specified by scanner
Confidence
89% confidence
Finding

The code imports and applies browser stealth/anti-automation evasion while interacting with a medical diagnosis website. Evasion mechanisms are unnecessary for a normal end-user assistant and increase suspicion because they are commonly used to bypass bot detection, hide automation, and frustrate oversight by the remote service.

Content

No source excerpt is available for this finding.

Description-Behavior Mismatch

Medium
Category
Not specified by scanner
Confidence
94% confidence
Finding

The filename parser performs only minimal checks and silently falls back to default age/gender values when parsing fails, despite the skill description claiming enhanced filename auditing. In a medical workflow, this can cause incorrect patient attributes to be submitted for diagnosis, producing unsafe or misleading results without any visible error.

Content

No source excerpt is available for this finding.

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
90% confidence
Finding

The code creates a persistent browser profile directory on disk and reuses it across sessions without disclosure. Persistent profiles can retain cookies, session tokens, browsing history, and potentially sensitive interactions, increasing the chance of unintended credential reuse or local data exposure.

Content

No source excerpt is available for this finding.

Natural-Language Policy Violations

Low
Category
Not specified by scanner
Confidence
95% confidence
Finding

The instructions require a fixed Chinese progress announcement to be shown to the user, with no option to adapt to the user's preferred language or locale. This is a natural-language policy issue because it forces a specific language rather than offering choice or documenting a justified locale restriction.

Content

No source excerpt is available for this finding.