Received: by 2002:a25:1506:0:0:0:0:0 with SMTP id 6csp5330371ybv; Tue, 11 Feb 2020 13:39:15 -0800 (PST) X-Google-Smtp-Source: APXvYqycz5Z+u2QHzactu3w4LchXtrWVh0DWVn7iRHpUoI9THYt1oG8T92Tj2aEnofeKRq36/G/1 X-Received: by 2002:aca:56ce:: with SMTP id k197mr4375575oib.99.1581457154907; Tue, 11 Feb 2020 13:39:14 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1581457154; cv=none; d=google.com; s=arc-20160816; b=rcPOPmmv75gtXCnCPQp82xJUbKkbSPg7k7K2ipbqLMUsSKNyh4QmlB8B5AcIH3RHo6 /yGxHT6sQFPoU8l8H9/wFSfnLlSjQjo97VN+FQ3zlvBVlN9bg7gBeJRPd1rQXvqSef60 y6FXxCkVPfXN6MjAZJOvIsU467Up6GRayhPH7w9Tjk1NR6Z8/CUtcfDYRK9hKOTjuxIK kHXg3/QPtlQpYqvBdZ9YrntIxtIAZ4IVm//LOirfpqM5ol2EmkZOAolAOXxAU/QuAuby Kce3D0uAfsSrJbtTBeAwe0DG87XZalEXQT6pcA/J5yq2bQLS8f3IqhlZmo7NSPdauPML +Z3w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from:date :dkim-signature; bh=Fduhzb+WwBefc5G2IiZw7jkFkPhFvQRZKGxZZqFDo/E=; b=z2Nwon2R/8U45z2cCJE2mTcVrA88JX4APOAUimim1b1xBSTJmybbgx7vUvYBQ250yo 89FzVXS2nvZ15jyNJ+/VfWpGOcCwEkmMjRIv80oRjV1GV8Q2YVTkJbXkAUybTdpeaFnU uFAKZsINcGWVQ5lSV7qK5rsCNao0CtBxnBNk3XPAjJBcHEapGG+E+qdG+uf0Wtj0ARU2 9KuJ9E8bTmTlTusr0+f56Jjq7gW+Q+eQa4Rh7R0WHTcOwnMJ7hEel6Eym52wIYA0JXOz xjjYHSJyef6kdERUMh40vSCzkPMDl73zlNvi4mcWnzR/K9PldzPjZQrM531IgbNv5Yfn X4aA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@chromium.org header.s=google header.b=aBFZgI1b; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=chromium.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id c144si2349884oig.263.2020.02.11.13.39.03; Tue, 11 Feb 2020 13:39:14 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@chromium.org header.s=google header.b=aBFZgI1b; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=chromium.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1730422AbgBKTZt (ORCPT + 99 others); Tue, 11 Feb 2020 14:25:49 -0500 Received: from mail-pl1-f194.google.com ([209.85.214.194]:33548 "EHLO mail-pl1-f194.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728508AbgBKTZt (ORCPT ); Tue, 11 Feb 2020 14:25:49 -0500 Received: by mail-pl1-f194.google.com with SMTP id ay11so4676180plb.0 for ; Tue, 11 Feb 2020 11:25:49 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to; bh=Fduhzb+WwBefc5G2IiZw7jkFkPhFvQRZKGxZZqFDo/E=; b=aBFZgI1bEVFMDfd8bvtXh9AZ1Mze2/1St6L/4BVij/mXj+0ZVWJe/BBz62kvdV/PUy KBlDmWnFixMHuEJ2x57jhZe2RZwo4KxOOAhGPDQppATODztQCUF1bGUHqwB2F+7dyFEs eKbWf5MArG16cSHqLbOgFxRg8G+4rPIDu1A8c= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to; bh=Fduhzb+WwBefc5G2IiZw7jkFkPhFvQRZKGxZZqFDo/E=; b=Hzn361BIh38YZagk8tlLURNpejW865wgYlXCrzdzB6BvJt1jWLo3vvc46tNPmwCFEY gYT8t6D/kXRt2Opz2tXWuLhY1I8r0AViuvkdEqUg/FQNqeIvRmH2+/+HfMBaGScrm6qK aw0qJe1bdyUIctuxjA6HZaKReEUnhtJp2854DK0MV6SIUSHyVRnWOcXOiSSt4lbJM9W5 HqKIyOPOy0fASyJgv7Av2G4CLYtKdpZ3pqtLCzvR1UvRWD+a/NpZMKDXqZNnxhP2ZFlC vzpiZh7hMt0kXeif2xwHpvBt0TIppJ90AYo/FyjlUwN+HF+PNei3X1zwudscY+CwaYMM s/zQ== X-Gm-Message-State: APjAAAVKtHG0ZqWxIELeSW4ImslDmh/O8F5ZHOcWrx484tmpMcp7T+u/ XlQwkYJCGp4obD1I8NSKXxZbtLUDcpg= X-Received: by 2002:a17:90a:b30b:: with SMTP id d11mr6814381pjr.22.1581449148710; Tue, 11 Feb 2020 11:25:48 -0800 (PST) Received: from www.outflux.net (smtp.outflux.net. [198.145.64.163]) by smtp.gmail.com with ESMTPSA id 3sm4285511pjg.27.2020.02.11.11.25.47 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 11 Feb 2020 11:25:47 -0800 (PST) Date: Tue, 11 Feb 2020 11:25:46 -0800 From: Kees Cook To: shuah Cc: Ingo Molnar , Hector Marco-Gisbert , Catalin Marinas , Will Deacon , Jason Gunthorpe , Jann Horn , Russell King , x86@kernel.org, kernel-hardening@lists.openwall.com, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, linux-kselftest@vger.kernel.org Subject: Re: [PATCH v3 7/7] selftests/exec: Add READ_IMPLIES_EXEC tests Message-ID: <202002111124.0A334167@keescook> References: <20200210193049.64362-1-keescook@chromium.org> <20200210193049.64362-8-keescook@chromium.org> <4f8a5036-dc2a-90ad-5fc8-69560a5dd78e@kernel.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <4f8a5036-dc2a-90ad-5fc8-69560a5dd78e@kernel.org> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Feb 11, 2020 at 11:11:21AM -0700, shuah wrote: > On 2/10/20 12:30 PM, Kees Cook wrote: > > In order to check the matrix of possible states for handling > > READ_IMPLIES_EXEC across native, compat, and the state of PT_GNU_STACK, > > add tests for these execution conditions. > > > > Signed-off-by: Kees Cook > > No issues for this to go through tip. > > A few problems to fix first. This fails to compile when 32-bit libraries > aren't installed. It should fail the 32-bit part and run other checks. Do you mean the Makefile should detect the missing compat build deps and avoid building them? Testing compat is pretty important to this test, so it seems like missing the build deps causing the build to fail is the correct action here. This is likely true for the x86/ selftests too. What would you like this to do? -- Kees Cook