Re: [PATCH] fork: Allow stack to be wiped on fork

2018-02-22 Thread Mel Gorman
On Wed, Feb 21, 2018 at 01:56:33AM +, Andrew Lutomirski wrote: > > It would be much nicer to be able to control this at runtime rather > > than compile-time. Why not a /proc tunable? We could always use more > > of those ;) > > /proc/sys/kernel/hardening_features_that_cost_essentially_nothin

Re: [PATCH] fork: Allow stack to be wiped on fork

2018-02-20 Thread Andy Lutomirski
On Wed, Feb 21, 2018 at 12:31 AM, Andrew Morton wrote: > On Tue, 16 Jan 2018 21:50:15 -0800 Kees Cook wrote: > >> One of the classes of kernel stack content leaks is exposing the contents >> of prior heap or stack contents when a new process stack is allocated. >> Normally, those stacks are not z

Re: [PATCH] fork: Allow stack to be wiped on fork

2018-02-20 Thread Andrew Morton
On Tue, 16 Jan 2018 21:50:15 -0800 Kees Cook wrote: > One of the classes of kernel stack content leaks is exposing the contents > of prior heap or stack contents when a new process stack is allocated. > Normally, those stacks are not zeroed, and the old contents remain in > place. With some types

Re: [PATCH] fork: Allow stack to be wiped on fork

2018-01-26 Thread Jiri Kosina
On Fri, 26 Jan 2018, Jiri Kosina wrote: > > diff --git a/include/linux/thread_info.h b/include/linux/thread_info.h > > index 34f053a150a9..091f53fe31cc 100644 > > --- a/include/linux/thread_info.h > > +++ b/include/linux/thread_info.h > > @@ -43,7 +43,9 @@ enum { > > #define THREAD_ALIGN TH

Re: [PATCH] fork: Allow stack to be wiped on fork

2018-01-26 Thread Jiri Kosina
On Tue, 16 Jan 2018, Kees Cook wrote: > diff --git a/include/linux/thread_info.h b/include/linux/thread_info.h > index 34f053a150a9..091f53fe31cc 100644 > --- a/include/linux/thread_info.h > +++ b/include/linux/thread_info.h > @@ -43,7 +43,9 @@ enum { > #define THREAD_ALIGN THREAD_SIZE > #endif

Re: [PATCH] fork: Allow stack to be wiped on fork

2018-01-19 Thread Laura Abbott
On 01/17/2018 01:17 AM, Michal Hocko wrote: On Tue 16-01-18 21:50:15, Kees Cook wrote: One of the classes of kernel stack content leaks is exposing the contents of prior heap or stack contents when a new process stack is allocated. Normally, those stacks are not zeroed, and the old contents rema

Re: [PATCH] fork: Allow stack to be wiped on fork

2018-01-17 Thread Michal Hocko
On Tue 16-01-18 21:50:15, Kees Cook wrote: > One of the classes of kernel stack content leaks is exposing the contents > of prior heap or stack contents when a new process stack is allocated. > Normally, those stacks are not zeroed, and the old contents remain in > place. With some types of stack c

[PATCH] fork: Allow stack to be wiped on fork

2018-01-16 Thread Kees Cook
One of the classes of kernel stack content leaks is exposing the contents of prior heap or stack contents when a new process stack is allocated. Normally, those stacks are not zeroed, and the old contents remain in place. With some types of stack content exposure flaws, those contents can leak to u