Skip to content

Commit

Permalink
ksmbd: remove wrong leading slash check
Browse files Browse the repository at this point in the history
Signed-off-by: Namjae Jeon <[email protected]>
  • Loading branch information
namjaejeon committed Jun 8, 2024
1 parent 18f1b87 commit 2acf2d6
Showing 1 changed file with 0 additions and 7 deletions.
7 changes: 0 additions & 7 deletions smb2pdu.c
Original file line number Diff line number Diff line change
Expand Up @@ -2939,13 +2939,6 @@ int smb2_open(struct ksmbd_work *work)
}

if (req->NameLength) {
if ((req->CreateOptions & FILE_DIRECTORY_FILE_LE) &&
*(char *)req->Buffer == '\\') {
pr_err("not allow directory name included leading slash\n");
rc = -EINVAL;
goto err_out2;
}

name = smb2_get_name((char *)req + le16_to_cpu(req->NameOffset),
le16_to_cpu(req->NameLength),
work->conn->local_nls);
Expand Down

0 comments on commit 2acf2d6

Please sign in to comment.