[SCM] Samba Shared Repository - branch master updated

Volker Lendecke vlendec at samba.org
Tue Mar 15 05:09:01 MDT 2011


The branch, master has been updated
       via  a6a722b libwbclient: CID 2199 -- NULL pointer return
       via  d9a5879 s3: Fix Coverity ID 2278: Uninitialized read
       via  f0d4912 s3: Fix Coverity ID 2279: Uninitialized read
       via  c98c36e s3: Fix Coverity ID 2280: Uninitialized read
       via  6b584e0 s3: Fix Coverity ID 2281: Uninitialized read
       via  e68cf5e s3: Fix Coverity ID 2282: Uninitialized read
       via  b753b0a s3: Fix Coverity ID 2283: Uninitialized read
       via  2992ccf s3: Fix Coverity ID 2284: Uninitialized read
       via  2b26c86 s3: Fix Coverity ID 2285: Uninitialized read
       via  c098771 s3: Fix Coverity ID 2286: Uninitialized read
       via  31ff8f3 s3: Fix Coverity ID 2287: Uninitialized read
       via  09677d6 s3: Fix Coverity ID 2288: Uninitialized read
       via  cc90415 s3: Fix Coverity ID 2289: Uninitialized read
       via  4f34955 s3: Fix Coverity ID 2290: Uninitialized read
      from  420be02 s3: Read uidNumber/gidNumber in pdb_ads_sid_to_id

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


- Log -----------------------------------------------------------------
commit a6a722b5bac1c0732acdd13e27d9be2e6aea73a1
Author: Volker Lendecke <vl at samba.org>
Date:   Tue Mar 15 11:19:57 2011 +0100

    libwbclient: CID 2199 -- NULL pointer return
    
    Autobuild-User: Volker Lendecke <vlendec at samba.org>
    Autobuild-Date: Tue Mar 15 12:08:48 CET 2011 on sn-devel-104

commit d9a58791b0e0c65556c055fcfff970b77d893f39
Author: Volker Lendecke <vl at samba.org>
Date:   Tue Mar 15 11:09:26 2011 +0100

    s3: Fix Coverity ID 2278: Uninitialized read
    
    We passed the structure including the uninitialized elements to
    dcerpc_winreg_SetValue.

commit f0d491205c75a7f5165d8b909590925ac80ca1c7
Author: Volker Lendecke <vl at samba.org>
Date:   Tue Mar 15 11:08:12 2011 +0100

    s3: Fix Coverity ID 2279: Uninitialized read
    
    We passed the structure including the uninitialized elements to
    dcerpc_winreg_SetValue.

commit c98c36e38b53a30c4708b4581a6b87e7110f8ac1
Author: Volker Lendecke <vl at samba.org>
Date:   Tue Mar 15 11:06:49 2011 +0100

    s3: Fix Coverity ID 2280: Uninitialized read
    
    We passed the structure including the uninitialized elements to
    dcerpc_winreg_SetValue.

commit 6b584e0e9a93b6e2a4601635f019960acd0a2a1d
Author: Volker Lendecke <vl at samba.org>
Date:   Tue Mar 15 11:05:48 2011 +0100

    s3: Fix Coverity ID 2281: Uninitialized read
    
    We passed the structure including the uninitialized elements to
    dcerpc_winreg_SetValue.

commit e68cf5e9bf10ebf24448d301047b2787838fa449
Author: Volker Lendecke <vl at samba.org>
Date:   Tue Mar 15 11:04:23 2011 +0100

    s3: Fix Coverity ID 2282: Uninitialized read
    
    We passed the structure including the uninitialized elements to
    dcerpc_winreg_SetValue.

commit b753b0ab82ed7d806f85d1e67afa4416ee7e77dc
Author: Volker Lendecke <vl at samba.org>
Date:   Tue Mar 15 11:02:57 2011 +0100

    s3: Fix Coverity ID 2283: Uninitialized read
    
    We passed the structure including the uninitialized elements to
    dcerpc_winreg_OpenKey.

commit 2992ccfe9cde279869091e96dffab4c8fe1631be
Author: Volker Lendecke <vl at samba.org>
Date:   Tue Mar 15 11:00:13 2011 +0100

    s3: Fix Coverity ID 2284: Uninitialized read
    
    We passed the structure including the uninitialized elements to
    dcerpc_winreg_DeleteValue.

commit 2b26c86fe6727fafef0dd5079fd75a334ea49b63
Author: Volker Lendecke <vl at samba.org>
Date:   Tue Mar 15 10:58:55 2011 +0100

    s3: Fix Coverity ID 2285: Uninitialized read
    
    We passed the structure including the uninitialized elements to
    dcerpc_winreg_DeleteValue.

commit c09877113d793f57e43a73fa6ac1e55ab7307047
Author: Volker Lendecke <vl at samba.org>
Date:   Tue Mar 15 10:56:37 2011 +0100

    s3: Fix Coverity ID 2286: Uninitialized read
    
    We passed the structure including the uninitialized elements to
    dcerpc_winreg_SetValue.

commit 31ff8f38e7d22402224996341c705e564e597d34
Author: Volker Lendecke <vl at samba.org>
Date:   Tue Mar 15 10:54:59 2011 +0100

    s3: Fix Coverity ID 2287: Uninitialized read
    
    We passed the structure including the uninitialized elements to
    dcerpc_winreg_CreateKey.

commit 09677d664f2a5c254549597f5b2b5203fcb0a23e
Author: Volker Lendecke <vl at samba.org>
Date:   Tue Mar 15 10:52:49 2011 +0100

    s3: Fix Coverity ID 2288: Uninitialized read
    
    We passed the structure including the uninitialized elements to
    dcerpc_winreg_SetValue.

commit cc90415062c4f1c68005fc3ff2958c189a88d949
Author: Volker Lendecke <vl at samba.org>
Date:   Tue Mar 15 10:49:00 2011 +0100

    s3: Fix Coverity ID 2289: Uninitialized read
    
    We passed the structure including the uninitialized elements to
    dcerpc_winreg_OpenKey.

commit 4f34955e2c68809cd598f0626cb1a03ba78b1059
Author: Volker Lendecke <vl at samba.org>
Date:   Tue Mar 15 10:47:02 2011 +0100

    s3: Fix Coverity ID 2290: Uninitialized read
    
    We passed the structure including the uninitialized elements to
    dcerpc_winreg_DeleteKey.

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

Summary of changes:
 nsswitch/libwbclient/wbc_util.c               |    4 ++++
 source3/rpc_client/cli_winreg.c               |    8 ++++----
 source3/rpc_server/spoolss/srv_spoolss_util.c |   12 ++++++------
 source3/rpcclient/cmd_winreg.c                |    2 +-
 source3/services/svc_winreg_glue.c            |    2 +-
 source3/utils/net_rpc_registry.c              |    2 +-
 6 files changed, 17 insertions(+), 13 deletions(-)


Changeset truncated at 500 lines:

diff --git a/nsswitch/libwbclient/wbc_util.c b/nsswitch/libwbclient/wbc_util.c
index d2783f3..6d7a96c 100644
--- a/nsswitch/libwbclient/wbc_util.c
+++ b/nsswitch/libwbclient/wbc_util.c
@@ -787,6 +787,10 @@ wbcErr wbcAddNamedBlob(size_t *num_blobs,
 		*num_blobs + 2, sizeof(struct wbcNamedBlob),
 		wbcNamedBlobDestructor);
 
+	if (blobs == NULL) {
+		return WBC_ERR_NO_MEMORY;
+	}
+
 	if (*pblobs != NULL) {
 		struct wbcNamedBlob *old = *pblobs;
 		memcpy(blobs, old, sizeof(struct wbcNamedBlob) * (*num_blobs));
diff --git a/source3/rpc_client/cli_winreg.c b/source3/rpc_client/cli_winreg.c
index c3f0c90..5b8635f 100644
--- a/source3/rpc_client/cli_winreg.c
+++ b/source3/rpc_client/cli_winreg.c
@@ -379,7 +379,7 @@ NTSTATUS dcerpc_winreg_set_dword(TALLOC_CTX *mem_ctx,
 				 uint32_t data,
 				 WERROR *pwerr)
 {
-	struct winreg_String wvalue;
+	struct winreg_String wvalue = { 0, };
 	DATA_BLOB blob;
 	WERROR result = WERR_OK;
 	NTSTATUS status;
@@ -413,7 +413,7 @@ NTSTATUS dcerpc_winreg_set_sz(TALLOC_CTX *mem_ctx,
 			      const char *data,
 			      WERROR *pwerr)
 {
-	struct winreg_String wvalue;
+	struct winreg_String wvalue = { 0, };
 	DATA_BLOB blob;
 	WERROR result = WERR_OK;
 	NTSTATUS status;
@@ -456,7 +456,7 @@ NTSTATUS dcerpc_winreg_set_expand_sz(TALLOC_CTX *mem_ctx,
 				     const char *data,
 				     WERROR *pwerr)
 {
-	struct winreg_String wvalue;
+	struct winreg_String wvalue = { 0, };
 	DATA_BLOB blob;
 	WERROR result = WERR_OK;
 	NTSTATUS status;
@@ -538,7 +538,7 @@ NTSTATUS dcerpc_winreg_set_binary(TALLOC_CTX *mem_ctx,
 				  DATA_BLOB *data,
 				  WERROR *pwerr)
 {
-	struct winreg_String wvalue;
+	struct winreg_String wvalue = { 0, };
 	WERROR result = WERR_OK;
 	NTSTATUS status;
 
diff --git a/source3/rpc_server/spoolss/srv_spoolss_util.c b/source3/rpc_server/spoolss/srv_spoolss_util.c
index 896a9ed..d27de5d 100644
--- a/source3/rpc_server/spoolss/srv_spoolss_util.c
+++ b/source3/rpc_server/spoolss/srv_spoolss_util.c
@@ -569,7 +569,7 @@ static WERROR winreg_printer_delete_subkeys(TALLOC_CTX *mem_ctx,
 	const char **subkeys = NULL;
 	uint32_t num_subkeys = 0;
 	struct policy_handle key_hnd;
-	struct winreg_String wkey;
+	struct winreg_String wkey = { 0, };
 	WERROR result = WERR_OK;
 	NTSTATUS status;
 	uint32_t i;
@@ -2228,7 +2228,7 @@ WERROR winreg_set_printer_dataex(TALLOC_CTX *mem_ctx,
 	uint32_t access_mask = SEC_FLAG_MAXIMUM_ALLOWED;
 	struct dcerpc_binding_handle *winreg_handle = NULL;
 	struct policy_handle hive_hnd, key_hnd;
-	struct winreg_String wvalue;
+	struct winreg_String wvalue = { 0, };
 	char *path;
 	WERROR result = WERR_OK;
 	NTSTATUS status;
@@ -2517,7 +2517,7 @@ WERROR winreg_delete_printer_dataex(TALLOC_CTX *mem_ctx,
 	uint32_t access_mask = SEC_FLAG_MAXIMUM_ALLOWED;
 	struct dcerpc_binding_handle *winreg_handle = NULL;
 	struct policy_handle hive_hnd, key_hnd;
-	struct winreg_String wvalue;
+	struct winreg_String wvalue = { 0, };
 	char *path;
 	WERROR result = WERR_OK;
 	NTSTATUS status;
@@ -2931,7 +2931,7 @@ WERROR winreg_printer_addform1(TALLOC_CTX *mem_ctx,
 	uint32_t access_mask = SEC_FLAG_MAXIMUM_ALLOWED;
 	struct dcerpc_binding_handle *winreg_handle = NULL;
 	struct policy_handle hive_hnd, key_hnd;
-	struct winreg_String wvalue;
+	struct winreg_String wvalue = { 0, };
 	DATA_BLOB blob;
 	uint32_t num_info = 0;
 	union spoolss_FormInfo *info = NULL;
@@ -3149,7 +3149,7 @@ WERROR winreg_printer_deleteform1(TALLOC_CTX *mem_ctx,
 	uint32_t access_mask = SEC_FLAG_MAXIMUM_ALLOWED;
 	struct dcerpc_binding_handle *winreg_handle = NULL;
 	struct policy_handle hive_hnd, key_hnd;
-	struct winreg_String wvalue;
+	struct winreg_String wvalue = { 0, };
 	uint32_t num_builtin = ARRAY_SIZE(builtin_forms1);
 	uint32_t i;
 	WERROR result = WERR_OK;
@@ -3232,7 +3232,7 @@ WERROR winreg_printer_setform1(TALLOC_CTX *mem_ctx,
 	uint32_t access_mask = SEC_FLAG_MAXIMUM_ALLOWED;
 	struct dcerpc_binding_handle *winreg_handle = NULL;
 	struct policy_handle hive_hnd, key_hnd;
-	struct winreg_String wvalue;
+	struct winreg_String wvalue = { 0, };
 	DATA_BLOB blob;
 	uint32_t num_builtin = ARRAY_SIZE(builtin_forms1);
 	uint32_t i;
diff --git a/source3/rpcclient/cmd_winreg.c b/source3/rpcclient/cmd_winreg.c
index 2ba2d6d..e9508e3 100644
--- a/source3/rpcclient/cmd_winreg.c
+++ b/source3/rpcclient/cmd_winreg.c
@@ -156,7 +156,7 @@ static WERROR cmd_winreg_querymultiplevalues_ex(struct rpc_pipe_client *cli,
 	NTSTATUS status;
 	WERROR werr;
 	struct policy_handle handle, key_handle;
-	struct winreg_String key_name;
+	struct winreg_String key_name = { 0, };
 	struct dcerpc_binding_handle *b = cli->binding_handle;
 
 	struct QueryMultipleValue *values_in, *values_out;
diff --git a/source3/services/svc_winreg_glue.c b/source3/services/svc_winreg_glue.c
index 65f0388..dc367c2 100644
--- a/source3/services/svc_winreg_glue.c
+++ b/source3/services/svc_winreg_glue.c
@@ -197,7 +197,7 @@ bool svcctl_set_secdesc(struct messaging_context *msg_ctx,
 
 	{
 		enum winreg_CreateAction action = REG_ACTION_NONE;
-		struct winreg_String wkey;
+		struct winreg_String wkey = { 0, };
 		struct winreg_String wkeyclass;
 
 		wkey.name = talloc_asprintf(tmp_ctx, "%s\\Security", key);
diff --git a/source3/utils/net_rpc_registry.c b/source3/utils/net_rpc_registry.c
index c98fc07..17c5d5a 100644
--- a/source3/utils/net_rpc_registry.c
+++ b/source3/utils/net_rpc_registry.c
@@ -1782,7 +1782,7 @@ static WERROR import_delete_key(struct import_ctx* ctx,
 	WERROR werr;
 	NTSTATUS status;
 	void* mem_ctx = talloc_new(ctx->mem_ctx);
-	struct winreg_String  keyname;
+	struct winreg_String  keyname = { 0, };
 	struct policy_handle  hive;
 	struct dcerpc_binding_handle *b = ctx->pipe_hnd->binding_handle;
 


-- 
Samba Shared Repository


More information about the samba-cvs mailing list