]> git.proxmox.com Git - mirror_ubuntu-bionic-kernel.git/commit
can: peak_usb: fix slab info leak
authorJohan Hovold <johan@kernel.org>
Wed, 23 Oct 2019 08:27:05 +0000 (10:27 +0200)
committerStefan Bader <stefan.bader@canonical.com>
Tue, 26 Nov 2019 12:16:09 +0000 (13:16 +0100)
commit6612db779b64f1123c7ed4c13e18553b39ffd426
treeec801626d2e7cf3237c41aae8c3e8c52ab9185d5
parent8579cc85889c7878a4bd5cabe4cbe92f717a0927
can: peak_usb: fix slab info leak

BugLink: https://bugs.launchpad.net/bugs/1853519
commit f7a1337f0d29b98733c8824e165fca3371d7d4fd upstream.

Fix a small slab info leak due to a failure to clear the command buffer
at allocation.

The first 16 bytes of the command buffer are always sent to the device
in pcan_usb_send_cmd() even though only the first two may have been
initialised in case no argument payload is provided (e.g. when waiting
for a response).

Fixes: bb4785551f64 ("can: usb: PEAK-System Technik USB adapters driver core")
Cc: stable <stable@vger.kernel.org> # 3.4
Reported-by: syzbot+863724e7128e14b26732@syzkaller.appspotmail.com
Signed-off-by: Johan Hovold <johan@kernel.org>
Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Kamal Mostafa <kamal@canonical.com>
Signed-off-by: Khalid Elmously <khalid.elmously@canonical.com>
drivers/net/can/usb/peak_usb/pcan_usb_core.c