query fs info level 0x100

Stefan Metzmacher metze at samba.org
Mon Apr 29 16:37:47 UTC 2024


Am 29.04.24 um 18:13 schrieb Steve French via samba-technical:
> On Mon, Apr 29, 2024 at 12:31 AM Ralph Boehme <slow at samba.org> wrote:
>>
>> On 4/29/24 1:27 AM, Steve French wrote:
>>> Trying some xfstests to current Samba (master branch, Samba 4.21),
>>> they fail because query fs info (level 0x100) is returning
>>> STATUS_INVALID_INFO_CLASS) - this works to ksmbd and I thought it used
>>> to work to Samba.   I do see the SMB3.1.1 opens with the POSIX open
>>> context works - but the query fs info failing causes xfstests to fail.
>>>
>>> Is that missing rom current mainline Samba?
>>
>> have you enabled SMB3 UNIX Extensions?
>>
>> smb3 unix extensions = yes
> 
> Yes - it is set to yes in the smb.conf for both the global section and
> the per share section
> 
> I also see that POSIX extensions in:
> 1) the server returns posix negotiation context in the SMB3.1.1
> negotiate protocol response
> 2) the server returns the level 100 (FILE_POSIX_INFO) query info responses
> 
> But the (current Samba) server fails the level 100 (level 0x64 in hex)
> FS_POSIX_INFO with "STATUS_INVALID_ERROR_CLASS"
> which causes all xfstests to break since they can't verify the mount
> (e.g. with "stat -f").
> Nothing related to this on the client has changed, and ksmbd has
> always supported this so works fine there.

I guess fsinfo_unix_valid_level() needs
fsp->posix_flags & FSP_POSIX_FLAGS_OPEN
instead of
fsp->posix_flags == FSP_POSIX_FLAGS_OPEN

In smbd_do_qfilepathinfo() we do the check with '&' instead of '=='.

metze



More information about the samba-technical mailing list