diff options
| author | Rick Macklem <rmacklem@FreeBSD.org> | 2025-12-31 02:43:23 +0000 |
|---|---|---|
| committer | Rick Macklem <rmacklem@FreeBSD.org> | 2025-12-31 02:43:23 +0000 |
| commit | e8567de718a4a16edbf5490e1c36360563e16667 (patch) | |
| tree | 5e09bddcb246d67111e6a6997edd0f44327a9295 | |
| parent | 4fecc8e3fe9408621429777b1028c9afb83c3925 (diff) | |
nfscl: Fix handling of POSIX draft default ACLs
A POSIX draft default ACL may not exist. As such,
an ACL with zero ACEs needs to be allowed.
This patch fixes acquisition of POSIX draft default
ACLs when they do not exist on the directory.
Fixes: a35bbd5d9f5f ("nfscommon: Add some support for POSIX draft ACLs")
| -rw-r--r-- | sys/fs/nfsclient/nfs_clvnops.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/sys/fs/nfsclient/nfs_clvnops.c b/sys/fs/nfsclient/nfs_clvnops.c index 7484a5a7e082..1bd77ab27ced 100644 --- a/sys/fs/nfsclient/nfs_clvnops.c +++ b/sys/fs/nfsclient/nfs_clvnops.c @@ -3779,7 +3779,8 @@ nfs_getacl(struct vop_getacl_args *ap) return (EINVAL); error = nfsrpc_getacl(ap->a_vp, ap->a_type, ap->a_cred, ap->a_td, ap->a_aclp); - if (error == 0 && ap->a_aclp->acl_cnt == 0) + if (error == 0 && ap->a_aclp->acl_cnt == 0 && + ap->a_type != ACL_TYPE_DEFAULT) return (EOPNOTSUPP); if (error > NFSERR_STALE) { (void) nfscl_maperr(ap->a_td, error, (uid_t)0, (gid_t)0); |
