Received: by 2002:a05:6358:3188:b0:123:57c1:9b43 with SMTP id q8csp1189115rwd; Tue, 16 May 2023 13:11:04 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ6ncsDgy8GvRT46u5G6sA4c/+fsY5P1Kf2lEwsXhk9N0FqRQLtfKfIoqDn2sE5JwJxopiPu X-Received: by 2002:a17:902:c40d:b0:1ab:2034:26da with SMTP id k13-20020a170902c40d00b001ab203426damr50406064plk.51.1684267864079; Tue, 16 May 2023 13:11:04 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1684267864; cv=none; d=google.com; s=arc-20160816; b=XHdmxqIthEb1AzGbYw66GParx44LLp+p0AqRjKYrvRy3lRsgla3J5VLTsdEoipqbAL U6apE4SBJTY3aVfwSQiY4EgVy5Uocxz8qwL/NYisV/LwOtPrlrOuidh6tvtG+WwpdYIB +CdAIaHLYA//4C2vmaZrw1MbWjwAx85ixvbVQ8bkXMkJkUxCaX+gVVTCijUzWXrNEbCS wqJoiB3CbZ3+NlOtxRwzZ8KtszJP2a9MGXZbG/6GrHB3sFk0EdfWoeeRuGOK1POAloYH 1hIbPpb6sWTkU24V20hRVW/35LtH1+ZMzdJ2lG+yylt97Yxb7MRj7zWlDSyKFNnvo4W8 rFbA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=5yK4aZqvfgO0WJ8XP2YQsUwZXdAoZzrxUjN80rlLt4Q=; b=ePhwKf74GuhZSQ54Igy2uS35QtsAv9mDt009mSLC/zqvHJ2l0Z2tYmjiMjQVDHbLx2 GpPTb3vKyeeJ+xvbdlNtTHwlOsTf4oOq8piB3Q4Hcj/qZMxdpcj1R5OAhNn2sbRXIZpF XWMYMn6LyhI6t/A4WePqthBA0NSQO8KFXgXmL/M1AUgDJTeaercvB1WQ1TLaD5xgEUFR 7Sv8r7MGW9E1DXlenhQxTIGDyV0zPNj2AzriBTyhnWedZxZxd4bWqtl8aeEzLVwovPhs CqnPvi4uaoyRvcu4C+9r7S2T0L3arqpcklsLh/HmYPY/yH1BJ5WIZQmoYWuDn9BcSAPV AYig== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@chromium.org header.s=google header.b=n+n0N1x1; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 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 out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id g21-20020a170902869500b001a63b045c86si18302352plo.10.2023.05.16.13.10.49; Tue, 16 May 2023 13:11:04 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@chromium.org header.s=google header.b=n+n0N1x1; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 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 S229705AbjEPUHn (ORCPT + 99 others); Tue, 16 May 2023 16:07:43 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:57478 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229460AbjEPUHm (ORCPT ); Tue, 16 May 2023 16:07:42 -0400 Received: from mail-pl1-x631.google.com (mail-pl1-x631.google.com [IPv6:2607:f8b0:4864:20::631]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 6A9786EBB for ; Tue, 16 May 2023 13:07:40 -0700 (PDT) Received: by mail-pl1-x631.google.com with SMTP id d9443c01a7336-1ae3fe67980so777825ad.3 for ; Tue, 16 May 2023 13:07:40 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; t=1684267660; x=1686859660; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:from:to:cc:subject:date:message-id:reply-to; bh=5yK4aZqvfgO0WJ8XP2YQsUwZXdAoZzrxUjN80rlLt4Q=; b=n+n0N1x1kTOQTXTYpkicsApchyuKJU6rIqOVr/nfeik1SxnFwCdYu5J+Ma2kGNR592 GmeMv+aGpBEWPX5873vshFxa6mCp2oj/97to3/3iWUtqRKhDbg7Z+FErMibpYj5M7orE WEN8nXBaRrWCplSX+wTveuOU4SzH9b4zVDJwk= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1684267660; x=1686859660; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=5yK4aZqvfgO0WJ8XP2YQsUwZXdAoZzrxUjN80rlLt4Q=; b=jIrrki/ZA3zxOUkg8pOmJ8AMO3UPNlco6Qb2FtO1Dsrcoi6rAB9mfIEA2gges0gSPl JkW1r6f/T+fE969DJ1AY3+3HqU75GZag8UhgUi4xCbfQENxigdCMshXZGtQ9O5/ul2I0 +mTOtduZ2y+SHHTFxF3RBYLbCjdE+KJkepegqFBxhGaFeM1hHkcV7fz1SqvxJWDwX7LL MXtxvVhFbjqCT/1OILQnMWdBOzxajtJEiN8vmGPEZf//A5jNCGBi87mjwNw/FU78onqi 5LN0IR1eREHLfXjeQI+6xD4/2IARIi4Tyiz6UFDPb6yv5qxO95yBB6s86uA3jsyx01lo CJtQ== X-Gm-Message-State: AC+VfDxZCTW8c0BjGRhX0dkFcvsU6xS5GQ39NMeZCaIOzBUToeGXyxeM 9qCmEvP8qMTGVTlcJmFisVQMWw== X-Received: by 2002:a17:902:cec8:b0:1ad:c736:2090 with SMTP id d8-20020a170902cec800b001adc7362090mr24149254plg.3.1684267659998; Tue, 16 May 2023 13:07:39 -0700 (PDT) Received: from www.outflux.net (198-0-35-241-static.hfc.comcastbusiness.net. [198.0.35.241]) by smtp.gmail.com with ESMTPSA id g7-20020a170902868700b001a64c4023aesm15911708plo.36.2023.05.16.13.07.39 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 16 May 2023 13:07:39 -0700 (PDT) Date: Tue, 16 May 2023 13:07:39 -0700 From: Kees Cook To: jeffxu@chromium.org Cc: dave.hansen@intel.com, luto@kernel.org, jorgelo@chromium.org, groeck@chromium.org, jannh@google.com, sroettger@google.com, akpm@linux-foundation.org, jeffxu@google.com, linux-kernel@vger.kernel.org, linux-kselftest@vger.kernel.org, linux-mm@kvack.org, linux-hardening@vger.kernel.org Subject: Re: [PATCH 3/6] PKEY: Apply PKEY_ENFORCE_API to mprotect Message-ID: <202305161307.77B29D261@keescook> References: <20230515130553.2311248-1-jeffxu@chromium.org> <20230515130553.2311248-4-jeffxu@chromium.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20230515130553.2311248-4-jeffxu@chromium.org> X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE,URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, May 15, 2023 at 01:05:49PM +0000, jeffxu@chromium.org wrote: > From: Jeff Xu > > This patch enables PKEY_ENFORCE_API for the mprotect and > mprotect_pkey syscalls. All callers are from userspace -- this change looks like a no-op? -Kees -- Kees Cook