linux/net/9p
Christoph Hellwig a39c46067c net/9p: validate fds in p9_fd_open
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 attempting a read or write, but
a new warning added in linux-next upsets syzcaller.

Fix this by just verifying the fds early on.

Link: http://lkml.kernel.org/r/20200710085722.435850-1-hch@lst.de
Reported-by: syzbot+e6f77e16ff68b2434a2c@syzkaller.appspotmail.com
Signed-off-by: Christoph Hellwig <hch@lst.de>
[Dominique: amend goto as per Doug Nazar's review]
Signed-off-by: Dominique Martinet <asmadeus@codewreck.org>
2020-07-19 14:58:29 +02:00
..
client.c 9pnet: allow making incomplete read requests 2020-03-27 09:29:56 +00:00
error.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 188 2019-05-30 11:29:21 -07:00
Kconfig treewide: Add SPDX license identifier - Makefile/Kconfig 2019-05-21 10:50:46 +02:00
Makefile 9p: Remove p9_idpool 2018-08-29 13:39:57 +09:00
mod.c net: Add MODULE_DESCRIPTION entries to network modules 2020-06-20 21:33:57 -07:00
protocol.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 188 2019-05-30 11:29:21 -07:00
protocol.h treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 188 2019-05-30 11:29:21 -07:00
trans_common.c net/9p: include trans_common.h to fix missing prototype warning. 2018-11-20 15:04:16 +09:00
trans_common.h net/9p: remove (now-)unused helpers 2015-04-11 22:28:29 -04:00
trans_fd.c net/9p: validate fds in p9_fd_open 2020-07-19 14:58:29 +02:00
trans_rdma.c rdma: Enable ib_alloc_cq to spread work over a device's comp_vectors 2019-08-05 11:50:32 -04:00
trans_virtio.c 9p pull request for inclusion in 5.13 2019-07-12 17:31:19 -07:00
trans_xen.c 9p/xen: increase XEN_9PFS_RING_ORDER 2020-06-02 08:00:39 +02:00