linux-stable/net/core
Christoph Hellwig 1f466e1f15 net: cleanly handle kernel vs user buffers for ->msg_control
The msg_control field in struct msghdr can either contain a user
pointer when used with the recvmsg system call, or a kernel pointer
when used with sendmsg.  To complicate things further kernel_recvmsg
can stuff a kernel pointer in and then use set_fs to make the uaccess
helpers accept it.

Replace it with a union of a kernel pointer msg_control field, and
a user pointer msg_control_user one, and allow kernel_recvmsg operate
on a proper kernel pointer using a bitfield to override the normal
choice of a user pointer for recvmsg.

Signed-off-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: David S. Miller <davem@davemloft.net>
2020-05-11 16:59:16 -07:00
..
bpf_sk_storage.c Merge git://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf-next 2020-02-29 15:53:35 -08:00
datagram.c net: use indirect call wrappers for skb_copy_datagram_iter() 2020-03-25 11:30:40 -07:00
datagram.h
dev.c Merge branch 'mlx5-next' of git://git.kernel.org/pub/scm/linux/kernel/git/mellanox/linux 2020-05-09 01:05:30 -07:00
dev_addr_lists.c
dev_ioctl.c ethtool: add timestamping related string sets 2020-03-29 22:32:36 -07:00
devlink.c Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net 2020-05-06 22:10:13 -07:00
drop_monitor.c drop_monitor: work around gcc-10 stringop-overflow warning 2020-05-01 15:45:16 -07:00
dst.c net/dst: use a smaller percpu_counter batch for dst entries accounting 2020-05-08 21:33:33 -07:00
dst_cache.c
failover.c
fib_notifier.c
fib_rules.c net: fib_rules: Correctly set table field when table number exceeds 8 bits 2020-02-16 18:38:24 -08:00
filter.c bpf: Bpf_{g,s}etsockopt for struct bpf_sock_addr 2020-05-01 12:44:28 -07:00
flow_dissector.c bpf: Use bpf_prog_run_pin_on_cpu() at simple call sites. 2020-02-24 16:20:09 -08:00
flow_offload.c netfilter: flowtable: Fix incorrect tc_setup_type type 2020-03-27 18:41:52 +01:00
gen_estimator.c
gen_stats.c docs: networking: convert gen_stats.txt to ReST 2020-04-28 14:39:46 -07:00
gro_cells.c
hwbm.c
link_watch.c net: Add IF_OPER_TESTING 2020-04-20 12:43:24 -07:00
lwt_bpf.c net: add net available in build_state 2020-03-29 22:30:57 -07:00
lwtunnel.c net: ipv6: add rpl sr tunnel 2020-03-29 22:30:57 -07:00
Makefile ethtool: move to its own directory 2019-12-12 17:07:05 -08:00
neighbour.c Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net 2020-05-06 22:10:13 -07:00
net-procfs.c
net-sysfs.c net: napi: use READ_ONCE()/WRITE_ONCE() 2020-04-23 12:43:20 -07:00
net-sysfs.h net-sysfs: add netdev_change_owner() 2020-02-26 20:07:25 -08:00
net-traces.c
net_namespace.c bpf: Add netns cookie and enable it for bpf cgroup hooks 2020-03-27 19:40:38 -07:00
netclassid_cgroup.c cgroup, netclassid: remove double cond_resched 2020-04-21 15:44:30 -07:00
netevent.c
netpoll.c netpoll: accept NULL np argument in netpoll_send_skb() 2020-05-07 18:11:07 -07:00
netprio_cgroup.c
page_pool.c net: page pool: allow to pass zero flags to page_pool_init() 2020-03-29 21:49:20 -07:00
pktgen.c docs: networking: convert pktgen.txt to ReST 2020-04-30 12:56:37 -07:00
ptp_classifier.c
request_sock.c
rtnetlink.c net: rtnetlink: remove redundant assignment to variable err 2020-04-27 11:14:07 -07:00
scm.c net: cleanly handle kernel vs user buffers for ->msg_control 2020-05-11 16:59:16 -07:00
secure_seq.c
skbuff.c net: fix skb_panic to output real address 2020-05-01 15:19:59 -07:00
skmsg.c bpf: Use bpf_prog_run_pin_on_cpu() at simple call sites. 2020-02-24 16:20:09 -08:00
sock.c net: relax SO_TXTIME CAP_NET_ADMIN check 2020-05-07 18:17:32 -07:00
sock_diag.c
sock_map.c bpf: Allow bpf_map_lookup_elem for SOCKMAP and SOCKHASH 2020-04-29 23:30:59 +02:00
sock_reuseport.c net: Generate reuseport group ID on group creation 2020-02-21 22:29:45 +01:00
stream.c
sysctl_net_core.c sysctl: pass kernel pointers to ->proc_handler 2020-04-27 02:07:40 -04:00
timestamping.c net: Introduce a new MII time stamping interface. 2019-12-25 19:51:33 -08:00
tso.c
utils.c net: Fix skb->csum update in inet_proto_csum_replace16(). 2020-01-24 20:54:30 +01:00
xdp.c net: page_pool: API cleanup and comments 2020-02-20 10:09:25 -08:00