Description
ha-mcp is a Home Assistant MCP Server. Prior to 7.0.0, the ha-mcp OAuth consent form renders user-controlled parameters via Python f-strings with no HTML escaping. An attacker who can reach the OAuth endpoint and convince the server operator to follow a crafted authorization URL could execute JavaScript in the operator's browser. This affects only users running the beta OAuth mode (ha-mcp-oauth), which is not part of the standard setup and requires explicit configuration. This vulnerability is fixed in 7.0.0.
Published: 2026-03-11
Score: 6.8 Medium
EPSS: < 1% Very Low
KEV: No
Impact: Cross‑Site Scripting via unescaped HTML in OAuth consent form
Action: Apply Patch
AI Analysis

Impact

This vulnerability exists because the ha‑mcp OAuth consent form renders user‑controlled query parameters directly into the HTML output using Python f‑strings without any escaping. If an attacker can reach the OAuth endpoint and persuade the server operator to click a crafted authorization URL, arbitrary JavaScript will run in the operator’s browser. The exposed weakness is a classic XSS flaw (CWE‑79) that compromises the confidentiality, integrity, and availability of the operator’s session and can be used for credential theft or persistence. The impact is limited to the browser context of the operator but can lead to significant damage if the operator has administrative access to the Home Assistant instance.

Affected Systems

Vendors: homeassistant‑ai; Product: ha‑mcp Server. Only the beta OAuth mode (ha‑mcp‑oauth) is affected, which is not part of the default configuration and requires explicit operator setup. All releases prior to 7.0.0 of ha‑mcp contain the flaw; the vulnerability is fixed in version 7.0.0.

Risk and Exploitability

The CVSS v3 base score is 6.8, indicating a medium‑to‑high severity. The EPSS score is below 1%, suggesting a low probability of exploitation in the wild. The issue is not listed in the CISA KEV catalog. Attackers would need network or Web access to the OAuth endpoint and the ability to influence the server operator to visit a crafted URL. The flaw is publicly documented and remains unaddressed until the operator updates the software.

Generated by OpenCVE AI on March 17, 2026 at 17:05 UTC.

Remediation

No vendor fix or workaround currently provided.

OpenCVE Recommended Actions

  • Upgrade ha‑mcp to version 7.0.0 or later

Generated by OpenCVE AI on March 17, 2026 at 17:05 UTC.

Tracking

Sign in to view the affected projects.

Advisories
Source ID Title
Github GHSA Github GHSA GHSA-pf93-j98v-25pv ha-mcp has XSS via Unescaped HTML in OAuth Consent Form
History

Tue, 17 Mar 2026 15:45:00 +0000

Type Values Removed Values Added
First Time appeared Homeassistant-ai home Assistant Mcp Server
CPEs cpe:2.3:a:homeassistant-ai:home_assistant_mcp_server:*:*:*:*:*:*:*:*
Vendors & Products Homeassistant-ai home Assistant Mcp Server

Thu, 12 Mar 2026 14:15:00 +0000

Type Values Removed Values Added
Metrics ssvc

{'options': {'Automatable': 'no', 'Exploitation': 'none', 'Technical Impact': 'total'}, 'version': '2.0.3'}


Thu, 12 Mar 2026 10:15:00 +0000

Type Values Removed Values Added
First Time appeared Homeassistant-ai
Homeassistant-ai ha-mcp
Vendors & Products Homeassistant-ai
Homeassistant-ai ha-mcp

Wed, 11 Mar 2026 21:00:00 +0000

Type Values Removed Values Added
Description ha-mcp is a Home Assistant MCP Server. Prior to 7.0.0, the ha-mcp OAuth consent form renders user-controlled parameters via Python f-strings with no HTML escaping. An attacker who can reach the OAuth endpoint and convince the server operator to follow a crafted authorization URL could execute JavaScript in the operator's browser. This affects only users running the beta OAuth mode (ha-mcp-oauth), which is not part of the standard setup and requires explicit configuration. This vulnerability is fixed in 7.0.0.
Title ha-mcp has XSS via Unescaped HTML in OAuth Consent Form
Weaknesses CWE-79
References
Metrics cvssV3_1

{'score': 6.8, 'vector': 'CVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:U/C:H/I:H/A:N'}


Subscriptions

Homeassistant-ai Ha-mcp Home Assistant Mcp Server
cve-icon MITRE

Status: PUBLISHED

Assigner: GitHub_M

Published:

Updated: 2026-03-12T14:05:47.508Z

Reserved: 2026-03-10T22:02:38.855Z

Link: CVE-2026-32112

cve-icon Vulnrichment

Updated: 2026-03-12T14:05:32.007Z

cve-icon NVD

Status : Analyzed

Published: 2026-03-11T21:16:17.450

Modified: 2026-03-17T15:39:07.100

Link: CVE-2026-32112

cve-icon Redhat

No data.

cve-icon OpenCVE Enrichment

Updated: 2026-03-20T15:37:05Z

Weaknesses