1
0
Fork 0
remarkable-linux/drivers/cdrom
Dan Carpenter 68c09d548b cdrom: information leak in cdrom_ioctl_media_changed()
commit 9de4ee4054 upstream.

This cast is wrong.  "cdi->capacity" is an int and "arg" is an unsigned
long.  The way the check is written now, if one of the high 32 bits is
set then we could read outside the info->slots[] array.

This bug is pretty old and it predates git.

Reviewed-by: Christoph Hellwig <hch@lst.de>
Cc: stable@vger.kernel.org
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-04-29 11:33:16 +02:00
..
Makefile License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
cdrom.c cdrom: information leak in cdrom_ioctl_media_changed() 2018-04-29 11:33:16 +02:00
gdrom.c block: don't set bounce limit in blk_init_queue 2017-06-27 12:13:45 -06:00