]> git.baikalelectronics.ru Git - kernel.git/commit
vt: fix unchecked __put_user() in tioclinux ioctls
authorAdam Borowski <kilobyte@angband.pl>
Sat, 3 Jun 2017 07:35:06 +0000 (09:35 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 9 Jun 2017 09:07:36 +0000 (11:07 +0200)
commit19dc135df7b52e9824c5dde0425f7443a5001fe7
tree83afa7420dbee39116d3953d5ea260cb76443861
parent72b8439ab489b0b0ffc340e7f9a69c0eb521d5bb
vt: fix unchecked __put_user() in tioclinux ioctls

Only read access is checked before this call.

Actually, at the moment this is not an issue, as every in-tree arch does
the same manual checks for VERIFY_READ vs VERIFY_WRITE, relying on the MMU
to tell them apart, but this wasn't the case in the past and may happen
again on some odd arch in the future.

If anyone cares about 3.7 and earlier, this is a security hole (untested)
on real 80386 CPUs.

Signed-off-by: Adam Borowski <kilobyte@angband.pl>
CC: stable@vger.kernel.org # v3.7-
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/tty/vt/vt.c