Client heap overwrite via surface-size integer overflow
Published Aug 31, 2023 · Updated Nov 3, 2025
Out-of-bounds write in FreeRDP clients before 2.11.0 and 3.0.0-beta1 through 3.0.0-beta2 allows remote attackers to crash clients via RDPGFX data. gdi_CreateSurface multiplies a 32-bit scanline by the server-supplied height when allocating, then repeats the product as size_t in memset, so the initialization write exceeds the undersized heap buffer. The affected path runs only in FreeRDP-based clients that decode image data from an RDP server; FreeRDP proxies do not decode it.
Summary
What happened
Out-of-bounds write in FreeRDP clients before 2.11.0 and 3.0.0-beta1 through 3.0.0-beta2 allows remote attackers to crash clients via RDPGFX data. gdi_CreateSurface multiplies a 32-bit scanline by the server-supplied height when allocating, then repeats the product as size_t in memset, so the initialization write exceeds the undersized heap buffer. The affected path runs only in FreeRDP-based clients that decode image data from an RDP server; FreeRDP proxies do not decode it.
The record
- CVE
- CVE-2023-40186
- Published
- Aug 31, 2023
- Updated
- Nov 3, 2025
- Vendor
- FreeRDP
- Product
- FreeRDP
- Classifications
- CWE-190, CWE-787
- Attack vector
- network
- Privileges
- unauthenticated
Timeline
How it unfolded
- Aug 31, 2023CVE publishedPublication date reported by the CVE source.
- Nov 3, 2025Record updatedLatest update available in the CVE record.
Exploitability
Present is not the same as exploitable
Compare your product and version with the public record. A matching version still requires validation against your environment.
Is a vulnerable build present?
Compare these published version ranges with your installed build and any vendor patches.
- Affected versionversion=< 2.11.0
- Affected versionversion=>= 3.0.0-beta1, < 3.0.0-beta3
What conditions does exploitation require?
What is affected?
Published CVSS scores
CVSS describes severity. EPSS estimates exploitation probability.
Attacks
What attackers are doing with it
Daily unique IPs observed by Shadowserver honeypots for known exploited vulnerabilities (KEVs). Missing observations do not establish an absence of attacks.
Public exploit references
- GHSA-hcj4-3c3r-5j3v surface-size proof of conceptproof of concept · demonstrated
Labels summarize the accepted research assessment. They do not indicate a test against your environment.
Technologies
Your stack
See the directory against your own environment.
Your stack
Check the software in your environment
Book a demo to see how Hinoki identifies affected software and validates exploitability in your environment.
Book a demo