Home
last modified time | relevance | path

Searched refs:aclp (Results 1 – 25 of 39) sorted by relevance

12

/freebsd/lib/libc/posix1e/
H A Dacl_get.c59 acl_t aclp; in acl_get_file() local
62 aclp = acl_init(ACL_MAX_ENTRIES); in acl_get_file()
63 if (aclp == NULL) in acl_get_file()
67 error = __acl_get_file(path_p, type, &aclp->ats_acl); in acl_get_file()
69 acl_free(aclp); in acl_get_file()
73 aclp->ats_acl.acl_maxcnt = ACL_MAX_ENTRIES; in acl_get_file()
74 _acl_brand_from_type(aclp, type); in acl_get_file()
76 return (aclp); in acl_get_file()
82 acl_t aclp; in acl_get_link_np() local
85 aclp = acl_init(ACL_MAX_ENTRIES); in acl_get_link_np()
[all …]
H A Dacl_strip.c41 void acl_nfs4_sync_mode_from_acl(mode_t *_mode, const struct acl *aclp);
42 void acl_nfs4_trivial_from_mode_libc(struct acl *aclp, int file_owner_id,
46 _nfs4_acl_strip_np(const acl_t aclp, int canonical_six) in _nfs4_acl_strip_np() argument
59 acl_nfs4_sync_mode_from_acl(&mode, &(aclp->ats_acl)); in _nfs4_acl_strip_np()
66 _posix1e_acl_strip_np(const acl_t aclp, int recalculate_mask) in _posix1e_acl_strip_np() argument
73 assert(_acl_brand(aclp) == ACL_BRAND_POSIX); in _posix1e_acl_strip_np()
75 acl_old = acl_dup(aclp); in _posix1e_acl_strip_np()
134 acl_strip_np(const acl_t aclp, int recalculate_mask) in acl_strip_np() argument
136 switch (_acl_brand(aclp)) { in acl_strip_np()
138 return (_nfs4_acl_strip_np(aclp, 0)); in acl_strip_np()
[all …]
H A Dacl_branding.c50 acl_t aclp; in entry2acl() local
52 aclp = (acl_t)(((long)entry >> _ACL_T_ALIGNMENT_BITS) << _ACL_T_ALIGNMENT_BITS); in entry2acl()
54 return (aclp); in entry2acl()
H A Dacl_from_text.c48 int _nfs4_acl_entry_from_text(acl_t aclp, char *entry);
81 _posix1e_acl_entry_from_text(acl_t aclp, char *entry) in _posix1e_acl_entry_from_text() argument
89 assert(_acl_brand(aclp) == ACL_BRAND_POSIX); in _posix1e_acl_entry_from_text()
159 error = _posix1e_acl_add_entry(aclp, t, id, p); in _posix1e_acl_entry_from_text()
H A Dacl_to_text_nfs4.c229 _nfs4_acl_to_text_np(const acl_t aclp, ssize_t *len_p, int flags) in _nfs4_acl_to_text_np() argument
235 if (aclp->ats_acl.acl_cnt == 0) in _nfs4_acl_to_text_np()
238 size = aclp->ats_acl.acl_cnt * MAX_ENTRY_LENGTH; in _nfs4_acl_to_text_np()
243 while (acl_get_entry(aclp, entry_id, &entry) == 1) { in _nfs4_acl_to_text_np()
H A Dacl_from_text_nfs4.c200 _nfs4_acl_entry_from_text(acl_t aclp, char *str) in _nfs4_acl_entry_from_text() argument
206 error = acl_create_entry(&aclp, &entry); in _nfs4_acl_entry_from_text()
278 acl_delete_entry(aclp, entry); in _nfs4_acl_entry_from_text()
/freebsd/sys/contrib/openzfs/module/os/freebsd/zfs/
H A Dzfs_acl.c456 zfs_acl_t *aclp; in zfs_acl_alloc() local
458 aclp = kmem_zalloc(sizeof (zfs_acl_t), KM_SLEEP); in zfs_acl_alloc()
459 list_create(&aclp->z_acl, sizeof (zfs_acl_node_t), in zfs_acl_alloc()
461 aclp->z_version = vers; in zfs_acl_alloc()
463 aclp->z_ops = &zfs_acl_fuid_ops; in zfs_acl_alloc()
465 aclp->z_ops = &zfs_acl_v0_ops; in zfs_acl_alloc()
466 return (aclp); in zfs_acl_alloc()
494 zfs_acl_release_nodes(zfs_acl_t *aclp) in zfs_acl_release_nodes() argument
498 while ((aclnode = list_remove_head(&aclp->z_acl))) in zfs_acl_release_nodes()
500 aclp->z_acl_count = 0; in zfs_acl_release_nodes()
[all …]
/freebsd/sys/contrib/openzfs/module/os/linux/zfs/
H A Dzfs_acl.c454 zfs_acl_t *aclp; in zfs_acl_alloc() local
456 aclp = kmem_zalloc(sizeof (zfs_acl_t), KM_SLEEP); in zfs_acl_alloc()
457 list_create(&aclp->z_acl, sizeof (zfs_acl_node_t), in zfs_acl_alloc()
459 aclp->z_version = vers; in zfs_acl_alloc()
461 aclp->z_ops = &zfs_acl_fuid_ops; in zfs_acl_alloc()
463 aclp->z_ops = &zfs_acl_v0_ops; in zfs_acl_alloc()
464 return (aclp); in zfs_acl_alloc()
492 zfs_acl_release_nodes(zfs_acl_t *aclp) in zfs_acl_release_nodes() argument
496 while ((aclnode = list_remove_head(&aclp->z_acl))) in zfs_acl_release_nodes()
498 aclp->z_acl_count = 0; in zfs_acl_release_nodes()
[all …]
H A Dzfs_vnops_os.c1936 zfs_acl_t *aclp; in zfs_setattr() local
2050 aclp = NULL; in zfs_setattr()
2343 if ((err = zfs_acl_chmod_setattr(zp, &aclp, new_mode))) in zfs_setattr()
2358 0, aclp->z_acl_bytes); in zfs_setattr()
2361 aclp->z_acl_bytes); in zfs_setattr()
2363 } else if (!zp->z_is_sa && aclp->z_acl_bytes > ZFS_ACE_SPACE) { in zfs_setattr()
2365 0, aclp->z_acl_bytes); in zfs_setattr()
2489 ASSERT3P(aclp, !=, NULL); in zfs_setattr()
2490 err = zfs_aclset_common(zp, aclp, cr, tx); in zfs_setattr()
2494 zp->z_acl_cached = aclp; in zfs_setattr()
[all …]
/freebsd/sys/kern/
H A Dsubr_acl_nfs4.c59 static void acl_nfs4_trivial_from_mode(struct acl *aclp, mode_t mode);
109 _acl_denies(const struct acl *aclp, int access_mask, struct ucred *cred, in _acl_denies() argument
118 KASSERT(aclp->acl_cnt <= ACL_MAX_ENTRIES, in _acl_denies()
121 for (i = 0; i < aclp->acl_cnt; i++) { in _acl_denies()
122 entry = &(aclp->acl_entry[i]); in _acl_denies()
172 struct acl *aclp, accmode_t accmode, struct ucred *cred) in vaccess_acl_nfs4() argument
221 denied = _acl_denies(aclp, access_mask, cred, file_uid, file_gid, in vaccess_acl_nfs4()
235 acl_nfs4_sync_mode_from_acl(&file_mode, aclp); in vaccess_acl_nfs4()
321 _acl_append(struct acl *aclp, acl_tag_t tag, acl_perm_t perm, in _acl_append() argument
326 KASSERT(aclp->acl_cnt + 1 <= ACL_MAX_ENTRIES, in _acl_append()
[all …]
H A Dvfs_acl.c67 acl_type_t type, struct acl *aclp, int follow);
71 acl_type_t type, struct acl *aclp, int follow);
73 acl_type_t type, const struct acl *aclp, int follow);
75 acl_type_t type, const struct acl *aclp);
77 acl_type_t type, struct acl *aclp);
79 acl_type_t type, const struct acl *aclp);
225 const struct acl *aclp) in vacl_set_acl() argument
233 error = acl_copyin(aclp, inkernelacl, type); in vacl_set_acl()
263 struct acl *aclp) in vacl_get_acl() argument
285 error = acl_copyout(inkernelacl, aclp, type); in vacl_get_acl()
[all …]
/freebsd/sys/contrib/openzfs/module/os/freebsd/spl/
H A Dspl_acl.c101 acl_from_aces(struct acl *aclp, const ace_t *aces, int nentries) in acl_from_aces() argument
122 memset(aclp, 0, sizeof (*aclp)); in acl_from_aces()
123 aclp->acl_maxcnt = ACL_MAX_ENTRIES; in acl_from_aces()
124 aclp->acl_cnt = nentries; in acl_from_aces()
127 entry = &(aclp->acl_entry[i]); in acl_from_aces()
171 aces_from_acl(ace_t *aces, int *nentries, const struct acl *aclp) in aces_from_acl() argument
177 memset(aces, 0, sizeof (*aces) * aclp->acl_cnt); in aces_from_acl()
179 *nentries = aclp->acl_cnt; in aces_from_acl()
181 for (i = 0; i < aclp->acl_cnt; i++) { in aces_from_acl()
182 entry = &(aclp->acl_entry[i]); in aces_from_acl()
H A Dacl_common.c234 acl_t *aclp; in acl_alloc() local
236 if (cacl_malloc((void **)&aclp, sizeof (acl_t)) != 0) in acl_alloc()
239 aclp->acl_aclp = NULL; in acl_alloc()
240 aclp->acl_cnt = 0; in acl_alloc()
244 aclp->acl_type = ACE_T; in acl_alloc()
245 aclp->acl_entry_size = sizeof (ace_t); in acl_alloc()
248 aclp->acl_type = ACLENT_T; in acl_alloc()
249 aclp->acl_entry_size = sizeof (aclent_t); in acl_alloc()
252 acl_free(aclp); in acl_alloc()
253 aclp = NULL; in acl_alloc()
[all …]
/freebsd/sys/cddl/compat/opensolaris/kern/
H A Dopensolaris_acl.c100 acl_from_aces(struct acl *aclp, const ace_t *aces, int nentries) in acl_from_aces() argument
121 bzero(aclp, sizeof(*aclp)); in acl_from_aces()
122 aclp->acl_maxcnt = ACL_MAX_ENTRIES; in acl_from_aces()
123 aclp->acl_cnt = nentries; in acl_from_aces()
126 entry = &(aclp->acl_entry[i]); in acl_from_aces()
170 aces_from_acl(ace_t *aces, int *nentries, const struct acl *aclp) in aces_from_acl() argument
176 bzero(aces, sizeof(*aces) * aclp->acl_cnt); in aces_from_acl()
178 *nentries = aclp->acl_cnt; in aces_from_acl()
180 for (i = 0; i < aclp->acl_cnt; i++) { in aces_from_acl()
181 entry = &(aclp->acl_entry[i]); in aces_from_acl()
/freebsd/sys/ufs/ufs/
H A Dufs_acl.c155 ufs_getacl_nfs4_internal(struct vnode *vp, struct acl *aclp, struct thread *td) in ufs_getacl_nfs4_internal() argument
160 len = sizeof(*aclp); in ufs_getacl_nfs4_internal()
161 bzero(aclp, len); in ufs_getacl_nfs4_internal()
165 &len, (char *) aclp, td); in ufs_getacl_nfs4_internal()
166 aclp->acl_maxcnt = ACL_MAX_ENTRIES; in ufs_getacl_nfs4_internal()
172 acl_nfs4_sync_acl_from_mode(aclp, ip->i_mode, ip->i_uid); in ufs_getacl_nfs4_internal()
180 if (len != sizeof(*aclp)) { in ufs_getacl_nfs4_internal()
194 error = acl_nfs4_check(aclp, vp->v_type == VDIR); in ufs_getacl_nfs4_internal()
374 ufs_setacl_nfs4_internal(struct vnode *vp, struct acl *aclp, struct thread *td) in ufs_setacl_nfs4_internal() argument
380 KASSERT(acl_nfs4_check(aclp, vp->v_type == VDIR) == 0, in ufs_setacl_nfs4_internal()
[all …]
H A Dacl.h42 int ufs_getacl_nfs4_internal(struct vnode *vp, struct acl *aclp,
44 int ufs_setacl_nfs4_internal(struct vnode *vp, struct acl *aclp,
/freebsd/contrib/libarchive/libarchive/test/
H A Dtest_acl_platform_posix1e.c221 void *aclp, int aclcnt,
251 acl_entry = &((aclent_t *)aclp)[e];
299 void *aclp;
335 aclp = sunacl_get(GETACL, &aclcnt, 0, "test0");
337 assert(aclp != NULL);
344 compare_acls(aclp, aclcnt, acls2, sizeof(acls2)/sizeof(acls2[0]));
345 free(aclp);
346 aclp = NULL;
369 void *aclp;
418 aclp
222 compare_acls(void * aclp,int aclcnt,struct archive_test_acl_t * myacls,int n) global() argument
[all...]
H A Dtest_acl_platform_nfs4.c684 void *aclp, in compare_acls()
714 if (aclp == NULL) in compare_acls()
748 acl_entry = &((ace_t *)aclp)[e]; in compare_acls()
867 void *aclp; in DEFINE_TEST()
928 aclp = sunacl_get(ACE_GETACL, &aclcnt, 0, "testall"); in DEFINE_TEST()
931 assert(aclp != NULL); in DEFINE_TEST()
948 compare_acls(aclp, aclcnt, acls_reg, "testall", 0, regcnt); in DEFINE_TEST()
949 free(aclp); in DEFINE_TEST()
950 aclp = NULL; in DEFINE_TEST()
966 aclp in DEFINE_TEST()
685 compare_acls(void * aclp,int aclcnt,struct myacl_t * myacls,const char * filename,int start,int end) compare_acls() argument
[all...]
/freebsd/sys/fs/nfs/
H A Dnfs_commonacl.c394 nfsrv_buildacl(struct nfsrv_descript *nd, NFSACL_T *aclp, __enum_uint8(vtype) type, in nfsrv_buildacl() argument
407 for (i = 0; i < aclp->acl_cnt; i++) { in nfsrv_buildacl()
409 switch (aclp->acl_entry[i].ae_tag) { in nfsrv_buildacl()
426 nfsv4_uidtostr(aclp->acl_entry[i].ae_id, &name, in nfsrv_buildacl()
434 nfsv4_gidtostr((gid_t)aclp->acl_entry[i].ae_id, &name, in nfsrv_buildacl()
443 isowner, &aclp->acl_entry[i]); in nfsrv_buildacl()
/freebsd/sys/contrib/openzfs/include/os/freebsd/spl/acl/
H A Dacl_common.h54 extern void acl_free(acl_t *aclp);
55 extern int acl_translate(acl_t *aclp, int target_flavor, boolean_t isdir,
/freebsd/sys/sys/
H A Dacl.h300 void acl_free(struct acl *aclp);
302 void acl_nfs4_sync_acl_from_mode(struct acl *aclp,
305 const struct acl *aclp);
306 int acl_nfs4_is_trivial(const struct acl *aclp,
325 int acl_nfs4_check(const struct acl *aclp, int is_directory);
/freebsd/contrib/llvm-project/compiler-rt/include/sanitizer/
H A Dnetbsd_syscall_hooks.h2761 #define __sanitizer_syscall_pre___acl_get_link(path, type, aclp) \ argument
2763 (long long)(path), (long long)(type), (long long)(aclp))
2764 #define __sanitizer_syscall_post___acl_get_link(res, path, type, aclp) \ argument
2766 res, (long long)(path), (long long)(type), (long long)(aclp))
2767 #define __sanitizer_syscall_pre___acl_set_link(path, type, aclp) \ argument
2769 (long long)(path), (long long)(type), (long long)(aclp))
2770 #define __sanitizer_syscall_post___acl_set_link(res, path, type, aclp) \ argument
2772 res, (long long)(path), (long long)(type), (long long)(aclp))
2779 #define __sanitizer_syscall_pre___acl_aclcheck_link(path, type, aclp) \ argument
2781 (long long)(path), (long long)(type), (long long)(aclp))
[all …]
/freebsd/sys/contrib/openzfs/include/os/freebsd/spl/sys/
H A Dacl.h204 extern void aces_from_acl(ace_t *aces, int *nentries, const struct acl *aclp);
205 extern int acl_from_aces(struct acl *aclp, const ace_t *aces, int nentries);
/freebsd/lib/libsys/
H A D_libsys.h663 int __sys___acl_get_file(const char * path, __acl_type_t type, struct acl * aclp);
664 int __sys___acl_set_file(const char * path, __acl_type_t type, struct acl * aclp);
665 int __sys___acl_get_fd(int filedes, __acl_type_t type, struct acl * aclp);
666 int __sys___acl_set_fd(int filedes, __acl_type_t type, struct acl * aclp);
669 int __sys___acl_aclcheck_file(const char * path, __acl_type_t type, struct acl * aclp);
670 int __sys___acl_aclcheck_fd(int filedes, __acl_type_t type, struct acl * aclp);
718 int __sys___acl_get_link(const char * path, __acl_type_t type, struct acl * aclp);
719 int __sys___acl_set_link(const char * path, __acl_type_t type, struct acl * aclp);
721 int __sys___acl_aclcheck_link(const char * path, __acl_type_t type, struct acl * aclp);
/freebsd/sys/fs/nfsserver/
H A Dnfs_nfsdserv.c119 NFSACL_T *aclp, NFSPROC_T *p, struct nfsexstuff *exp, char *pathcp,
124 int *diraft_retp, nfsattrbit_t *attrbitp, NFSACL_T *aclp,
375 NFSACL_T *aclp = NULL; in nfsrvd_setattr() local
384 aclp = acl_alloc(M_WAITOK); in nfsrvd_setattr()
385 aclp->acl_cnt = 0; in nfsrvd_setattr()
401 error = nfsrv_sattr(nd, vp, &nva, &attrbits, aclp, p); in nfsrvd_setattr()
426 acl_free(aclp); in nfsrvd_setattr()
536 if (!nd->nd_repstat && aclp->acl_cnt > 0 && in nfsrvd_setattr()
538 nd->nd_repstat = nfsrv_setacl(vp, aclp, nd->nd_cred, p); in nfsrvd_setattr()
554 acl_free(aclp); in nfsrvd_setattr()
[all …]

12