linux-stable/fs/smb
Scott Mayhew abcd2a0b4f smb: client: fix null auth
commit 270d73e650 upstream.

Commit abdb1742a3 removed code that clears ctx->username when sec=none, so attempting
to mount with '-o sec=none' now fails with -EACCES.  Fix it by adding that logic to the
parsing of the 'sec' option, as well as checking if the mount is using null auth before
setting the username when parsing the 'user' option.

Fixes: abdb1742a3 ("cifs: get rid of mount options string parsing")
Cc: stable@vger.kernel.org
Signed-off-by: Scott Mayhew <smayhew@redhat.com>
Reviewed-by: Paulo Alcantara (SUSE) <pc@manguebit.com>
Signed-off-by: Steve French <stfrench@microsoft.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2023-08-23 17:32:52 +02:00
..
client smb: client: fix null auth 2023-08-23 17:32:52 +02:00
common
server ksmbd: fix wrong next length validation of ea buffer in smb2_set_ea() 2023-08-16 18:32:16 +02:00
Kconfig
Makefile