| 695 | } |
| 696 | |
| 697 | static uchar recv_ida_entries(int f, ida_entries *ent) |
| 698 | { |
| 699 | uchar computed_mask_bits = 0; |
| 700 | int i, count = read_varint_bounded(f, 0, MAX_WIRE_ACL_COUNT, "ACL count"); |
| 701 | |
| 702 | ent->idas = count ? new_array(id_access, count) : NULL; |
| 703 | ent->count = count; |
| 704 | |
| 705 | for (i = 0; i < count; i++) { |
| 706 | uchar has_name; |
| 707 | id_t id = read_varint(f); |
| 708 | uint32 access = recv_acl_access(f, &has_name); |
| 709 | |
| 710 | if (has_name) { |
| 711 | if (access & NAME_IS_USER) |
| 712 | id = recv_user_name(f, id); |
| 713 | else |
| 714 | id = recv_group_name(f, id, NULL); |
| 715 | } else if (access & NAME_IS_USER) { |
| 716 | if (inc_recurse && !numeric_ids) |
| 717 | id = match_uid(id); |
| 718 | } else { |
| 719 | if (inc_recurse && (!am_root || !numeric_ids)) |
| 720 | id = match_gid(id, NULL); |
| 721 | } |
| 722 | |
| 723 | ent->idas[i].id = id; |
| 724 | ent->idas[i].access = access; |
| 725 | computed_mask_bits |= access; |
| 726 | } |
| 727 | |
| 728 | return computed_mask_bits & ~NO_ENTRY; |
| 729 | } |
| 730 | |
| 731 | static int recv_rsync_acl(int f, item_list *racl_list, SMB_ACL_TYPE_T type, mode_t mode) |
| 732 | { |
no test coverage detected