On 8/12/2018 02:12, Lars wrote:
In your response you say "the read bits are always set" - is that based on read-only attribute or Windows permission settings?
No. They are always set. They are never not returned. A file with the read-only attribute set is reported as "readable but not writable" by Boost.Filesystem. A file with it not set is reported as "readable and writable".
I appreciate this might be complicated but the Windows implementation of permissions is rather surprising and not comparable to viewing "Security" on a file in Windows Explorer. Maybe a more visible and clearer description of permissions in the documentation is in order. I have certainly spent hours trying to use permissions with an incorrect view of its functionality 😊
Boost.Filesystem does not model ACL permissions at all (neither for Windows nor for Linux). You will have to use native APIs for that. The "Security" tab in Windows are the ACL permissions.