Technical impact
Eclipse Mosquitto versions 2.1 through 2.1.2 allow an unauthenticated client to send empty WebSocket frames that are incorrectly interpreted as zero‑length payloads. The MQTT packet reader then trusts this to calculate how many bytes to read, which causes it to advance the read pointer over an uninitialized heap allocation, leak heap and libc addresses, and underflow a counter so that subsequent frames overflow the heap. These read and write errors are reachable before any authentication, allowing a remote client to corrupt the broker’s memory and cause a crash or gain execution as the broker user.
Affected Systems
The flaw exists in the Eclipse Mosquitto broker owned by the Eclipse Foundation, specifically in all releases from 2.1.0 up through 2.1.2 inclusive. A listener configured with protocol websockets is required for the issue to be triggered.
Risk and Exploitability
The CVSS v3.1 score of 9.8 classifies this vulnerability as Critical. The EPSS score is not available, so the current exploitation probability cannot be quantified, and the vulnerability has not been catalogued in CISA’s KEV. An unauthenticated client can reach the vulnerable code over a WebSocket connection before user authentication, meaning the attack can be performed remotely from the public internet. The combined read/write flaw can disclose privileged pointers and then allow an attacker to execute arbitrary code under the broker’s operating system user.