AirGradient Forum

Heimautomatisierung: ESPHome-Lücke erlaubt volle Kompromittierung

Please check out this (German) article about a security leak of ESP32 and check if your product may have it:

heise de
/news/
Heimautomatisierung-ESPHome-Luecke-erlaubt-volle-Kompromittierung-10628487
html

Here the text from heise:

Heimautomatisierung: ESPHome-Lücke erlaubt volle Kompromittierung

Eine Schwachstelle in ESPHome ermöglicht Angreifern unter anderem eigene Firmware zu flashen. Aktualisierte Software korrigiert das.

02.09.2025, 09:01 Uhr
Lesezeit: 2 Min.
Security
Von Dirk Knop

In der ESP-IDF-Plattform der ESPHome-Firmwarebasis führt eine nun entdeckte Sicherheitslücke dazu, dass Angreifer eine Authentifizierung umgehen können. Das ermöglicht ihnen sogar, eigene Firmware auf verwundbare Controller zu verfrachten.

ESPHome ist ein Entwicklungssystem, mit dem sich Mikrocontroller einfach in Heimautomatisierungssysteme einbinden lassen. Entwickler erstellen Firmwares auf dieser Basis etwa für Controllerboards mit ESP32-Mikroprozessoren und programmieren eigene Funktionen dazu. ESPHome liefert nützliche Funktionen wie Over-the-Air-Updates (OTA) gleich mit, sodass Programmierer sich nicht weiter damit auseinandersetzen müssen.

Ein neuer Schwachstelleneintrag vom Montag dieser Woche erörtert die Sicherheitslücke in der Firmware. Die ESPHome-Entwickler führen darin aus, dass die “web_server”-Authentifizierungsprüfung der ESP-IDF-Plattform fälschlicherweise bestanden wird, wenn der clientseitig übergebene, Base64-kodierte Autorisierungswert leer ist oder lediglich einen Teil des korrekten Werts enthält. “Das erlaubt Zugriff auf die ‘web_server’-Funktionen (einschließlich OTA, wenn es aktiviert ist), ohne jedwede Information über den korrekten Usernamen oder Passwort zu haben”, erklären die Programmierer (CVE-2025-57808 / noch kein EUVD, CVSS 8.1, Risiko “hoch”).
Unklarer Status zu verwundbaren ESPHome-Versionen

Der Fehler wurde dem Schwachstelleneintrag zufolge mit ESPHome 2025.8.0 eingeführt – jedoch will der Schwachstellenmelder das Problem auch mit ESPHome 2025.7.5 verifiziert haben. Auf Github geht der Meldende noch etwas tiefer in die Details des Sicherheitsproblems. ESPHome 2025.8.1 oder neuer dichtet das Sicherheitsleck hingegen ab. Aktuell ist das Release ESPHome 2025.8.2 vom Wochenende.

Wer ESPHome-basierte Firmwares auf seinen Internet-of-Things-Geräten einsetzt, sollte die Aktualisierung auf die jüngste Firmware-Basis vornehmen. Aufgrund der Widersprüche zu den verwundbaren Versionen sollten auch ESPHome-Versionen vor 2025.8.0 auf den neuen Stand gebracht werden.

Mitte vergangenen Jahres hatten Updates für Home Assistant dafür gesorgt, dass Over-the-Air-Updates mit älteren ESPHome-Projekten lediglich zu Fehlermeldungen führten. Ursache war, dass seitdem der Parameter “platform” für OTA-Aktualisierungen übergeben werden muss, der in älteren Projekten schlicht nicht angegeben war.

Home Automation: ESPHome Vulnerability Allows Complete Compromise

A vulnerability in ESPHome allows attackers to, among other things, flash their own firmware. Updated software corrects this.

September 2, 2025, 9:01 a.m.
Reading time: 2 min.
Security
By Dirk Knop

A recently discovered security vulnerability in the ESP-IDF platform of the ESPHome firmware base allows attackers to bypass authentication. This even allows them to deploy their own firmware to vulnerable controllers.

ESPHome is a development system that makes it easy to integrate microcontrollers into home automation systems. Developers create firmware based on this platform, for example, for controller boards with ESP32 microprocessors and program their own functions. ESPHome provides useful features such as over-the-air (OTA) updates, so programmers don’t have to worry about them.

A new vulnerability entry from Monday of this week discusses the firmware vulnerability. The ESPHome developers explain that the ESP-IDF platform’s “web_server” authentication check is incorrectly passed if the client-side, Base64-encoded authorization value is empty or contains only part of the correct value. “This allows access to the ‘web_server’ functions (including OTA, if enabled) without any information about the correct username or password,” the programmers explain (CVE-2025-57808 / no EUVD yet, CVSS 8.1, risk “high”).
Unclear status of vulnerable ESPHome versions

According to the vulnerability entry, the bug was introduced with ESPHome 2025.8.0 – however, the vulnerability reporter claims to have also verified the issue with ESPHome 2025.7.5. On Github, the reporter delves into the details of the security issue in more detail. ESPHome 2025.8.1 or newer, however, seals the security vulnerability. The current release is ESPHome 2025.8.2, released this weekend.

Anyone using ESPHome-based firmware on their Internet of Things devices should update to the latest firmware. Due to the inconsistencies with the vulnerable versions, ESPHome versions prior to 2025.8.0 should also be updated.

In the middle of last year, updates to Home Assistant caused over-the-air updates with older ESPHome projects to simply result in error messages. The reason was that since then, the “platform” parameter must be passed for OTA updates, which was simply not specified in older projects.

Thank you. This is the first I’ve seen about this so far.

The official AirGradient firmware is based on Arduino and doesn’t sound like it is vulnerable.
There is ESPHome based options out there and I’ll make sure to create updated binary files from the patched version in case someone downloads it directly.

For other users of ESPHome, they will have to update their install and send updated firmware to their devices, which I do on a regular basis for all of my devices.

1 Like

Thank you for your response!

I thought about your motto about “your data is yours” and thought how that CVE-2025-57808 could influence that in a bad way.

It’s good to hear you got it covered and also that most (Arduino) based users are safe!

Updated the pre-compiled binaries in my repository
Merge pull request #167 from MallocArray/2025.8.3_bin · MallocArray/airgradient_esphome@1c501ad

1 Like

Fantastic. Thanks again.

How will affected users know that there is a good reason to update?

I update all of my ESPHome devices on a monthly basis and others may

I doubt many would come to my GitHub page just to see if there are any updates, so I don’t expect that to be a high visibility location.

If I read it right, the issue is with web_server which isn’t enabled by default. I do have captive_portal enabled but not sure if it also loads components from the affected code.

Well, I just saw the article and thought to let you know. Better to be safe than sorry.

AirGradient is one of only a few companies that advertise that they use open source code and respect personal data privacy. I just wanted to let you know that you can react so this thing does not come back to you at all.

Just talk to Achim or someone else from the team and figure out a way that is safe for you and the company.