From: Jeremy Allison Date: Tue, 8 Jun 2021 19:16:04 +0000 (-0700) Subject: s3: smbd: smbd_check_access_rights_sd(). Add dirfsp parameter. X-Git-Tag: tevent-0.11.0~522 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=88881510c7472721f6968b68a33f35b9b0bdd229;p=thirdparty%2Fsamba.git s3: smbd: smbd_check_access_rights_sd(). Add dirfsp parameter. Pass down to parent_override_delete(). Always pass fsp->conn->cwd_fsp for now. Signed-off-by: Jeremy Allison Reviewed-by: Ralph Boehme --- diff --git a/source3/smbd/open.c b/source3/smbd/open.c index c7ab1bfa5d8..edced0d6131 100644 --- a/source3/smbd/open.c +++ b/source3/smbd/open.c @@ -98,6 +98,7 @@ static bool parent_override_delete(connection_struct *conn, static NTSTATUS smbd_check_access_rights_sd( struct connection_struct *conn, + struct files_struct *dirfsp, const struct smb_filename *smb_fname, struct security_descriptor *sd, bool use_privs, @@ -220,7 +221,7 @@ access_denied: } if (parent_override_delete(conn, - conn->cwd_fsp, + dirfsp, smb_fname, access_mask, rejected_mask)) @@ -289,6 +290,7 @@ NTSTATUS smbd_check_access_rights_fsp(struct files_struct *fsp, } return smbd_check_access_rights_sd(fsp->conn, + fsp->conn->cwd_fsp, fsp->fsp_name, sd, use_privs,