[SCM] Samba Shared Repository - branch master updated

Stefan Metzmacher metze at samba.org
Wed Sep 5 04:28:02 MDT 2012


The branch, master has been updated
       via  92bd7b0 s3:smb2_create: check for SMB2_CREATE_TAG_DHNC first
       via  a3eee54 s3:locking: fix trailing space in brl_close_fnum()
      from  2311a2c s4 dns: Allow configuring signed updates

http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master


- Log -----------------------------------------------------------------
commit 92bd7b0db82bffc951af7862edde95852edc756d
Author: Stefan Metzmacher <metze at samba.org>
Date:   Tue Aug 28 09:33:51 2012 +0200

    s3:smb2_create: check for SMB2_CREATE_TAG_DHNC first
    
    metze
    
    Autobuild-User(master): Stefan Metzmacher <metze at samba.org>
    Autobuild-Date(master): Wed Sep  5 12:27:25 CEST 2012 on sn-devel-104

commit a3eee547ac939eec6f040c3b9968364b6b58aad3
Author: Michael Adam <obnox at samba.org>
Date:   Tue Sep 4 11:56:15 2012 +0200

    s3:locking: fix trailing space in brl_close_fnum()
    
    Signed-off-by: Stefan Metzmacher <metze at samba.org>

-----------------------------------------------------------------------

Summary of changes:
 source3/locking/brlock.c   |    2 +-
 source3/smbd/smb2_create.c |   57 ++++++++++---------------------------------
 2 files changed, 15 insertions(+), 44 deletions(-)


Changeset truncated at 500 lines:

diff --git a/source3/locking/brlock.c b/source3/locking/brlock.c
index e9c073b..c03e451 100644
--- a/source3/locking/brlock.c
+++ b/source3/locking/brlock.c
@@ -1500,7 +1500,7 @@ void brl_close_fnum(struct messaging_context *msg_ctx,
 		if (!locks_copy) {
 			smb_panic("brl_close_fnum: talloc failed");
 			}
-	} else {	
+	} else {
 		locks_copy = NULL;
 	}
 
diff --git a/source3/smbd/smb2_create.c b/source3/smbd/smb2_create.c
index c1cfa0c..2c308b1 100644
--- a/source3/smbd/smb2_create.c
+++ b/source3/smbd/smb2_create.c
@@ -431,6 +431,7 @@ static struct tevent_req *smbd_smb2_create_send(TALLOC_CTX *mem_ctx,
 	struct timespec write_time_ts;
 	struct smb2_create_blobs out_context_blobs;
 	int requested_oplock_level;
+	struct smb2_create_blob *dhnc = NULL;
 
 	ZERO_STRUCT(out_context_blobs);
 
@@ -468,6 +469,19 @@ static struct tevent_req *smbd_smb2_create_send(TALLOC_CTX *mem_ctx,
 			in_name ));
 	}
 
+	dhnc = smb2_create_blob_find(&in_context_blobs,
+				     SMB2_CREATE_TAG_DHNC);
+
+	if (dhnc) {
+		if (dhnc->data.length != 16) {
+			tevent_req_nterror(req, NT_STATUS_INVALID_PARAMETER);
+			return tevent_req_post(req, ev);
+		}
+		/* we don't support durable handles yet */
+		tevent_req_nterror(req, NT_STATUS_OBJECT_NAME_NOT_FOUND);
+		return tevent_req_post(req, ev);
+	}
+
 	if (IS_IPC(smb1req->conn)) {
 		const char *pipe_name = in_name;
 
@@ -507,7 +521,6 @@ static struct tevent_req *smbd_smb2_create_send(TALLOC_CTX *mem_ctx,
 		struct smb2_create_blob *secd = NULL;
 		struct security_descriptor *sec_desc = NULL;
 		struct smb2_create_blob *dhnq = NULL;
-		struct smb2_create_blob *dhnc = NULL;
 		struct smb2_create_blob *alsi = NULL;
 		uint64_t allocation_size = 0;
 		struct smb2_create_blob *twrp = NULL;
@@ -521,8 +534,6 @@ static struct tevent_req *smbd_smb2_create_send(TALLOC_CTX *mem_ctx,
 					     SMB2_CREATE_TAG_SECD);
 		dhnq = smb2_create_blob_find(&in_context_blobs,
 					     SMB2_CREATE_TAG_DHNQ);
-		dhnc = smb2_create_blob_find(&in_context_blobs,
-					     SMB2_CREATE_TAG_DHNC);
 		alsi = smb2_create_blob_find(&in_context_blobs,
 					     SMB2_CREATE_TAG_ALSI);
 		twrp = smb2_create_blob_find(&in_context_blobs,
@@ -536,11 +547,6 @@ static struct tevent_req *smbd_smb2_create_send(TALLOC_CTX *mem_ctx,
 		}
 
 		if (exta) {
-			if (dhnc) {
-				tevent_req_nterror(req,NT_STATUS_OBJECT_NAME_NOT_FOUND);
-				return tevent_req_post(req, ev);
-			}
-
 			ea_list = read_nttrans_ea_list(mem_ctx,
 				(const char *)exta->data.data, exta->data.length);
 			if (!ea_list) {
@@ -551,11 +557,6 @@ static struct tevent_req *smbd_smb2_create_send(TALLOC_CTX *mem_ctx,
 		}
 
 		if (mxac) {
-			if (dhnc) {
-				tevent_req_nterror(req, NT_STATUS_OBJECT_NAME_NOT_FOUND);
-				return tevent_req_post(req, ev);
-			}
-
 			if (mxac->data.length == 0) {
 				max_access_time = 0;
 			} else if (mxac->data.length == 8) {
@@ -569,11 +570,6 @@ static struct tevent_req *smbd_smb2_create_send(TALLOC_CTX *mem_ctx,
 		if (secd) {
 			enum ndr_err_code ndr_err;
 
-			if (dhnc) {
-				tevent_req_nterror(req, NT_STATUS_OBJECT_NAME_NOT_FOUND);
-				return tevent_req_post(req, ev);
-			}
-
 			sec_desc = talloc_zero(state, struct security_descriptor);
 			if (tevent_req_nomem(sec_desc, req)) {
 				return tevent_req_post(req, ev);
@@ -591,11 +587,6 @@ static struct tevent_req *smbd_smb2_create_send(TALLOC_CTX *mem_ctx,
 		}
 
 		if (dhnq) {
-			if (dhnc) {
-				tevent_req_nterror(req, NT_STATUS_OBJECT_NAME_NOT_FOUND);
-				return tevent_req_post(req, ev);
-			}
-
 			if (dhnq->data.length != 16) {
 				tevent_req_nterror(req, NT_STATUS_INVALID_PARAMETER);
 				return tevent_req_post(req, ev);
@@ -606,22 +597,7 @@ static struct tevent_req *smbd_smb2_create_send(TALLOC_CTX *mem_ctx,
 			 */
 		}
 
-		if (dhnc) {
-			if (dhnc->data.length != 16) {
-				tevent_req_nterror(req, NT_STATUS_INVALID_PARAMETER);
-				return tevent_req_post(req, ev);
-			}
-			/* we don't support durable handles yet */
-			tevent_req_nterror(req, NT_STATUS_OBJECT_NAME_NOT_FOUND);
-			return tevent_req_post(req, ev);
-		}
-
 		if (alsi) {
-			if (dhnc) {
-				tevent_req_nterror(req, NT_STATUS_OBJECT_NAME_NOT_FOUND);
-				return tevent_req_post(req, ev);
-			}
-
 			if (alsi->data.length != 8) {
 				tevent_req_nterror(req, NT_STATUS_INVALID_PARAMETER);
 				return tevent_req_post(req, ev);
@@ -634,11 +610,6 @@ static struct tevent_req *smbd_smb2_create_send(TALLOC_CTX *mem_ctx,
 			time_t t;
 			struct tm *tm;
 
-			if (dhnc) {
-				tevent_req_nterror(req, NT_STATUS_OBJECT_NAME_NOT_FOUND);
-				return tevent_req_post(req, ev);
-			}
-
 			if (twrp->data.length != 8) {
 				tevent_req_nterror(req, NT_STATUS_INVALID_PARAMETER);
 				return tevent_req_post(req, ev);


-- 
Samba Shared Repository


More information about the samba-cvs mailing list