From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 54961392829; Tue, 12 May 2026 08:51:25 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1778575885; cv=none; b=AfEthh0db28xeLBHK1oYREWvwB66jBjyakufVFh8GtXR0+Mi8cjgEwkd2vzwtfOvMtbGfOG6U3Nw7cH6VQokxEiraOii900lSV72kAmdshQ9jh1zhQrWYTLhZ4/NUMeC+poF0YNXlglq4IdukrDPB+PKxMqjmn0Zgl7WELeBeoA= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1778575885; c=relaxed/simple; bh=Wt32r9HqTnmChyHNUvyBHP0cnR5+BSMvmBHSczvrJoc=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=StqXp7FxXpFY0/LnprFnqSDphyOiPAOkuXqY6GnoZQ86Ct5xu1VmqM93r4FqM2VdT1CK86WzpNEzv6HJ7PX9wDQZB1hHHJe2Qq2u4SHZJp60WRyOq/x1dQ2xiaOQLSuckz+WGQUFx4sIeWy/I/BJ0dgSqfsdO9sjWeiVS33TEPo= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=gpVwbLMw; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="gpVwbLMw" Received: by smtp.kernel.org (Postfix) with ESMTPSA id C7B5CC2BCB0; Tue, 12 May 2026 08:51:23 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1778575884; bh=Wt32r9HqTnmChyHNUvyBHP0cnR5+BSMvmBHSczvrJoc=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=gpVwbLMwNfdLpdSY7fNpWhpdW/X5XTGl0Oeb8wUNbwBSpkUthjBoWYQeNh48cWMZ5 goDoE0i3QnfiRzR+2MJq6c0MQIWWK3xM7ROSMekRm12lBmvaXyE43pZih47ptZ9R+S PDdULsdVV7kwx9lNWNz5zMgwdTBQHdY/5cmqr1BjPvxXIiMDyqNd/Mq1PXlbAx0MfV Mk6uHGyhGluXCTdftSM1NPR5c7VN+aW/QekePdpHiEHsmHReAbVmshmE/Jj5WmkffZ rxnDddH520MD51johZ9H444ms3wVVgMAIy039yiMXyqYoznak8DKUlwQJieJM4ablg tUzJyKrgr7+5w== Date: Tue, 12 May 2026 11:51:18 +0300 From: Leon Romanovsky To: Paul Moore Cc: Jason Gunthorpe , Roberto Sassu , KP Singh , Matt Bobrowski , Alexei Starovoitov , Daniel Borkmann , John Fastabend , Andrii Nakryiko , Martin KaFai Lau , Eduard Zingerman , Song Liu , Yonghong Song , Stanislav Fomichev , Hao Luo , Jiri Olsa , Shuah Khan , Saeed Mahameed , Itay Avraham , Dave Jiang , Jonathan Cameron , bpf@vger.kernel.org, linux-kernel@vger.kernel.org, linux-kselftest@vger.kernel.org, linux-rdma@vger.kernel.org, Chiara Meiohas , Maher Sanalla , linux-security-module@vger.kernel.org Subject: Re: [PATCH v2 0/4] Firmware LSM hook Message-ID: <20260512085118.GP15586@unreal> References: <20260413231920.GS3694781@ziepe.ca> <20260415134705.GG2577880@ziepe.ca> <20260417191749.GK2577880@ziepe.ca> <20260424143603.GB3611611@ziepe.ca> <20260424221310.GA804026@ziepe.ca> Precedence: bulk X-Mailing-List: linux-rdma@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: On Mon, May 04, 2026 at 06:33:45PM -0400, Paul Moore wrote: > On Fri, Apr 24, 2026 at 6:13 PM Jason Gunthorpe wrote: > > > > ... I wonder if we are even speaking the same language. > > Let's reset the conversation. > > As I understand it, based on our discussion in this thread and Leon's > previous patchsets, the basic idea is to enable LSMs to enforce access > control over fwctl requests/commands sent from userspace. I'm going > to start with that as a basis. Yes, we proposed two users: FWCTL and RDMA DevX. Both are relevant, but FWCTL is the higher priority. > > Using the kernel's docs on fwctl, the userspace API appears to consist > mostly of ioctls with some basic sysfs interfaces. It looks like we > can mostly ignore the sysfs interface and focus on the ioctl side of > the API, do you agree? Yes, all FW commands are routed through ioctls. > > https://docs.kernel.org/userspace-api/fwctl/fwctl.html > > While normally I would suggest simply using the existing > security_file_ioctl() hook, Leon previously mentioned that the hook is > too early for fwctl as the userspace copy happens much later. I talked about general verbs interface in RDMA. Thanks