Skip to content

Correctly Copy the DXGKRNL_INTERFACE Structure

During its DxgkDdiStartDevice routine, the qxldod driver is provided with an DXGKRNL_INTERFACE structure containing mostly pointers to various WDDM interface functions that it my need to use. The driver copies this structure to its device-specific block of memory. However, the driver expected the system would provide the same version of the structure it uses, however, this is not necessarily true. Such behavior resulted in copying memory past the end of the system-provided structure which triggered the crash.

Fixed version of the driver copies only bytes really occupied by the DXGKRNL_INTERFACE structure (stored in its Size member).

Cc: @yuri_benditovich

Merge request reports