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, 14 Jan 2019 19:08:19 +0300
From:   Andrey Ryabinin <aryabinin@...tuozzo.com>
To:     Dmitry Vyukov <dvyukov@...gle.com>
Cc:     Andrew Morton <akpm@...ux-foundation.org>,
        LKML <linux-kernel@...r.kernel.org>,
        kasan-dev <kasan-dev@...glegroups.com>,
        Linux-MM <linux-mm@...ck.org>,
        Linux ARM <linux-arm-kernel@...ts.infradead.org>,
        Qian Cai <cai@....pw>, Alexander Potapenko <glider@...gle.com>,
        Catalin Marinas <catalin.marinas@....com>,
        Will Deacon <will.deacon@....com>
Subject: Re: [PATCH] kasan: Remove use after scope bugs detection.

On 1/14/19 4:24 PM, Dmitry Vyukov wrote:
> On Fri, Jan 11, 2019 at 7:58 PM Andrey Ryabinin <aryabinin@...tuozzo.com> wrote:
>>
>> Use after scope bugs detector seems to be almost entirely useless
>> for the linux kernel. It exists over two years, but I've seen only
>> one valid bug so far [1]. And the bug was fixed before it has been
>> reported. There were some other use-after-scope reports, but they
>> were false-positives due to different reasons like incompatibility
>> with structleak plugin.
>>
>> This feature significantly increases stack usage, especially with
>> GCC < 9 version, and causes a 32K stack overflow. It probably
>> adds performance penalty too.
>>
>> Given all that, let's remove use-after-scope detector entirely.
>>
>> While preparing this patch I've noticed that we mistakenly enable
>> use-after-scope detection for clang compiler regardless of
>> CONFIG_KASAN_EXTRA setting. This is also fixed now.
> 
> Hi Andrey,
> 
> I am on a fence. On one hand removing bug detection sucks and each
> case of a missed memory corruption leads to a splash of assorted bug
> reports by syzbot. On the other hand everything you said is true.
> Maybe support for CONFIG_VMAP_STACK will enable stacks larger then
> PAGE_ALLOC_COSTLY_ORDER?
> 

Yes, with vmap stacks higher order won't be a problem, since vmalloc() does only 0-order 
allocations. But even with vmap stacks use-after-scope won't become useful,
thus I don't see the point of re-enabling it with vmap stacks.
If feature doesn't detect bugs, but waste resources, than it's bad for detecting bugs.
We wasting our limited resources for useless checks, instead of using these resources
for doing more useful checks, running tests faster hence detecting more bugs per-time. 




Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ