Lines Matching refs:acl
15 int acl_find_uid(acl_t acl, uid_t uid, acl_entry_t *ret_entry) { in acl_find_uid() argument
19 assert(acl); in acl_find_uid()
23 for (r = acl_get_entry(acl, ACL_FIRST_ENTRY, &i); in acl_find_uid()
25 r = acl_get_entry(acl, ACL_NEXT_ENTRY, &i)) { in acl_find_uid()
152 _cleanup_(acl_freep) acl_t acl = NULL; in acl_search_groups()
159 acl = acl_get_file(path, ACL_TYPE_DEFAULT); in acl_search_groups()
160 if (!acl) in acl_search_groups()
163 r = acl_get_entry(acl, ACL_FIRST_ENTRY, &entry); in acl_search_groups()
203 r = acl_get_entry(acl, ACL_NEXT_ENTRY, &entry); in acl_search_groups()
326 static int find_acl_entry(acl_t acl, acl_entry_t entry, acl_entry_t *out) { in find_acl_entry() argument
330 for (r = acl_get_entry(acl, ACL_FIRST_ENTRY, &i); in find_acl_entry()
332 r = acl_get_entry(acl, ACL_NEXT_ENTRY, &i)) { in find_acl_entry()
347 int acls_for_file(const char *path, acl_type_t type, acl_t new, acl_t *acl) { in acls_for_file() argument
375 *acl = TAKE_PTR(old); in acls_for_file()
395 _cleanup_(acl_freep) acl_t acl = NULL; in fd_add_uid_acl_permission()
406 acl = acl_get_fd(fd); in fd_add_uid_acl_permission()
407 if (!acl) in fd_add_uid_acl_permission()
410 r = acl_find_uid(acl, uid, &entry); in fd_add_uid_acl_permission()
412 if (acl_create_entry(&acl, &entry) < 0 || in fd_add_uid_acl_permission()
428 r = calc_acl_mask_if_needed(&acl); in fd_add_uid_acl_permission()
432 if (acl_set_fd(fd, acl) < 0) in fd_add_uid_acl_permission()