lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Wed, 31 Mar 2021 08:00:24 +0200
From:   Eric Dumazet <edumazet@...gle.com>
To:     Eric Dumazet <eric.dumazet@...il.com>
Cc:     "David S . Miller" <davem@...emloft.net>,
        Jakub Kicinski <kuba@...nel.org>,
        netdev <netdev@...r.kernel.org>,
        syzbot <syzkaller@...glegroups.com>
Subject: Re: [PATCH net-next] ip6_tunnel: sit: proper dev_{hold|put} in
 ndo_[un]init methods

On Tue, Mar 30, 2021 at 8:45 AM Eric Dumazet <eric.dumazet@...il.com> wrote:
>
> From: Eric Dumazet <edumazet@...gle.com>
>
> Same reasons than for the previous commits :
> 6289a98f0817 ("sit: proper dev_{hold|put} in ndo_[un]init methods")
> 40cb881b5aaa ("ip6_vti: proper dev_{hold|put} in ndo_[un]init methods")
> 7f700334be9a ("ip6_gre: proper dev_{hold|put} in ndo_[un]init methods")
>
> After adopting CONFIG_PCPU_DEV_REFCNT=n option, syzbot was able to trigger
> a warning [1]
>
> Issue here is that:
>
> - all dev_put() should be paired with a corresponding prior dev_hold().
>
> - A driver doing a dev_put() in its ndo_uninit() MUST also
>   do a dev_hold() in its ndo_init(), only when ndo_init()
>   is returning 0.
>
> Otherwise, register_netdevice() would call ndo_uninit()
> in its error path and release a refcount too soon.
>
>

Note to David & Jakub

Can you merge this patch so that I can send my global fix for fallback
tunnels, with a correct Fixes: tag for this patch ?

Thanks !

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ