[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <1515610607.131759.27.camel@gmail.com>
Date: Wed, 10 Jan 2018 10:56:47 -0800
From: Eric Dumazet <eric.dumazet@...il.com>
To: Mike Maloney <maloneykernel@...il.com>, netdev@...r.kernel.org,
davem@...emloft.net
Cc: Mike Maloney <maloney@...gle.com>
Subject: Re: [PATCH net] ipv6: fix udpv6 sendmsg crash caused by too small
MTU
On Wed, 2018-01-10 at 12:45 -0500, Mike Maloney wrote:
> From: Mike Maloney <maloney@...gle.com>
>
> The logic in __ip6_append_data() assumes that the MTU is at least large
> enough for the headers. A device's MTU may be adjusted after being
> added while sendmsg() is processing data, resulting in
> __ip6_append_data() seeing any MTU. For an mtu smaller than the size of
> the fragmentation header, the math results in a negative 'maxfraglen',
> which causes problems when refragmenting any previous skb in the
> skb_write_queue, leaving it possibly malformed.
>
> Instead sendmsg returns EINVAL when the mtu is calculated to be less
> than IPV6_MIN_MTU.
>
> Reported-by: syzbot <syzkaller@...glegroups.com>
> Signed-off-by: Mike Maloney <maloney@...gle.com>
>
>
Reviewed-by: Eric Dumazet <edumazet@...gle.com>
Powered by blists - more mailing lists