From a2a097fc3d6a89fb970c1ea3ea75fde93ddb545e Mon Sep 17 00:00:00 2001 From: Jeremy Allison Date: Tue, 9 Aug 2022 10:41:39 -0700 Subject: [PATCH] s3: smbd: Make sure we have identical check_path_syntax logic in smbd_smb2_create_durable_lease_check(), as for smb2_create. BUG: https://bugzilla.samba.org/show_bug.cgi?id=15144 Signed-off-by: Jeremy Allison Reviewed-by: Ralph Boehme --- source3/smbd/smb2_create.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/source3/smbd/smb2_create.c b/source3/smbd/smb2_create.c index 8ef605dea66..75b9c7d28ff 100644 --- a/source3/smbd/smb2_create.c +++ b/source3/smbd/smb2_create.c @@ -430,6 +430,7 @@ static NTSTATUS smbd_smb2_create_durable_lease_check(struct smb_request *smb1req uint32_t ucf_flags; NTTIME twrp = fsp->fsp_name->twrp; NTSTATUS status; + bool is_dfs = (smb1req->flags2 & FLAGS2_DFS_PATHNAMES); if (lease_ptr == NULL) { if (fsp->oplock_type != LEASE_OPLOCK) { @@ -459,7 +460,7 @@ static NTSTATUS smbd_smb2_create_durable_lease_check(struct smb_request *smb1req } /* This also converts '\' to '/' */ - status = check_path_syntax(filename); + status = check_path_syntax_smb2(filename, is_dfs); if (!NT_STATUS_IS_OK(status)) { TALLOC_FREE(filename); return status; -- 2.47.3