From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752017AbcGOCGR (ORCPT ); Thu, 14 Jul 2016 22:06:17 -0400 Received: from mail-pa0-f67.google.com ([209.85.220.67]:34748 "EHLO mail-pa0-f67.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751279AbcGOCGK (ORCPT ); Thu, 14 Jul 2016 22:06:10 -0400 Date: Fri, 15 Jul 2016 12:05:50 +1000 From: Balbir Singh To: Kees Cook Cc: linux-kernel@vger.kernel.org, Rik van Riel , Casey Schaufler , PaX Team , Brad Spengler , Russell King , Catalin Marinas , Will Deacon , Ard Biesheuvel , Benjamin Herrenschmidt , Michael Ellerman , Tony Luck , Fenghua Yu , "David S. Miller" , x86@kernel.org, Christoph Lameter , Pekka Enberg , David Rientjes , Joonsoo Kim , Andrew Morton , Andy Lutomirski , Borislav Petkov , Mathias Krause , Jan Kara , Vitaly Wool , Andrea Arcangeli , Dmitry Vyukov , Laura Abbott , linux-arm-kernel@lists.infradead.org, linux-ia64@vger.kernel.org, linuxppc-dev@lists.ozlabs.org, sparclinux@vger.kernel.org, linux-arch@vger.kernel.org, linux-mm@kvack.org, kernel-hardening@lists.openwall.com Subject: Re: [PATCH v2 11/11] mm: SLUB hardened usercopy support Message-ID: <20160715020550.GB13944@balbir.ozlabs.ibm.com> Reply-To: bsingharora@gmail.com References: <1468446964-22213-1-git-send-email-keescook@chromium.org> <1468446964-22213-12-git-send-email-keescook@chromium.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1468446964-22213-12-git-send-email-keescook@chromium.org> User-Agent: Mutt/1.6.1 (2016-04-27) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Jul 13, 2016 at 02:56:04PM -0700, Kees Cook wrote: > Under CONFIG_HARDENED_USERCOPY, this adds object size checking to the > SLUB allocator to catch any copies that may span objects. Includes a > redzone handling fix from Michael Ellerman. > > Based on code from PaX and grsecurity. > > Signed-off-by: Kees Cook > --- > init/Kconfig | 1 + > mm/slub.c | 36 ++++++++++++++++++++++++++++++++++++ > 2 files changed, 37 insertions(+) > > diff --git a/init/Kconfig b/init/Kconfig > index 798c2020ee7c..1c4711819dfd 100644 > --- a/init/Kconfig > +++ b/init/Kconfig > @@ -1765,6 +1765,7 @@ config SLAB > > config SLUB > bool "SLUB (Unqueued Allocator)" > + select HAVE_HARDENED_USERCOPY_ALLOCATOR Should this patch come in earlier from a build perspective? I think patch 1 introduces and uses __check_heap_object. Balbir Singh.