]> git.ipfire.org Git - thirdparty/samba.git/commitdiff
s3: smbd: Make sure we have identical check_path_syntax logic in smbd_smb2_create_dur...
authorJeremy Allison <jra@samba.org>
Tue, 9 Aug 2022 17:41:39 +0000 (10:41 -0700)
committerJeremy Allison <jra@samba.org>
Fri, 12 Aug 2022 18:19:30 +0000 (18:19 +0000)
BUG: https://bugzilla.samba.org/show_bug.cgi?id=15144

Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
source3/smbd/smb2_create.c

index 8ef605dea66a67744e227453f6112c04655a3db9..75b9c7d28ff362b5479dd8c90403659f5600cd0e 100644 (file)
@@ -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;