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]
Date:   Mon, 10 Jul 2017 12:34:50 +0300
From:   Alexey Dobriyan <adobriyan@...il.com>
To:     "Eric W. Biederman" <ebiederm@...ssion.com>
Cc:     "Reshetova, Elena" <elena.reshetova@...el.com>,
        "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
        "peterz@...radead.org" <peterz@...radead.org>,
        "gregkh@...uxfoundation.org" <gregkh@...uxfoundation.org>,
        "akpm@...ux-foundation.org" <akpm@...ux-foundation.org>,
        "mingo@...hat.com" <mingo@...hat.com>,
        "serge@...lyn.com" <serge@...lyn.com>,
        "arozansk@...hat.com" <arozansk@...hat.com>,
        "dave@...olabs.net" <dave@...olabs.net>,
        "keescook@...omium.org" <keescook@...omium.org>,
        Hans Liljestrand <ishkamiel@...il.com>,
        David Windsor <dwindsor@...il.com>
Subject: Re: [PATCH 1/3] ipc: convert ipc_namespace.count from atomic_t to refcount_t

On Mon, Jul 10, 2017 at 11:37 AM, Eric W. Biederman
<ebiederm@...ssion.com> wrote:
> "Reshetova, Elena" <elena.reshetova@...el.com> writes:
>
> 2>> Elena Reshetova <elena.reshetova@...el.com> writes:
>>>
>>> > refcount_t type and corresponding API should be
>>> > used instead of atomic_t when the variable is used as
>>> > a reference counter. This allows to avoid accidental
>>> > refcounter overflows that might lead to use-after-free
>>> > situations.
>>>
>>> In this patch you can see all of the uses of the count.
>>> What accidental refcount overflows are possible?
>>
>> Even if one can guarantee and prove that in the current implementation
>> there are no overflows possible, we can't say that for
>> sure for any future implementation. Bugs might always happen
>> unfortunately, but if we convert the refcounter to a safer
>> type we can be sure that overflows are not possible.
>>
>> Does it make sense to you?
>
> Not for code that is likely to remain unchanged for a decade no.
>
> This looks like a large set of unautomated changes without any real
> thought put into it.  That almost always results in a typo somewhere
> that breaks things.

This is nonsense. The wrong code would simply emit a warning
which are caught very quickly.

> So there is no benefit to the code, and a non-zero chance that there
> will be a typo breaking the code.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ