]> git.baikalelectronics.ru Git - kernel.git/commit
s390/keyboard: sanitize array index in do_kdsk_ioctl
authorMartin Schwidefsky <schwidefsky@de.ibm.com>
Thu, 19 Jul 2018 08:27:33 +0000 (10:27 +0200)
committerMartin Schwidefsky <schwidefsky@de.ibm.com>
Thu, 19 Jul 2018 14:37:30 +0000 (16:37 +0200)
commit0fa728eddf330e5322a69ccbebcc0ce6ec496415
tree60cc433b2c29fc4b249ddb9c9f6badbe1fc1d223
parent282d6b516068f407eedb0f19c1ffbd55a4375814
s390/keyboard: sanitize array index in do_kdsk_ioctl

The kbd_ioctl uses two user controlled indexes for KDGKBENT/KDSKBENT.
Use array_index_nospec to prevent any out of bounds speculation.

Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
drivers/s390/char/keyboard.c