CVE-2026-32112: ha-mcp XSS Vulnerability in OAuth Consent Form

ha-mcp Updated 14 Mar 2026

Summary

12/03/2026
Yes i
Moderate
6.8

CVE-2026-32112: ha-mcp has XSS via Unescaped HTML in OAuth Consent Form. Affects ha-mcp versions < 7.0.0. Fixed in 7.0.0. How to fix ↓

Free scan

Check if this vulnerability affects your application

Upload a manifest or SBOM and we'll show whether you're affected, plus every other risky package in the same scan.

Check my app free

No signup required · Results in about 60 seconds

Upload your dependency manifest or SBOM

Drag & drop your file here or

Java Javascript PHP Python Go Rust Ruby Dart C/C++ Elixir CycloneDX SPDX

Upload a supported dependency manifest or SBOM. No installation or source-code access required.

See supported files and SBOM formats
SBOM sbom.json · bom.json · bom.xml · *.spdx.json · *.cdx.json · *.cdx.xml
Java pom.xml · gradle.lockfile · buildscript-gradle.lockfile
Javascript package-lock.json · yarn.lock · pnpm-lock.yaml
PHP composer.lock
Python poetry.lock · requirements.txt · Pipfile.lock
Go go.mod
Rust Cargo.lock
Ruby Gemfile.lock
Dart pubspec.lock
C/C++ conan.lock
Elixir mix.lock
Enter your work email to receive your report link.

Verify your email to view the full report and start 30 days of continuous monitoring. No credit card required.

Sponsored MarkAI Find prospects already talking about the problem you solve AI watches the communities your customers use to find qualified prospects, then alerts you when a conversation is worth joining. See MarkAI

Background

ha-mcp is a Python package that facilitates OAuth authentication for various applications. It is designed to streamline the authorization process by allowing users to register and manage OAuth clients. The package includes a beta mode, 'ha-mcp-oauth', which is not part of the standard setup and requires explicit configuration. This mode is particularly vulnerable due to its handling of user-controlled parameters in the OAuth consent form.

Vulnerability Detail

The vulnerability arises from the use of unescaped HTML rendering in the OAuth consent form, specifically through Python f-strings in the 'consent_form.py' file. This allows an attacker to inject malicious JavaScript into the consent form by manipulating parameters such as 'client_name' and 'client_id'. If a server operator visits a crafted authorization URL, the injected script could execute in their browser, potentially exfiltrating sensitive information like the Home Assistant Long-Lived Access Token. The vulnerability is classified as a Cross-Site Scripting (XSS) issue (CWE-79) and primarily affects users running the beta OAuth mode.

How To Fix

Minimum fixed version

7.0.0

This is the first release that contains the fix.

pip install --upgrade "ha-mcp==7.0.0"

Tip — Not sure which version your app runs? Vulert can match this fix to it. Scan free →

Workaround

As a temporary workaround, avoid using the beta OAuth mode ('ha-mcp-oauth') until the package is updated. Ensure that only trusted clients are registered and monitor access to the OAuth endpoint closely.

Conclusion

CVE-2026-32112 is a significant XSS vulnerability in the ha-mcp package's OAuth consent form, primarily affecting users of the beta OAuth mode. Immediate action is required to upgrade the package to mitigate potential risks associated with this vulnerability.

See every vulnerability recorded for ha-mcp →

Share this vulnerability

FAQ

CVE-2026-32112 is a vulnerability in the ha-mcp package that allows for Cross-Site Scripting (XSS) attacks through unescaped HTML in the OAuth consent form.

Only users running the beta OAuth mode ('ha-mcp-oauth') are affected, as this mode requires explicit configuration and is not part of the standard setup.

You can use Vulert's playground at Vulert Scanner to check if your application is affected by this vulnerability without needing to sign up.

If exploited, an attacker could execute JavaScript in the server operator's browser, potentially exfiltrating sensitive data such as access tokens.

Upgrade to version 7.0.0 or later of the ha-mcp package. Additionally, avoid using the beta OAuth mode until the update is applied.

Related vulnerabilities

Recent vulnerabilities recorded for ha-mcp.

How To Fix

Minimum fixed version

7.0.0

This is the first release that contains the fix.

pip install --upgrade "ha-mcp==7.0.0"

Tip — Not sure which version your app runs? Vulert can match this fix to it. Scan free →

Subscribe to Vulert on Telegram
Daily digest of new CVEs, critical and high severity, affected packages and fixes — plus a weekly roundup.
Join the channel →
Help improve this record
Report an issue or send feedback