From: Alan Stern <stern@rowland.harvard.edu>
To: Mauro Carvalho Chehab <mchehab@kernel.org>, Greg KH <greg@kroah.com>
Cc: andreyknvl@google.com,
Kernel development list <linux-kernel@vger.kernel.org>,
<linux-media@vger.kernel.org>,
USB list <linux-usb@vger.kernel.org>,
<syzkaller-bugs@googlegroups.com>, <wen.yang99@zte.com.cn>
Subject: Re: [PATCH] media: usb: siano: Fix general protection fault in smsusb
Date: Fri, 24 May 2019 09:54:02 -0400 (EDT) [thread overview]
Message-ID: <Pine.LNX.4.44L0.1905240951470.1435-100000@iolanthe.rowland.org> (raw)
In-Reply-To: <20190524103540.250a69e7@coco.lan>
On Fri, 24 May 2019, Mauro Carvalho Chehab wrote:
> Em Tue, 7 May 2019 12:39:47 -0400 (EDT)
> Alan Stern <stern@rowland.harvard.edu> escreveu:
>
> > The syzkaller USB fuzzer found a general-protection-fault bug in the
> > smsusb part of the Siano DVB driver. The fault occurs during probe
> > because the driver assumes without checking that the device has both
> > IN and OUT endpoints and the IN endpoint is ep1.
> >
> > By slightly rearranging the driver's initialization code, we can make
> > the appropriate checks early on and thus avoid the problem. If the
> > expected endpoints aren't present, the new code safely returns -ENODEV
> > from the probe routine.
> >
> > Signed-off-by: Alan Stern <stern@rowland.harvard.edu>
> > Reported-and-tested-by: syzbot+53f029db71c19a47325a@syzkaller.appspotmail.com
> > CC: <stable@vger.kernel.org>
> Patch looks correct, and I'm applying it. It exposes another potential
> problem though: what happens if sizeof(desc.wMaxPacketSize) < sizeof(struct sms_msg_hdr)?
>
> I'm enclosing a followup patch that should solve this situation
> (and clean up a sparse warning).
>
> Thanks,
> Mauro
Your points are well taken.
However, Greg KH has already taken the original patch and a fix for the
sparse warning into his tree. I guess the two of you should figure out
how best to straighten this out.
Alan Stern
next prev parent reply other threads:[~2019-05-24 13:54 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-04-18 12:06 general protection fault in smsusb_init_device syzbot
2019-04-19 20:29 ` Alan Stern
2019-05-06 20:41 ` Alan Stern
2019-05-06 21:21 ` syzbot
2019-05-07 16:39 ` [PATCH] media: usb: siano: Fix general protection fault in smsusb Alan Stern
2019-05-08 6:01 ` Johan Hovold
2019-05-24 13:35 ` Mauro Carvalho Chehab
2019-05-24 13:54 ` Alan Stern [this message]
2019-05-07 8:34 ` general protection fault in smsusb_init_device Johan Hovold
2019-05-07 14:42 ` Alan Stern
2019-05-07 15:07 ` Johan Hovold
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=Pine.LNX.4.44L0.1905240951470.1435-100000@iolanthe.rowland.org \
--to=stern@rowland.harvard.edu \
--cc=andreyknvl@google.com \
--cc=greg@kroah.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-media@vger.kernel.org \
--cc=linux-usb@vger.kernel.org \
--cc=mchehab@kernel.org \
--cc=syzkaller-bugs@googlegroups.com \
--cc=wen.yang99@zte.com.cn \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).