Received: by 2002:a25:1985:0:0:0:0:0 with SMTP id 127csp1112930ybz; Fri, 1 May 2020 14:57:09 -0700 (PDT) X-Google-Smtp-Source: APiQypL2+em8wKJq8iebYr1cEq91qzVn3lhPYsqbrkEX3XRO4+QeK46nruoO94hSkq2XzsUBlxf+ X-Received: by 2002:a17:906:eb90:: with SMTP id mh16mr5262831ejb.201.1588370228918; Fri, 01 May 2020 14:57:08 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1588370228; cv=none; d=google.com; s=arc-20160816; b=iIQQktRghuKq+qZ0Rpyy0a7hDxJjdcZFac4gs+9J5uHzAsnFQjsqMLYxRC/EmBpkIk 7zUxFFAnA3KOZXEpt3RO4LWqUI8P7hcNX+ksqLXOXgC1XZ86mEMEv1YYYcKJ2SWDOq18 FDzEyNGbms1AaYGgFtw45C/u3rJ8FizmN/vOEGc7Xoyeac7UqGG/A+sy0BzlvHal/MUY 33QfI/X7C7fhFJy5nhK5LtKxPmi5cGvQ/+MKDYdToFbxudLRLjrMXPRIuuSRVI8aVikc srRVMtDHUEtjPMS+PIooMoPaIaNBVDMAUyUiz0NNFw2glRInQh7KFxYWb9L1LJM8pe34 qD2w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:message-id:date:subject:cc:to:from :dmarc-filter:dkim-signature; bh=AQ70akaLPnIqMlM4CmJJfg3Ty/uXQB6hVv/IyZfwri4=; b=vGzRRACmhn19IwSc1MoQZXB74KdkVSj3iBePDs0AAezv/dgOP9Ai1nuZvu50gGt7Bi 3gqfeKWtFC5LAry8NYgErchmbqmQ2BlM+uU6GmvFGrU38nYrCLBhBnlK8NdNwEl4hUsk pWrUfLFHzFH24QGaMMXgQV1VbCWrUyA03u+ef62mYS6lTJTlohc4XOgpdew1MwLSBqDE Kuz3gUO/zkVDDY5CXbMzS1AIpz91CBWxa5BI4GKS4dIDHDXVzzivl/F2IC0xc/mKhqV8 a/kmBWe7X9el/tq8g4vbtPFCgCXmHpy+eUImh/jHzagF54Ebi6L+0CKGoeWmPgkQl2nv +CDg== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@mg.codeaurora.org header.s=smtp header.b=puZHq1iH; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id rs10si2490940ejb.288.2020.05.01.14.56.46; Fri, 01 May 2020 14:57:08 -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=fail header.i=@mg.codeaurora.org header.s=smtp header.b=puZHq1iH; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726893AbgEAVzA (ORCPT + 99 others); Fri, 1 May 2020 17:55:00 -0400 Received: from mail27.static.mailgun.info ([104.130.122.27]:58310 "EHLO mail27.static.mailgun.info" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726045AbgEAVy7 (ORCPT ); Fri, 1 May 2020 17:54:59 -0400 DKIM-Signature: a=rsa-sha256; v=1; c=relaxed/relaxed; d=mg.codeaurora.org; q=dns/txt; s=smtp; t=1588370099; h=Message-Id: Date: Subject: Cc: To: From: Sender; bh=AQ70akaLPnIqMlM4CmJJfg3Ty/uXQB6hVv/IyZfwri4=; b=puZHq1iHgFyM/8BXyXTTlRnFLtvdplFxBhrcg/86dNIwFKeBIcKo6+idq8aAPjKq/D3V77mE CLqVS7vzfKomiWkXAA7qnR1BXaZeyawb64SX3ZaqEsBfvY/7Nvx8UexKgH7qGrzCCR9C31Jl oXeFERr/w8dEwIlXDIEufYOM3MY= X-Mailgun-Sending-Ip: 104.130.122.27 X-Mailgun-Sid: WyI0MWYwYSIsICJsaW51eC1rZXJuZWxAdmdlci5rZXJuZWwub3JnIiwgImJlOWU0YSJd Received: from smtp.codeaurora.org (ec2-35-166-182-171.us-west-2.compute.amazonaws.com [35.166.182.171]) by mxa.mailgun.org with ESMTP id 5eac9a9d.7f3115b200a0-smtp-out-n01; Fri, 01 May 2020 21:54:37 -0000 (UTC) Received: by smtp.codeaurora.org (Postfix, from userid 1001) id 39FE3C43637; Fri, 1 May 2020 21:54:37 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-caf-mail-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-1.0 required=2.0 tests=ALL_TRUSTED,SPF_NONE autolearn=unavailable autolearn_force=no version=3.4.0 Received: from sidgup-linux.qualcomm.com (i-global254.qualcomm.com [199.106.103.254]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-SHA256 (128/128 bits)) (No client certificate requested) (Authenticated sender: sidgup) by smtp.codeaurora.org (Postfix) with ESMTPSA id 86360C433F2; Fri, 1 May 2020 21:54:36 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 smtp.codeaurora.org 86360C433F2 Authentication-Results: aws-us-west-2-caf-mail-1.web.codeaurora.org; dmarc=none (p=none dis=none) header.from=codeaurora.org Authentication-Results: aws-us-west-2-caf-mail-1.web.codeaurora.org; spf=none smtp.mailfrom=sidgup@codeaurora.org From: Siddharth Gupta To: Masahiro Yamada , Sam Ravnborg Cc: Siddharth Gupta , linux-kernel@vger.kernel.org Subject: [PATCH] scripts: headers_install: Exit with error on config leak Date: Fri, 1 May 2020 14:54:25 -0700 Message-Id: <1588370065-30312-1-git-send-email-sidgup@codeaurora.org> X-Mailer: git-send-email 2.7.4 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org 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 -- Qualcomm Innovation Center, Inc. is a member of the Code Aurora Forum, a Linux Foundation Collaborative Project