SMB3 POSIX and deleting files with FILE_ATTRIBUTE_READONLY
Ralph Boehme
slow at samba.org
Mon Apr 14 19:02:47 UTC 2025
As discussed at SambaXP, what about this?
https://gitlab.com/samba-team/smb3-posix-spec/-/merge_requests/6/diffs
On 4/9/25 8:18 PM, Ralph Boehme via samba-technical wrote:
> Hi folks,
>
> what should be the behavior with SMB3 POSIX when a POSIX client tries to
> delete a file that has FILE_ATTRIBUTE_READONLY set?
>
> The major question that we must answer is, if this we would want to
> allow for POSIX clients to ignore this in some way: either completely
> ignore it on POSIX handles or first check if the handle has requested
> and been granted WRITE_ATTRIBUTES access.
>
> Checking WRITE_ATTRIBUTES first means we would correctly honor
> permissions and the client could have removed FILE_ATTRIBUTE_READONLY
> anyway to then remove the file.
>
> Windows has some new bits FILE_DISPOSITION_IGNORE_READONLY_ATTRIBUTE to
> handle this locally (!) and it seems to be doing it without checking
> WRITE_ATTRIBUTES on the server.
>
> <https://learn.microsoft.com/en-us/openspecs/windows_protocols/ms-
> fscc/2e860264-018a-47b3-8555-565a13b35a45>
>
> Thoughts?
>
> Thanks!
> -slow
-------------- next part --------------
A non-text attachment was scrubbed...
Name: OpenPGP_signature.asc
Type: application/pgp-signature
Size: 840 bytes
Desc: OpenPGP digital signature
URL: <http://lists.samba.org/pipermail/samba-technical/attachments/20250414/8d2c7585/OpenPGP_signature.sig>
More information about the samba-technical
mailing list