Back to skill

Security audit

MedRates.fyi

Security checks for vulnerabilities and agentic risk

Overview

This is a straightforward MedRates API guide, but medical-cost searches may send procedure, insurance, and location details to MedRates.

Before installing, be aware that procedure searches, insurance details, and location coordinates may be sent to MedRates. Prefer CPT or HCPCS codes, ZIP/city-level location, and only the insurance fields needed for the quote; avoid including names, account identifiers, addresses, or unrelated medical history.

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

other

Warning
Location
SKILL.md:31
Finding

Sensitive Healthcare Context Transmitted to a Third-Party API Without Privacy Safeguards

Content
View full analysis

Vulnerability Details

File Location: SKILL.md, lines 31–34, 68–70, 93–94, and 150
Vulnerability Type: Sensitive Data Disclosure
Risk Level: Medium

Evidence

bash
curl -X POST https://data.medrates.fyi/api/search/nlp/grouped \
  -H "Content-Type: application/json" \
  -d '{"query": "brain MRI near San Jose with Blue Cross PPO"}'
markdown
| `lat` | float | no | Patient latitude (improves geo-sorting) |
| `lng` | float | no | Patient longitude |
| `radius_miles` | float | no | Geo cutoff in miles |
markdown
| `lat` | float | yes | Patient latitude |
| `lng` | float | yes | Patient longitude |
markdown
Use `POST /api/search/nlp/grouped` with their query. Include `lat`/`lng` if you know their location.

Technical Analysis

The documented workflow instructs an AI agent to transmit potentially sensitive healthcare intent to the external service data.medrates.fyi. A request can combine a medical procedure or condition-related query with precise coordinates, an insurance provider, and a plan type or name.

This combination can be identifying or enable sensitive profiling. Exact latitude and longitude may correspond to a residence or workplace, while procedure searches reveal healthcare interests. The Skill does not require the agent to obtain informed approval before disclosure, explain which data will be sent, reduce location precision, remove identifiers, or avoid forwarding unrelated user context.

No evidence establishes malicious behavior by the external service. The issue is the absence of privacy-preserving controls around third-party disclosure.

Attack Path

  1. A user asks the agent to research the price of a medical procedure.
  2. The user supplies or previously disclosed a location, insurer, or plan.
  3. Following SKILL.md, the agent places the procedure and associated details into a request to https://data.medrates.fyi.
  4. The request t ...[truncated 696 chars]
Remediation
View remediation

Remediation Suggestions

  1. Require explicit user approval before transmitting healthcare-related information to the external API.
  2. Clearly disclose the destination, purpose, and exact fields that will be transmitted.
  3. Default to city, ZIP code, or coarsened coordinates instead of exact latitude and longitude.
  4. Remove names, addresses, account identifiers, and unrelated conversational context before constructing requests.
  5. Send insurer and plan information only when necessary for the requested comparison.
  6. Add instructions prohibiting the transmission of protected health information or uniquely identifying medical details.
  7. Document or link to the service's privacy, retention, deletion, and logging policies.
  8. Provide a privacy-preserving mode that uses billing codes and coarse geographic information without natural-language medical context.
Vulnerability Patterns
  • Data ExfiltrationExternal Transmission, Env Variable Harvesting, File System Enumeration
  • Privilege EscalationExcessive Permissions, Sudo/Root Execution, Credential Access
  • Prompt InjectionInstruction Override, Hidden Instructions, Exfiltration Commands
  • Supply ChainUnpinned Dependencies, External Script Fetching, Obfuscated Code
  • Excessive AgencyUnrestricted Tool Access, Autonomous Decision Making, Scope Creep
Findings (8)

Credential Access

High
Category
Privilege Escalation
Confidence
70% confidence
Finding

Code accesses credential files (SSH keys, AWS credentials, etc.). This could indicate credential theft attempts.

Content

Scanner excerpt · SKILL.md (reported line 176)May include surrounding context.

md
### Authenticated Access (Higher Limits)

If you hit rate limits, your human should request an API access token by emailing **hello@medrates.fyi** or visiting [medrates.fyi/api-access](https://medrates.fyi/api-access).

Once you have a JWT token, include it in requests:

Missing User Warnings

Medium
Category
Not specified by scanner
Confidence
94% confidence
Finding

The skill clearly sends user-provided medical procedure queries, insurance details, and potentially precise location data to an external third-party API, but the description does not prominently warn about that data flow. Because medical cost queries can reveal sensitive health interests and location can increase identifiability, users may disclose regulated or highly private information without informed consent.

Content

No source excerpt is available for this finding.

External Transmission

Medium
Category
Data Exfiltration
Confidence
92% confidence
Finding

This endpoint transmits free-text medical cost queries to an external service, and those queries may include sensitive medical procedures, insurance carrier, and inferred location. Even though this is the stated function of the skill, the risk is real because NLP-style prompts tend to encourage users to provide more personal health context than necessary.

Content

Scanner excerpt · SKILL.md (reported line 32)May include surrounding context.

The fastest way to answer "how much does X cost?" is the NLP search:

bash
curl -X POST https://data.medrates.fyi/api/search/nlp/grouped \
  -H "Content-Type: application/json" \
  -d '{"query": "brain MRI near San Jose with Blue Cross PPO"}'

External Transmission

Medium
Category
Data Exfiltration
Confidence
92% confidence
Finding

This endpoint transmits free-text medical cost queries to an external service, and those queries may include sensitive medical procedures, insurance carrier, and inferred location. Even though this is the stated function of the skill, the risk is real because NLP-style prompts tend to encourage users to provide more personal health context than necessary.

Content

Scanner excerpt · SKILL.md (reported line 32)May include surrounding context.

The fastest way to answer "how much does X cost?" is the NLP search:

bash
curl -X POST https://data.medrates.fyi/api/search/nlp/grouped \
  -H "Content-Type: application/json" \
  -d '{"query": "brain MRI near San Jose with Blue Cross PPO"}'

External Transmission

Medium
Category
Data Exfiltration
Confidence
90% confidence
Finding

The price-quote example sends CPT codes together with exact latitude/longitude and payer information to an external API. Combining treatment codes, insurance details, and precise geolocation can expose sensitive health-related interests and make users more identifiable than necessary.

Content

Scanner excerpt · SKILL.md (reported line 40)May include surrounding context.

For exact code lookups with multi-hospital price comparison:

bash
curl "https://data.medrates.fyi/api/price-quote?codes=70551,70552&lat=37.33&lng=-121.89&payer=Blue+Cross&plan_type=PPO"

Coverage Limitation

External Transmission

Medium
Category
Data Exfiltration
Confidence
84% confidence
Finding

Deep-linking directly to a procedure-specific page on a third-party site can expose the user's condition or procedure interest through browser navigation, logs, referrers, or copied links. The impact is lower than API submission, but it still externalizes potentially sensitive medical-interest data.

Content

Scanner excerpt · SKILL.md (reported line 143)May include surrounding context.

md
When presenting results to users, link to the web UI for visual exploration:

- **Procedure page:** `https://data.medrates.fyi/code/{CODE_TYPE}/{CODE}` (e.g. `/code/CPT/70551`)
- **Hospital search:** `https://data.medrates.fyi/search?q={QUERY}`
- **All hospitals:** `https://data.medrates.fyi/hospitals`

External Transmission

Medium
Category
Data Exfiltration
Confidence
86% confidence
Finding

The hospital search deep link embeds the user's query into a third-party URL, which may include medical terms, payer names, or location details. That exposes potentially sensitive search intent to the external site and to intermediary browser history, logs, and analytics.

Content

Scanner excerpt · SKILL.md (reported line 144)May include surrounding context.

md
When presenting results to users, link to the web UI for visual exploration:

- **Procedure page:** `https://data.medrates.fyi/code/{CODE_TYPE}/{CODE}` (e.g. `/code/CPT/70551`)
- **Hospital search:** `https://data.medrates.fyi/search?q={QUERY}`
- **All hospitals:** `https://data.medrates.fyi/hospitals`

## Workflow Recommendations

External Transmission

Medium
Category
Data Exfiltration
Confidence
50% confidence
Finding

Data is being sent to an external URL. This could be legitimate telemetry or data exfiltration. Manual review is recommended.

Content

Scanner excerpt · SKILL.md (reported line 145)May include surrounding context.

md
- **Procedure page:** `https://data.medrates.fyi/code/{CODE_TYPE}/{CODE}` (e.g. `/code/CPT/70551`)
- **Hospital search:** `https://data.medrates.fyi/search?q={QUERY}`
- **All hospitals:** `https://data.medrates.fyi/hospitals`

## Workflow Recommendations

Static analysis

No suspicious patterns detected.