Willem de Bruijn 6cd021a58c udp: segment looped gso packets correctly
Multicast and broadcast packets can be looped from egress to ingress
pre segmentation with dev_loopback_xmit. That function unconditionally
sets ip_summed to CHECKSUM_UNNECESSARY.

udp_rcv_segment segments gso packets in the udp rx path. Segmentation
usually executes on egress, and does not expect packets of this type.
__udp_gso_segment interprets !CHECKSUM_PARTIAL as CHECKSUM_NONE. But
the offsets are not correct for gso_make_checksum.

UDP GSO packets are of type CHECKSUM_PARTIAL, with their uh->check set
to the correct pseudo header checksum. Reset ip_summed to this type.
(CHECKSUM_PARTIAL is allowed on ingress, see comments in skbuff.h)

Reported-by: syzbot <syzkaller@googlegroups.com>
Fixes: cf329aa42b66 ("udp: cope with UDP GRO packet misdirection")
Signed-off-by: Willem de Bruijn <willemb@google.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2020-01-28 10:56:51 +01:00
..
2019-04-19 14:07:40 -07:00
2020-01-27 11:33:29 +01:00
2019-12-09 09:59:07 +01:00
2019-10-23 20:13:22 -07:00
2019-12-09 10:36:44 -08:00
2019-09-13 21:44:19 +02:00
2020-01-25 08:14:39 +01:00
2020-01-14 11:31:41 -08:00
2019-12-09 10:36:44 -08:00
2019-04-22 21:47:25 -07:00
2019-10-05 16:29:00 -07:00
2019-12-09 10:28:43 -08:00
2019-06-19 11:23:13 -04:00
2019-12-09 09:59:07 +01:00