Hi Kevin,
Thank you for the additional explanation and for pointing us to the relevant Libc and copyfile implementations.
Your clarification resolves our remaining question about enumerating a valid ACL without knowing its entry count in advance.
We understand that, when working with an unchanged acl_t successfully returned by acl_get_fd_np, the ACL_FIRST_ENTRY / ACL_NEXT_ENTRY sequence can enumerate the entries, with -1 and EINVAL marking the end of the valid sequence.
We also understand your distinction between errors originating in Libc and those returned by the kernel, and that your comments about the exact Libc error paths were not intended as an exhaustive code audit.
For our implementation, we will continue to handle genuine retrieval failures separately, preserve descriptor identity checks, and avoid treating invalid inputs or unexpected states as successful verification.
Thank you again for the detailed technical guidance and for helping us resolve these questions using the supported macOS interfaces.
Topic:
App & System Services
SubTopic:
Core OS
Tags: