audk/MdeModulePkg/Bus/Usb/UsbMouseAbsolutePointerDxe
Ruiyu Ni 0dd6065520 MdeModulePkg/AbsPointer: Don't access key codes when length is wrong
Per USB HID spec, the buffer holding key codes should at least 3-byte
long.
Today's code assumes that the key codes buffer length is longer than
3-byte and unconditionally accesses the key codes buffer.
It's incorrect.
The patch fixes the issue by returning Device Error when the
length is less than 3-byte.

Contributed-under: TianoCore Contribution Agreement 1.1
Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com>
Cc: Star Zeng <star.zeng@intel.com>
Cc: Jiewen Yao <jiewen.yao@intel.com>
Cc: Steven Shi <steven.shi@intel.com>
Reviewed-by: Star Zeng <star.zeng@intel.com>
2018-10-17 11:04:02 +08:00
..
ComponentName.c
MouseHid.c
UsbMouseAbsolutePointer.c MdeModulePkg/AbsPointer: Don't access key codes when length is wrong 2018-10-17 11:04:02 +08:00
UsbMouseAbsolutePointer.h MdeModulePkg: Clean up source files 2018-06-28 11:19:45 +08:00
UsbMouseAbsolutePointerDxe.inf MdeModulePkg: Removing ipf which is no longer supported from edk2. 2018-09-06 15:25:16 +08:00
UsbMouseAbsolutePointerDxe.uni MdeModulePkg: Clean up source files 2018-06-28 11:19:45 +08:00
UsbMouseAbsolutePointerDxeExtra.uni MdeModulePkg: Clean up source files 2018-06-28 11:19:45 +08:00