summaryrefslogtreecommitdiff
path: root/block
diff options
context:
space:
mode:
authorJens Axboe <axboe@kernel.dk>2018-09-04 11:52:34 -0600
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2018-09-19 22:43:35 +0200
commit23ecbbad7bf921f83a5c99718ded203676ddd91c (patch)
treebf4b9d906919d98156b5dcdd3f9079f5da4d8011 /block
parent425739151e03c00487910a9d9cdfbd55cceb9975 (diff)
nbd: don't allow invalid blocksize settings
commit bc811f05d77f47059c197a98b6ad242eb03999cb upstream. syzbot reports a divide-by-zero off the NBD_SET_BLKSIZE ioctl. We need proper validation of the input here. Not just if it's zero, but also if the value is a power-of-2 and in a valid range. Add that. Cc: stable@vger.kernel.org Reported-by: syzbot <syzbot+25dbecbec1e62c6b0dd4@syzkaller.appspotmail.com> Reviewed-by: Josef Bacik <josef@toxicpanda.com> Signed-off-by: Jens Axboe <axboe@kernel.dk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'block')
0 files changed, 0 insertions, 0 deletions