Re: [PATCH] net/9p: validate fds in p9_fd_open

2020-07-16 Thread David Miller
The amount of time you used to compose this email exceeds by several orders of magnitude the amount of effort it would have taken to merge the fix to Linus, calm the syzbot warnings, and make those warnings therefore more useful for people doing active development. I think your priorities are ki

Re: [PATCH] net/9p: validate fds in p9_fd_open

2020-07-16 Thread Dominique Martinet
David Miller wrote on Wed, Jul 15, 2020: > From: Dominique Martinet > Date: Wed, 15 Jul 2020 15:47:56 +0200 > > It's honestly just a warn on something that would fail anyway so I'd > > rather let it live in -next first, I don't get why syzbot is so verbose > > about this - it sent a mail when it f

Re: [PATCH] net/9p: validate fds in p9_fd_open

2020-07-15 Thread David Miller
From: Dominique Martinet Date: Wed, 15 Jul 2020 15:47:56 +0200 > It's honestly just a warn on something that would fail anyway so I'd > rather let it live in -next first, I don't get why syzbot is so verbose > about this - it sent a mail when it found a c repro and one more once it > bisected the

Re: [PATCH] net/9p: validate fds in p9_fd_open

2020-07-15 Thread Christoph Hellwig
On Wed, Jul 15, 2020 at 03:47:56PM +0200, Dominique Martinet wrote: > Christoph Hellwig wrote on Wed, Jul 15, 2020: > > FYI, this is now generating daily syzbot reports, so I'd love to see > > the fix going into Linus' tree ASAP.. > > Yes, I'm getting some syzbot warnings as well now. > > I had h

Re: [PATCH] net/9p: validate fds in p9_fd_open

2020-07-15 Thread Dominique Martinet
Christoph Hellwig wrote on Wed, Jul 15, 2020: > FYI, this is now generating daily syzbot reports, so I'd love to see > the fix going into Linus' tree ASAP.. Yes, I'm getting some syzbot warnings as well now. I had however only planned to get this in linux-next, since that is what the syzbot mails

Re: [PATCH] net/9p: validate fds in p9_fd_open

2020-07-15 Thread Christoph Hellwig
FYI, this is now generating daily syzbot reports, so I'd love to see the fix going into Linus' tree ASAP..

Re: [PATCH] net/9p: validate fds in p9_fd_open

2020-07-13 Thread Christoph Hellwig
On Sat, Jul 11, 2020 at 12:49:23PM +0200, Dominique Martinet wrote: > > >diff --git a/net/9p/trans_fd.c b/net/9p/trans_fd.c > > >index 13cd683a658ab6..1cd8ea0e493617 100644 > > >--- a/net/9p/trans_fd.c > > >+++ b/net/9p/trans_fd.c > > >@@ -803,20 +803,28 @@ static int p9_fd_open(struct p9_client *c

Re: [PATCH] net/9p: validate fds in p9_fd_open

2020-07-11 Thread Dominique Martinet
Doug Nazar wrote on Fri, Jul 10, 2020: > On 2020-07-10 04:57, Christoph Hellwig wrote: > > >diff --git a/net/9p/trans_fd.c b/net/9p/trans_fd.c > >index 13cd683a658ab6..1cd8ea0e493617 100644 > >--- a/net/9p/trans_fd.c > >+++ b/net/9p/trans_fd.c > >@@ -803,20 +803,28 @@ static int p9_fd_open(struct

Re: [PATCH] net/9p: validate fds in p9_fd_open

2020-07-10 Thread Doug Nazar
On 2020-07-10 04:57, Christoph Hellwig wrote: diff --git a/net/9p/trans_fd.c b/net/9p/trans_fd.c index 13cd683a658ab6..1cd8ea0e493617 100644 --- a/net/9p/trans_fd.c +++ b/net/9p/trans_fd.c @@ -803,20 +803,28 @@ static int p9_fd_open(struct p9_client *client, int rfd, int wfd) re

Re: [PATCH] net/9p: validate fds in p9_fd_open

2020-07-10 Thread Dominique Martinet
Christoph Hellwig wrote on Fri, Jul 10, 2020: > p9_fd_open just fgets file descriptors passed in from userspace, but > doesn't verify that they are valid for read or writing. This gets > cought down in the VFS when actually attemping a read or write, but a > new warning added in linux-next upsets

[PATCH] net/9p: validate fds in p9_fd_open

2020-07-10 Thread Christoph Hellwig
p9_fd_open just fgets file descriptors passed in from userspace, but doesn't verify that they are valid for read or writing. This gets cought down in the VFS when actually attemping a read or write, but a new warning added in linux-next upsets syzcaller. Fix this by just verifying the fds early o