Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1517308
| From | Johan Hovold <johan@kernel.org> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | Re: [PATCH] USB: serial: fix invalid user-pointer checks |
| Date | 2016-11-08 16:50 +0100 |
| Message-ID | <sBgOS-2Jy-25@gated-at.bofh.it> (permalink) |
| References | <sBdHk-SQ-13@gated-at.bofh.it> <sBfpL-20X-13@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
On Tue, Nov 08, 2016 at 03:13:13PM +0100, Oliver Neukum wrote: > On Tue, 2016-11-08 at 13:26 +0100, Johan Hovold wrote: > > Drop invalid user-pointer checks from ioctl handlers. > > > > A NULL-pointer can be valid in user space and copy_to_user() takes > > care > > of sanity checking. > > Shouldn't we bail out early in these cases? I don't think it's worth it, and this is also the general pattern for such ioctls. The added overhead for an error case like this is really negligible. Thanks, Johan
Back to linux.kernel | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
[PATCH] USB: serial: fix invalid user-pointer checks Johan Hovold <johan@kernel.org> - 2016-11-08 13:30 +0100
Re: [PATCH] USB: serial: fix invalid user-pointer checks Oliver Neukum <oneukum@suse.com> - 2016-11-08 15:20 +0100
Re: [PATCH] USB: serial: fix invalid user-pointer checks Johan Hovold <johan@kernel.org> - 2016-11-08 16:50 +0100
Re: [PATCH] USB: serial: fix invalid user-pointer checks Oliver Neukum <oneukum@suse.com> - 2016-11-09 12:10 +0100
Re: [PATCH] USB: serial: fix invalid user-pointer checks Johan Hovold <johan@kernel.org> - 2016-11-09 12:10 +0100
csiph-web