[SMB3 POSIX] POSIX client creates a file, set the ARCHIVE bit or not
Jeremy Allison
jra at samba.org
Mon Oct 30 16:28:17 UTC 2023
On Mon, Oct 30, 2023 at 04:03:29PM +0100, Ralph Boehme wrote:
>Hi!
>
>I just stumpled over our old SMB1 UNIX extensions code dealing with
>file creation in POSIX context. There we have in open_file_ntcreate():
>
> if (new_dos_attributes & FILE_FLAG_POSIX_SEMANTICS) {
> posix_open = True;
> unx_mode = (mode_t)(new_dos_attributes &
>~FILE_FLAG_POSIX_SEMANTICS);
> new_dos_attributes = 0;
> } else {
> ...
> new_dos_attributes |= FILE_ATTRIBUTE_ARCHIVE;
> ...
> }
>
>Why don't we set ARCHIVE for files created in POSIX context? Makes no
>sense to me.
I *think* it was back from when most servers were running
without EA's, so archive was mapped to a POSIX perms bit.
More information about the samba-technical
mailing list