Skip to content

Commit 728f14c

Browse files
namjaejeonsmfrench
authored andcommitted
ksmbd: set FILE_NAMED_STREAMS attribute in FS_ATTRIBUTE_INFORMATION
If vfs objects = streams_xattr in ksmbd.conf FILE_NAMED_STREAMS should be set to Attributes in FS_ATTRIBUTE_INFORMATION. MacOS client show "Format: SMB (Unknown)" on faked NTFS and no streams support. Cc: stable@vger.kernel.org Reported-by: Miao Lihua <441884205@qq.com> Tested-by: Miao Lihua <441884205@qq.com> Signed-off-by: Namjae Jeon <linkinjeon@kernel.org> Signed-off-by: Steve French <stfrench@microsoft.com>
1 parent 7a891d4 commit 728f14c

1 file changed

Lines changed: 4 additions & 0 deletions

File tree

fs/ksmbd/smb2pdu.c

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4934,6 +4934,10 @@ static int smb2_get_info_filesystem(struct ksmbd_work *work,
49344934

49354935
info->Attributes |= cpu_to_le32(server_conf.share_fake_fscaps);
49364936

4937+
if (test_share_config_flag(work->tcon->share_conf,
4938+
KSMBD_SHARE_FLAG_STREAMS))
4939+
info->Attributes |= cpu_to_le32(FILE_NAMED_STREAMS);
4940+
49374941
info->MaxPathNameComponentLength = cpu_to_le32(stfs.f_namelen);
49384942
len = smbConvertToUTF16((__le16 *)info->FileSystemName,
49394943
"NTFS", PATH_MAX, conn->local_nls, 0);

0 commit comments

Comments
 (0)