Received: by 2002:a25:1985:0:0:0:0:0 with SMTP id 127csp1800534ybz; Sat, 2 May 2020 08:06:30 -0700 (PDT) X-Google-Smtp-Source: APiQypIYItGSTF8TuiqLCdEADI5tzoPez6wB6yKnUBl8JDKKlu00Jh+vKYPNTh1+q8yRT5mACgfp X-Received: by 2002:aa7:ce05:: with SMTP id d5mr7884093edv.120.1588431990053; Sat, 02 May 2020 08:06:30 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1588431990; cv=none; d=google.com; s=arc-20160816; b=Jd22T9Tag4WrNZr344XuIq1QKbt7c0W/aDw7hlRE55sRpn9ryIWk3VSwBTxmSKj4Ls LpTd3yausfGeCHslOGpXQMnkR+piOhuavoYHXXOskBw2ckGShCLurzmGiZ0+xPUUFcvO pqY4wfQSNsrQwm+FXQgWSo5OR2qg/RY5PBxNhiaDUvDesUce3QcZuB6XzjKPHKs71wbd uEJmFW2hpQFyEUTgLAHXJne8dYlSY4qXR9KJRUjY/Z5sB6De6Ejf8/ZtMPhLcDQX9f1T NKpnlhtyttzL9FpA6yJbXMqUN3xfKcGVC+GoJchwXpDRL3PVFwE4e+314J7lL+VzsAL+ ROxw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:dkim-signature:dkim-filter; bh=DMFnL4Ja0ytXLUSslY0x5/p22BzQ4UAUV+62ACuyysQ=; b=p4V/gNnKL7eEnj7k7sVPfZ0yeIqI8b6K4vk9xX816a2iLvG7/7R8uxThwFe36kXZ12 9UtujdHiH66S1dqAgo4+7xJbFFxRTOfY8E5E5dT6pxMkkPDksEIlYEVvdcjYVl3GJ0FP EvEN9JaviWbREs9l7QMTuuQUPdXUafob6H9dXLnSX3ADP3AVeNYLcfRX0F681Bd2MsLD c4HNAN1EeKaBt7MJwMvjGRAUO1bg/l10np7isB0ck56Y2r7Rb74F7vWY18boUwRdUL8E Eg4cpowpcUfv2/HPGlQUz5j72NIFyD/R7gn6WUA6klewrreigq2zCs4hRnwdNblWBbAa EQVg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@nifty.com header.s=dec2015msa header.b=Aaef2tA5; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id ay15si3915080ejb.1.2020.05.02.08.06.06; Sat, 02 May 2020 08:06:30 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@nifty.com header.s=dec2015msa header.b=Aaef2tA5; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728134AbgEBPER (ORCPT + 99 others); Sat, 2 May 2020 11:04:17 -0400 Received: from conssluserg-06.nifty.com ([210.131.2.91]:48645 "EHLO conssluserg-06.nifty.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727968AbgEBPER (ORCPT ); Sat, 2 May 2020 11:04:17 -0400 Received: from mail-ua1-f50.google.com (mail-ua1-f50.google.com [209.85.222.50]) (authenticated) by conssluserg-06.nifty.com with ESMTP id 042F43bi028934 for ; Sun, 3 May 2020 00:04:04 +0900 DKIM-Filter: OpenDKIM Filter v2.10.3 conssluserg-06.nifty.com 042F43bi028934 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nifty.com; s=dec2015msa; t=1588431844; bh=DMFnL4Ja0ytXLUSslY0x5/p22BzQ4UAUV+62ACuyysQ=; h=References:In-Reply-To:From:Date:Subject:To:Cc:From; b=Aaef2tA5bhM68oFBSPc3aAjVXTHBzg4wvC5CM69KmQjAWqqYZkbBDZ2h7zoOKiMve xKHTsM9HnJhQattM9rgn18389ernwpwz2h9P8yAKLVYu9/zNqH9ByXdYD/VAURfaw0 lmdUr6fUn0KBiFrQxFl5BK3sE5vB3rl9lHgEHjhngqo/fOFSlV8yY2tfTaHEaDx5NV Nmz+B0qmDGUh+YFOFl3qzeuH7wo7YRwO6e82tRlsZgN5IF/jwQfSG9020K+ysi9+s3 PEZBKugnWxiIQrGFw6V7kvN2o6P4S4z0ddj49ANfcXE2ef+U2ayRu5g6PbBjpeeFX5 zH8uSkt8iYeig== X-Nifty-SrcIP: [209.85.222.50] Received: by mail-ua1-f50.google.com with SMTP id m9so4778584uaq.12 for ; Sat, 02 May 2020 08:04:03 -0700 (PDT) X-Gm-Message-State: AGi0PubLnPaP/07i1ohjkjUu5Lndk/5hlC6BEIqJ0rwH5q76AatG4H+x ELnPa7Th51pZXoyX4UgQTGleRuMatOkOHAyikqs= X-Received: by 2002:a9f:28c5:: with SMTP id d63mr6212285uad.25.1588431842760; Sat, 02 May 2020 08:04:02 -0700 (PDT) MIME-Version: 1.0 References: <1588370065-30312-1-git-send-email-sidgup@codeaurora.org> In-Reply-To: <1588370065-30312-1-git-send-email-sidgup@codeaurora.org> From: Masahiro Yamada Date: Sun, 3 May 2020 00:03:26 +0900 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [PATCH] scripts: headers_install: Exit with error on config leak To: Siddharth Gupta Cc: Sam Ravnborg , Linux Kernel Mailing List Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Sat, May 2, 2020 at 6:55 AM Siddharth Gupta wrote: > > Misuse of CONFIG_* in UAPI headers should result in an error as it exposes > configuration of different targets to userspace. > > Signed-off-by: Siddharth Gupta > --- > scripts/headers_install.sh | 3 ++- > 1 file changed, 2 insertions(+), 1 deletion(-) > > diff --git a/scripts/headers_install.sh b/scripts/headers_install.sh > index a07668a..bd6c93a 100755 > --- a/scripts/headers_install.sh > +++ b/scripts/headers_install.sh > @@ -109,7 +109,8 @@ do > done > > if [ "$warn" = 1 ]; then > - echo "warning: $INFILE: leak $c to user-space" >&2 > + echo "error: $INFILE: leak $c to user-space" >&2 > + exit 1 > fi > done If you want to change this, please update the comment at line 67. Also, rename the variable $warn to something else, $error or $leak_error, etc. ? -- Best Regards Masahiro Yamada