]> git.proxmox.com Git - mirror_ubuntu-zesty-kernel.git/commit
udp: consistently apply ufo or fragmentation
authorWillem de Bruijn <willemb@google.com>
Fri, 14 Jul 2017 08:19:00 +0000 (10:19 +0200)
committerStefan Bader <stefan.bader@canonical.com>
Tue, 8 Aug 2017 10:24:34 +0000 (12:24 +0200)
commit5967f2e74e50c277759c900e415a5ef49ac1c635
treee59ceaca9de770a34ec7d2bfe527d72d62bb0847
parente635edd833bf1b46aa428d119a3cadd6a1249286
udp: consistently apply ufo or fragmentation

When iteratively building a UDP datagram with MSG_MORE and that
datagram exceeds MTU, consistently choose UFO or fragmentation.

Once skb_is_gso, always apply ufo. Conversely, once a datagram is
split across multiple skbs, do not consider ufo.

Sendpage already maintains the first invariant, only add the second.
IPv6 does not have a sendpage implementation to modify.

Fixes: e89e9cf539a2 ("[IPv4/IPv6]: UFO Scatter-gather approach")
Reported-by: Andrey Konovalov <andreyknvl@google.com>
Signed-off-by: Willem de Bruijn <willemb@google.com>
CVE-2017-1000112

(backported from email submission)
Signed-off-by: Stefan Bader <stefan.bader@canonical.com>
net/ipv4/ip_output.c
net/ipv6/ip6_output.c