WSL2-Linux-Kernel/drivers/usb/usbip
Colin Ian King d4f0bf4525 usbip: vudc: fix null pointer dereference on udc->lock
commit df3334c223 upstream.

Currently the driver attempts to spin lock on udc->lock before a NULL
pointer check is performed on udc, hence there is a potential null
pointer dereference on udc->lock.  Fix this by moving the null check
on udc before the lock occurs.

Fixes: ea6873a45a ("usbip: vudc: Add SysFS infrastructure for VUDC")
Signed-off-by: Colin Ian King <colin.king@canonical.com>
Acked-by: Shuah Khan <shuahkh@osg.samsung.com>
Reviewed-by: Krzysztof Opasiak <k.opasiak@samsung.com>
Cc: stable <stable@vger.kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-03-19 08:42:46 +01:00
..
Kconfig
Makefile License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
README
stub.h
stub_dev.c usbip: keep usbip_device sockfd state in sync with tcp_socket 2018-02-25 11:07:53 +01:00
stub_main.c usbip: stub: stop printing kernel pointer addresses in messages 2018-01-02 20:31:14 +01:00
stub_rx.c usbip: stub: stop printing kernel pointer addresses in messages 2018-01-02 20:31:14 +01:00
stub_tx.c usbip: stub: stop printing kernel pointer addresses in messages 2018-01-02 20:31:14 +01:00
usbip_common.c usbip: remove kernel addresses from usb device and urb debug msgs 2018-01-17 09:45:26 +01:00
usbip_common.h usbip: prevent vhci_hcd driver from leaking a socket pointer address 2017-12-20 10:10:19 +01:00
usbip_event.c
vhci.h usbip: vhci-hcd: Clean up the code by adding a new macro 2017-06-13 10:51:10 +02:00
vhci_hcd.c usbip: keep usbip_device sockfd state in sync with tcp_socket 2018-02-25 11:07:53 +01:00
vhci_rx.c usbip: vhci: stop printing kernel pointer addresses in messages 2018-01-02 20:31:14 +01:00
vhci_sysfs.c usbip: prevent vhci_hcd driver from leaking a socket pointer address 2017-12-20 10:10:19 +01:00
vhci_tx.c usbip: vhci: stop printing kernel pointer addresses in messages 2018-01-02 20:31:14 +01:00
vudc.h
vudc_dev.c
vudc_main.c
vudc_rx.c usbip: fix vudc_rx: harden CMD_SUBMIT path to handle malicious input 2018-01-17 09:45:26 +01:00
vudc_sysfs.c usbip: vudc: fix null pointer dereference on udc->lock 2018-03-19 08:42:46 +01:00
vudc_transfer.c
vudc_tx.c usbip: vudc_tx: fix v_send_ret_submit() vulnerability to null xfer buffer 2018-01-17 09:45:26 +01:00

README

TODO:
	- more discussion about the protocol
	- testing
	- review of the userspace interface
	- document the protocol

Please send patches for this code to Greg Kroah-Hartman <greg@kroah.com>