From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752436AbdKHTnU (ORCPT ); Wed, 8 Nov 2017 14:43:20 -0500 Received: from mail-ot0-f196.google.com ([74.125.82.196]:44322 "EHLO mail-ot0-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752158AbdKHTnS (ORCPT ); Wed, 8 Nov 2017 14:43:18 -0500 X-Google-Smtp-Source: AGs4zMYVY6P2LoIZT0LRn/VCTkjX30ocUlTttA2UpXb/dlKaVSSD9Kv3PyGYpqxQ1+D2TrkKajkSBQ== Subject: Re: [PATCH v2 0/3] Makefile: Introduce CONFIG_CC_STACKPROTECTOR_AUTO To: Kees Cook , Andrew Morton Cc: Masahiro Yamada , Arnd Bergmann , Josh Triplett , Nicholas Piggin , linux-kbuild@vger.kernel.org, linux-kernel@vger.kernel.org References: <1510076320-69931-1-git-send-email-keescook@chromium.org> From: Laura Abbott Message-ID: <1a23e5eb-66d7-2e86-e918-fd5eabb4c014@redhat.com> Date: Wed, 8 Nov 2017 11:43:14 -0800 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.3.0 MIME-Version: 1.0 In-Reply-To: <1510076320-69931-1-git-send-email-keescook@chromium.org> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 11/07/2017 09:38 AM, Kees Cook wrote: > As described in the final patch: > > Nearly all modern compilers support a stack-protector option, and nearly > all modern distributions enable the kernel stack-protector, so enabling > this by default in kernel builds would make sense. However, Kconfig does > not have knowledge of available compiler features, so it isn't safe to > force on, as this would unconditionally break builds for the compilers > or architectures that don't have support. Instead, this introduces a new > option, CONFIG_CC_STACKPROTECTOR_AUTO, which attempts to discover the best > possible stack-protector available, and will allow builds to proceed even > if the compiler doesn't support any stack-protector. > > This option is made the default so that kernels built with modern > compilers will be protected-by-default against stack buffer overflows, > avoiding things like the recent BlueBorne attack. Selection of a specific > stack-protector option remains available, including disabling it. > > > This has lived over the last several days without any unfixed 0day failures. > > v2: > - under ..._AUTO, warn and continue on _all_ stack protector failure cases > - fix 32-bit boot regression due to lazy gz. > - set CONFIG_CC_STACKPROTECTOR_NONE for tiny.config. > > Thanks, > > -Kees > This passed a test build on all Fedora arches, including s390 and ppc. On x86 it picks up the strong option correctly. You're welcome to add Tested-by: Laura Abbott Thanks, Laura