[SCM] Samba Shared Repository - branch master updated
Volker Lendecke
vlendec at samba.org
Sat Apr 10 09:06:24 MDT 2010
The branch, master has been updated
via 1038a13... libwbclient: Fix a memleak in wbcGetDisplayName
via 27d3bdd... libwbclient: Ensure correct 0-termination in wbcGetSidAliases
via 4085e18... s3: Check 0 termination in GETALIASES
from 7726773... s4:dsdb Don't use the permissive modify control on schemaInfo updates
http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master
- Log -----------------------------------------------------------------
commit 1038a134eddd178635d3c1187cb92a42b884e76f
Author: Volker Lendecke <vl at samba.org>
Date: Sat Apr 10 16:34:53 2010 +0200
libwbclient: Fix a memleak in wbcGetDisplayName
commit 27d3bdd36b374b40a9e383262e2e30c813943d7e
Author: Volker Lendecke <vl at samba.org>
Date: Sat Apr 10 16:59:27 2010 +0200
libwbclient: Ensure correct 0-termination in wbcGetSidAliases
commit 4085e189a147841fed64ecbe072cde007cedad0d
Author: Volker Lendecke <vl at samba.org>
Date: Sat Apr 10 16:55:46 2010 +0200
s3: Check 0 termination in GETALIASES
-----------------------------------------------------------------------
Summary of changes:
nsswitch/libwbclient/wbc_sid.c | 2 ++
source3/winbindd/winbindd_getsidaliases.c | 20 +++++++++++++-------
2 files changed, 15 insertions(+), 7 deletions(-)
Changeset truncated at 500 lines:
diff --git a/nsswitch/libwbclient/wbc_sid.c b/nsswitch/libwbclient/wbc_sid.c
index e589122..5687132 100644
--- a/nsswitch/libwbclient/wbc_sid.c
+++ b/nsswitch/libwbclient/wbc_sid.c
@@ -576,6 +576,7 @@ wbcErr wbcGetSidAliases(const struct wbcDomainSid *dom_sid,
extra_data[extra_data_len++] = '\n';
extra_data[extra_data_len] = '\0';
}
+ extra_data_len += 1;
request.extra_data.data = extra_data;
request.extra_len = extra_data_len;
@@ -781,6 +782,7 @@ wbcErr wbcGetDisplayName(const struct wbcDomainSid *sid,
name = talloc_strdup(NULL, pwd->pw_gecos);
BAIL_ON_PTR_ERROR(name, wbc_status);
+ wbcFreeMemory(pwd);
}
wbc_status = WBC_ERR_SUCCESS;
diff --git a/source3/winbindd/winbindd_getsidaliases.c b/source3/winbindd/winbindd_getsidaliases.c
index 6755fa1..baa8fea 100644
--- a/source3/winbindd/winbindd_getsidaliases.c
+++ b/source3/winbindd/winbindd_getsidaliases.c
@@ -68,13 +68,19 @@ struct tevent_req *winbindd_getsidaliases_send(TALLOC_CTX *mem_ctx,
num_sids = 0;
sids = NULL;
- if ((request->extra_data.data != NULL)
- && !parse_sidlist(state, request->extra_data.data,
- &sids, &num_sids)) {
- DEBUG(1, ("Could not parse SID list: %s\n",
- request->extra_data.data));
- tevent_req_nterror(req, NT_STATUS_INVALID_PARAMETER);
- return tevent_req_post(req, ev);
+ if (request->extra_data.data != NULL) {
+ if (request->extra_data.data[request->extra_len-1] != '\0') {
+ DEBUG(1, ("Got non-NULL terminated sidlist\n"));
+ tevent_req_nterror(req, NT_STATUS_INVALID_PARAMETER);
+ return tevent_req_post(req, ev);
+ }
+ if (!parse_sidlist(state, request->extra_data.data,
+ &sids, &num_sids)) {
+ DEBUG(1, ("Could not parse SID list: %s\n",
+ request->extra_data.data));
+ tevent_req_nterror(req, NT_STATUS_INVALID_PARAMETER);
+ return tevent_req_post(req, ev);
+ }
}
subreq = wb_lookupuseraliases_send(state, ev, domain, num_sids, sids);
--
Samba Shared Repository
More information about the samba-cvs
mailing list