From nobody Mon Dec 27 16:06:58 2021 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 6522C1900094; Mon, 27 Dec 2021 16:06:59 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4JN2c313h4z4pYl; Mon, 27 Dec 2021 16:06:59 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 0056020BE8; Mon, 27 Dec 2021 16:06:58 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.16.1/8.16.1) with ESMTP id 1BRG6w7N085184; Mon, 27 Dec 2021 16:06:58 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 1BRG6wvS085183; Mon, 27 Dec 2021 16:06:58 GMT (envelope-from git) Date: Mon, 27 Dec 2021 16:06:58 GMT Message-Id: <202112271606.1BRG6wvS085183@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Rick Macklem Subject: git: f10dc28ec21d - main - nfscommon: Return NFSERR_ATTRNOTSUPP for AUDIT/ALARM ACEs List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-all@freebsd.org X-BeenThere: dev-commits-src-all@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: rmacklem X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: f10dc28ec21db60cf1faa3c4b445c4065e760dba Auto-Submitted: auto-generated ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1640621219; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=ml6T0uXlXcj3usJtxiAKFyQ6jvJbxMC+kRHqnmMuRLs=; b=dlVP4wijTb5CkNVJXiL7AqHBK6SXW2PPHnQ4kIEOsAi6cCo3IilqC5NcNty1xMMF7gZbsy kN78+8Lne2l7kLdM4HtIs4D0c6JMzmsYkOhB8ZqJVsK27NJie/r4shzNkXn5LaGOV2a1wM zovP5Hh8bOQH3OSYKC7zsQc3izn7a5IYs86P6+i+sVfojIJDW63PsetQKUH21TOQbXyHnT 4TlW6pn7Isci7MRCW1bIDyop6yvWqo0tr5amVxy9PJ8SSBDHpDNg5G45D5Lp5JbbCiSxkl oag/FcamX9jQLs9WrGn8TrUi/W+5Iq4w2RtT3y2byylEdDG0pF6263n4pzj5ZQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1640621219; a=rsa-sha256; cv=none; b=aceD8SZBr0OtPjvFOpwAVl1/vhFYdKkWr2tEI5vbMn5ojgqG0pqFCLe1saID3FeHRPbGXh w++YPPsT/y3bJ3muY8AGw/SRkvJjJ4F+FIqlzdsjLbsao9pKFiK2QXD1v4MQsFYZ4jKdZ8 r8nXpeUg4FWXdERd0dXCs6b5XfUjvWnC3/X0IrPtO2jnZGSp6S1y0xnziLR5QHpIbJiSN6 vT7EnUpQdcae45WjWu4SnJHv7H+5CttSlOCeKhFL3HyxJTjJqw7mumOe0+5BrQ1nkfBMYX 9zkSbqzO/AFzSbs+H7PFsh9I+HDTYLtmzpe7RHSY6h5Rfwhc81JV8dsvGIAmsg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none X-ThisMailContainsUnwantedMimeParts: N The branch main has been updated by rmacklem: URL: https://cgit.FreeBSD.org/src/commit/?id=f10dc28ec21db60cf1faa3c4b445c4065e760dba commit f10dc28ec21db60cf1faa3c4b445c4065e760dba Author: Rick Macklem AuthorDate: 2021-12-27 16:03:41 +0000 Commit: Rick Macklem CommitDate: 2021-12-27 16:03:41 +0000 nfscommon: Return NFSERR_ATTRNOTSUPP for AUDIT/ALARM ACEs FreeBSD only supports Allow/Deny ACEs in NFSv4 ACLs. As such, it does not make sense to parse Audit/Alarm ACEs. Modify nfsrv_dissectace() so that it returns NFSERR_ATTRNOTSUPP if an Audit/Alarm ACE is found in the ACL being parsed. The code has been #ifdef notnow'd, since Audit/Alarm ACEs might be supported someday. This should not have significant impact, since FreeBSD reports to clients that only Allow/Deny ACEs are supported and an attempt to set one would have failed anyhow. MFC after: 2 weeks --- sys/fs/nfs/nfs_commonacl.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/sys/fs/nfs/nfs_commonacl.c b/sys/fs/nfs/nfs_commonacl.c index e3583b273db8..057efdfbc29c 100644 --- a/sys/fs/nfs/nfs_commonacl.c +++ b/sys/fs/nfs/nfs_commonacl.c @@ -158,10 +158,13 @@ nfsrv_dissectace(struct nfsrv_descript *nd, struct acl_entry *acep, acep->ae_entry_type = ACL_ENTRY_TYPE_ALLOW; else if (acetype == NFSV4ACE_DENIEDTYPE) acep->ae_entry_type = ACL_ENTRY_TYPE_DENY; +#ifdef notnow + /* FreeBSD does not support Audit/Alarm ACEs at this time. */ else if (acetype == NFSV4ACE_AUDITTYPE) acep->ae_entry_type = ACL_ENTRY_TYPE_AUDIT; else if (acetype == NFSV4ACE_ALARMTYPE) acep->ae_entry_type = ACL_ENTRY_TYPE_ALARM; +#endif else aceerr = NFSERR_ATTRNOTSUPP; }