Skip to content
Commit 6a254242 authored by Rustam Kovhaev's avatar Rustam Kovhaev Committed by Paul Gortmaker
Browse files

staging: wlan-ng: fix out of bounds read in prism2sta_probe_usb()

commit fea22e15 upstream.

let's use usb_find_common_endpoints() to discover endpoints, it does all
necessary checks for type and xfer direction

remove memset() in hfa384x_create(), because we now assign endpoints in
prism2sta_probe_usb() and because create_wlan() uses kzalloc() to
allocate hfa384x struct before calling hfa384x_create()

Fixes: faaff976

 ("staging: wlan-ng: properly check endpoint types")
Reported-and-tested-by: default avatar <syzbot+22794221ab96b0bab53a@syzkaller.appspotmail.com>
Link: https://syzkaller.appspot.com/bug?extid=22794221ab96b0bab53a
Signed-off-by: default avatarRustam Kovhaev <rkovhaev@gmail.com>
Cc: stable <stable@vger.kernel.org>
Link: https://lore.kernel.org/r/20200804145614.104320-1-rkovhaev@gmail.com
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: default avatarPaul Gortmaker <paul.gortmaker@windriver.com>
parent 384241c0
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment