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: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAJAFBLAx1G_AYCWrjnJ_NXLNr0-BTaLtORj9J87Q8YnKVB7bwQ@mail.gmail.com>
Date:   Thu, 15 Dec 2016 13:16:08 +0100
From:   Fubo Chen <fubo.chen@...il.com>
To:     "Eric W. Biederman" <ebiederm@...ssion.com>
Cc:     Dmitry Torokhov <dmitry.torokhov@...il.com>,
        Jakub Kicinski <kubakici@...pl>,
        Linux Kernel <linux-kernel@...r.kernel.org>,
        Kees Cook <keescook@...omium.org>,
        Johannes Berg <johannes@...solutions.net>,
        Maciej Żenczykowski <zenczykowski@...il.com>
Subject: Re: [PATCH] userns: suppress kmemleak message

On Thu, Nov 3, 2016 at 3:54 PM, Eric W. Biederman <ebiederm@...ssion.com> wrote:
> Dmitry Torokhov <dmitry.torokhov@...il.com> writes:
>
>> We do not ever intend to unregister "user" sysctl table, unfortunately
>> it leads kmemleak to believe that we are leaking memory:
>
> Sounds like an issue with kmemleak because we do retain references.
>
> So no we don't intend to unregister the table.
>
> As for the patch.
>
> Nacked-by: "Eric W. Biederman" <ebiederm@...ssion.com>
>
> I can't see the using kmemleak_not_leak is possibly good form.  I
> would much rather have suggestions about constructs that won't confuse
> kmemleak and won't need ugly annotations that serve no purpose but to
> appease a tool.  Perhaps the user_header variable needs to be moved out
> of user_namespace_sysctl_init.

The only alternative I see is to use WRITE_ONCE() instead of "=" to
set "user_header" such that the compiler cannot optimize that variable
away. Which of these two approaches do you prefer?

Fubo.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ