]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
ksmbd: do not grant v2 lease if parent lease key and epoch are not set
authorNamjae Jeon <linkinjeon@kernel.org>
Wed, 1 May 2024 12:58:15 +0000 (21:58 +0900)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 17 May 2024 09:56:22 +0000 (11:56 +0200)
commit94eb9f83a45dac66de76e9c2a30ab9d592b4c9bd
tree0ffca4df3e7dcee693438f2086b6983f9db9c43f
parent3ae4f87ac2c696e784ea4c2657f00a62616248eb
ksmbd: do not grant v2 lease if parent lease key and epoch are not set

commit 691aae4f36f9825df6781da4399a1e718951085a upstream.

This patch fix xfstests generic/070 test with smb2 leases = yes.

cifs.ko doesn't set parent lease key and epoch in create context v2 lease.
ksmbd suppose that parent lease and epoch are vaild if data length is
v2 lease context size and handle directory lease using this values.
ksmbd should hanle it as v1 lease not v2 lease if parent lease key and
epoch are not set in create context v2 lease.

Cc: stable@vger.kernel.org
Signed-off-by: Namjae Jeon <linkinjeon@kernel.org>
Signed-off-by: Steve French <stfrench@microsoft.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
fs/smb/server/oplock.c