Re: [PATCH net] ipv6: fix races in ip6_dst_destroy()

2019-04-30 Thread David Miller
From: Eric Dumazet Date: Sun, 28 Apr 2019 12:22:25 -0700 > We had many syzbot reports that seem to be caused by use-after-free > of struct fib6_info. > > ip6_dst_destroy(), fib6_drop_pcpu_from() and rt6_remove_exception() > are writers vs rt->from, and use non consistent synchronization among >

Re: [PATCH net] ipv6: fix races in ip6_dst_destroy()

2019-04-29 Thread Wei Wang
On Sun, Apr 28, 2019 at 12:24 PM Eric Dumazet wrote: > > We had many syzbot reports that seem to be caused by use-after-free > of struct fib6_info. > > ip6_dst_destroy(), fib6_drop_pcpu_from() and rt6_remove_exception() > are writers vs rt->from, and use non consistent synchronization among > them

Re: [PATCH net] ipv6: fix races in ip6_dst_destroy()

2019-04-29 Thread Martin Lau
On Sun, Apr 28, 2019 at 12:22:25PM -0700, Eric Dumazet wrote: > We had many syzbot reports that seem to be caused by use-after-free > of struct fib6_info. > > ip6_dst_destroy(), fib6_drop_pcpu_from() and rt6_remove_exception() > are writers vs rt->from, and use non consistent synchronization among

Re: [PATCH net] ipv6: fix races in ip6_dst_destroy()

2019-04-28 Thread David Ahern
On 4/28/19 1:22 PM, Eric Dumazet wrote: > We had many syzbot reports that seem to be caused by use-after-free > of struct fib6_info. > > ip6_dst_destroy(), fib6_drop_pcpu_from() and rt6_remove_exception() > are writers vs rt->from, and use non consistent synchronization among > themselves. > > Sw

[PATCH net] ipv6: fix races in ip6_dst_destroy()

2019-04-28 Thread Eric Dumazet
We had many syzbot reports that seem to be caused by use-after-free of struct fib6_info. ip6_dst_destroy(), fib6_drop_pcpu_from() and rt6_remove_exception() are writers vs rt->from, and use non consistent synchronization among themselves. Switching to xchg() will solve the issues with no possible