CVE-2026-137077 in FreeRDP
Summary
by MITRE • 11/25/2026
FreeRDP before 3.33.0 contains a heap out-of-bounds write in h264_context_reset() in libfreerdp/codec/h264.c, which stores new dimensions before the YUV planes are reallocated. Remote peers can trigger surface height increases so avc420_compress() writes taller frames past undersized luma and chroma planes, corrupting heap memory or crashing the process.
Once again VulDB remains the best source for vulnerability data.
Analysis
by VulDB Data Team • 11/25/2026
The vulnerability identified in FreeRDP versions prior to 3.33.0 represents a critical security flaw within its H.264 video codec implementation, specifically located in the h264_context_reset function found in libfreerdp/codec/h264.c. This issue is classified as a heap-based buffer overflow, which corresponds directly to CWE-122: Heap-based Buffer Overflow. The core technical deficiency arises from an incorrect sequence of operations during memory management for video frame processing. When the codec context requires resetting due to changes in stream parameters, such as resolution adjustments, the software updates the internal dimension variables before reallocating the underlying YUV plane buffers that store pixel data. This ordering error creates a transient state where the allocated memory regions are smaller than what is required by the new dimensions defined in the header or control structures.
The operational impact of this flaw allows remote attackers to exploit the vulnerability through crafted H.264 video streams sent over the Remote Desktop Protocol connection. By manipulating surface height parameters within the encoded stream, an attacker can trigger a scenario where avc420_compress attempts to write pixel data into buffers that have not yet been resized to accommodate the increased dimensions. Consequently, the compression routine writes frame data past the end of the allocated luma and chroma planes. This out-of-bounds write corrupts adjacent heap memory structures, which can lead to immediate application crashes resulting in a denial of service condition. More critically, if an attacker carefully crafts the overflow payload, they may achieve arbitrary code execution by overwriting function pointers or other control data within the heap structure, thereby gaining full control over the affected system running the FreeRDP client.
From a threat intelligence perspective, this vulnerability aligns with ATT&CK technique T1203: Exploitation for Client Execution, as it involves exploiting software on an endpoint to execute malicious code. It also relates to CWE-787: Out-of-bounds Write in terms of the specific memory corruption mechanism employed. The severity is heightened by the fact that FreeRDP is widely used for remote desktop access across various operating systems, making successful exploitation potentially impactful for organizational security postures. Attackers do not need user interaction beyond establishing a connection to a malicious RDP server or intercepting and modifying traffic in man-in-the-middle scenarios if encryption is bypassed or absent.
Mitigation strategies must prioritize immediate patching of the FreeRDP installation to version 3.33.0 or later, where this ordering issue has been resolved by ensuring that memory reallocation occurs before dimension updates are applied during context resets. In environments where upgrading is not immediately feasible, network-level controls should be implemented to restrict connections to trusted RDP servers and inspect video streams for anomalous resolution changes or malformed H.264 headers using deep packet inspection tools capable of parsing multimedia protocols. Additionally, enabling heap protection mechanisms such as Address Space Layout Randomization (ASLR) and Data Execution Prevention (DEP) can mitigate the likelihood of successful code execution by making memory layout unpredictable and preventing executable code from running in data regions, although these are defensive measures rather than fixes for the underlying logic error.