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: <CAG48ez2u9gH8skjFcNR-cBctxCEdfZckDjvej07-hooiCvBO8A@mail.gmail.com>
Date:   Tue, 28 Aug 2018 14:53:35 +0200
From:   Jann Horn <jannh@...gle.com>
To:     Andrey Ryabinin <aryabinin@...tuozzo.com>
Cc:     Andy Lutomirski <luto@...nel.org>,
        "the arch/x86 maintainers" <x86@...nel.org>,
        kernel list <linux-kernel@...r.kernel.org>,
        Dmitry Vyukov <dvyukov@...gle.com>, kasan-dev@...glegroups.com,
        Alexander Potapenko <glider@...gle.com>,
        Kees Cook <keescook@...omium.org>
Subject: Re: [PATCH] x86/entry/64: wipe KASAN stack shadow in rewind_stack_do_exit()

On Tue, Aug 28, 2018 at 1:33 PM Andrey Ryabinin <aryabinin@...tuozzo.com> wrote:
> On 08/28/2018 01:38 PM, Jann Horn wrote:
> >> Why this has to be done in the rewind_stack_do_exit()?
> >> Are there any problems with calling the kasan_unpoison_task_stack(current) from oops_end(), before the rewind_stack_do_exit()?
> >
> > Ooh, good point! I didn't see that KASAN instrumentation is disabled
> > for dumpstack.c.
>
> It doesn't really matter. This would work with instrumented oops_end() as well.
> kasan_unpoison_task_stack() will unpoison everything including oops_end's stack.
> It would be also ok if kasan_unpoison_task_stack() instrumented,

But then that would rely on ASAN implementation details, so I'd be
hesitant to do that.

> or calling any number of instrumented functions
> in between kasan_unpoison_task_stack() and rewind_stack_do_exit(). As long as we return from these functions before
> the rewind_stack_do_exit(), the stack will be unpoisoned on return.

Yeah, I understand that. :)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ