From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from firstgate.proxmox.com (firstgate.proxmox.com [212.224.123.68]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by lists.proxmox.com (Postfix) with ESMTPS id 5ACED94E27 for ; Mon, 16 Jan 2023 16:46:24 +0100 (CET) Received: from firstgate.proxmox.com (localhost [127.0.0.1]) by firstgate.proxmox.com (Proxmox) with ESMTP id 396D31935 for ; Mon, 16 Jan 2023 16:45:54 +0100 (CET) Received: from proxmox-new.maurer-it.com (proxmox-new.maurer-it.com [94.136.29.106]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by firstgate.proxmox.com (Proxmox) with ESMTPS for ; Mon, 16 Jan 2023 16:45:53 +0100 (CET) Received: from proxmox-new.maurer-it.com (localhost.localdomain [127.0.0.1]) by proxmox-new.maurer-it.com (Proxmox) with ESMTP id D09F644E3E for ; Mon, 16 Jan 2023 16:45:52 +0100 (CET) Message-ID: Date: Mon, 16 Jan 2023 16:45:52 +0100 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:109.0) Gecko/20100101 Thunderbird/109.0 Content-Language: en-GB To: Proxmox VE development discussion , Markus Frank References: <20221223131007.130310-1-m.frank@proxmox.com> <20221223131007.130310-3-m.frank@proxmox.com> From: Thomas Lamprecht In-Reply-To: <20221223131007.130310-3-m.frank@proxmox.com> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-SPAM-LEVEL: Spam detection results: 0 AWL 0.011 Adjusted score from AWL reputation of From: address BAYES_00 -1.9 Bayes spam probability is 0 to 1% KAM_DMARC_STATUS 0.01 Test Rule for DKIM or SPF Failure with Strict Alignment NICE_REPLY_A -0.097 Looks like a legit reply (A) SPF_HELO_NONE 0.001 SPF: HELO does not publish an SPF Record SPF_PASS -0.001 SPF: sender matches SPF record Subject: Re: [pve-devel] [PATCH access-control v2 2/6] added acls for Shared Filesystem Directories X-BeenThere: pve-devel@lists.proxmox.com X-Mailman-Version: 2.1.29 Precedence: list List-Id: Proxmox VE development discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 16 Jan 2023 15:46:24 -0000 Am 23/12/2022 um 14:10 schrieb Markus Frank: > Signed-off-by: Markus Frank > --- > src/PVE/AccessControl.pm | 2 ++ > src/PVE/RPCEnvironment.pm | 12 +++++++++++- > 2 files changed, 13 insertions(+), 1 deletion(-) >=20 > diff --git a/src/PVE/AccessControl.pm b/src/PVE/AccessControl.pm > index a95d072..742304c 100644 > --- a/src/PVE/AccessControl.pm > +++ b/src/PVE/AccessControl.pm > @@ -1221,6 +1221,8 @@ sub check_path { > |/storage/[[:alnum:]\.\-\_]+ > |/vms > |/vms/[1-9][0-9]{2,} > + |/dirs > + |/dirs/[[:alnum:]\.\-\_]+ I do not like this too much, iff we expose this at the ACL level I'd rath= er like to use a /map// path, as we need that for Dominik's HW (PCI(e)) ma= ppings anyway, and I think we could reuse such a mapping ACL object path for even more t= hings (e.g., VMID (allocation) ranges, CPU cores (for cpu task set/pinning), ... Besides that, note that our access model normally adds privileges based o= f the top-level ACL object path, with the fitting roles - e.g., here that could be Dirs.A= udit, Dirs.Modify Dirs.Use =E2=80=93 but with above it will then naturally something like M= ap.Audit, Map.Modify, Map.Use.