mbox series

[ipsec,0/7] xfrm: policy: fix various bugs

Message ID 20190104131705.9550-1-fw@strlen.de
Headers show
Series xfrm: policy: fix various bugs | expand

Message

Florian Westphal Jan. 4, 2019, 1:16 p.m. UTC
This series addresses various bugs, mostly fallout from the recent
rcu tree work. One is a fix for an older bug coming from the initial
rcu conversion.

There were several xfrm policy related syzbot bugs recently, but
so far only one of them has a reproducer (addressed by patch #4).

As I provided ample rope for syzbot to hang itself with, there is
some chance that this and the other fixes also resolve the KASAN
and UAF syzbot xfrm reports reported in the last couple of days.

My plan is to wait until these patches are applied, and then tell syzbot
for all the open reports that the last patch 'fixes this'.

AFAIU that will make syzbot report the problem again in case it can still
trigger similar splats with these fixes in place.

Florian Westphal (7):
      selftests: xfrm: add block rules with adjacent/overlapping subnets
      xfrm: policy: use hlist rcu variants on inexact insert, part 2
      xfrm: policy: increment xfrm_hash_generation on hash rebuild
      xfrm: policy: delete inexact policies from inexact list on hash rebuild
      xfrm: policy: fix reinsertion on node merge
      selftests: xfrm: alter htresh to trigger move of policies to hash table
      xfrm: policy: fix infinite loop when merging src-nodes

 net/xfrm/xfrm_policy.c                     |   58 +++++-----
 tools/testing/selftests/net/xfrm_policy.sh |  153 ++++++++++++++++++++++++-----
 2 files changed, 160 insertions(+), 51 deletions(-)

Comments

Steffen Klassert Jan. 10, 2019, 8:09 a.m. UTC | #1
On Fri, Jan 04, 2019 at 02:16:58PM +0100, Florian Westphal wrote:
> This series addresses various bugs, mostly fallout from the recent
> rcu tree work. One is a fix for an older bug coming from the initial
> rcu conversion.
> 
> There were several xfrm policy related syzbot bugs recently, but
> so far only one of them has a reproducer (addressed by patch #4).
> 
> As I provided ample rope for syzbot to hang itself with, there is
> some chance that this and the other fixes also resolve the KASAN
> and UAF syzbot xfrm reports reported in the last couple of days.
> 
> My plan is to wait until these patches are applied, and then tell syzbot
> for all the open reports that the last patch 'fixes this'.
> 
> AFAIU that will make syzbot report the problem again in case it can still
> trigger similar splats with these fixes in place.
> 
> Florian Westphal (7):
>       selftests: xfrm: add block rules with adjacent/overlapping subnets
>       xfrm: policy: use hlist rcu variants on inexact insert, part 2
>       xfrm: policy: increment xfrm_hash_generation on hash rebuild
>       xfrm: policy: delete inexact policies from inexact list on hash rebuild
>       xfrm: policy: fix reinsertion on node merge
>       selftests: xfrm: alter htresh to trigger move of policies to hash table
>       xfrm: policy: fix infinite loop when merging src-nodes

All applied, thanks a lot Florian!