summaryrefslogtreecommitdiff
path: root/source4/rpc_server
diff options
context:
space:
mode:
authorAndrew Bartlett <abartlet@samba.org>2011-07-28 07:55:09 +1000
committerAndrew Bartlett <abartlet@samba.org>2011-07-29 04:24:06 +0200
commitee20a27d411c4f3c1d97e9c9bdbb7226f144c2f1 (patch)
tree49524d03778d5b34ed70cefa344444a457c7f0fc /source4/rpc_server
parent481f1e601daafd186c504476f7efa1b557099105 (diff)
downloadsamba-ee20a27d411c4f3c1d97e9c9bdbb7226f144c2f1.tar.gz
samba-ee20a27d411c4f3c1d97e9c9bdbb7226f144c2f1.tar.bz2
samba-ee20a27d411c4f3c1d97e9c9bdbb7226f144c2f1.zip
s4-lsa Use the supplied handle in LsaLookupNames2
In my rework of this function in 2006 with 459a2301a5d63f5a1a6b27996c8a0358b20f2ab2 I ignored the incoming handle, instead feching the LSA state again (dispite the commit message indicating otherwise). This means that data->access_mask is uninitialised, which doesn't matter right now, but will once we start checking that. Andrew Bartlett
Diffstat (limited to 'source4/rpc_server')
-rw-r--r--source4/rpc_server/lsa/lsa_lookup.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/source4/rpc_server/lsa/lsa_lookup.c b/source4/rpc_server/lsa/lsa_lookup.c
index 3d472812d8..522d2db6d6 100644
--- a/source4/rpc_server/lsa/lsa_lookup.c
+++ b/source4/rpc_server/lsa/lsa_lookup.c
@@ -549,12 +549,17 @@ NTSTATUS dcesrv_lsa_LookupSids2(struct dcesrv_call_state *dce_call,
struct lsa_RefDomainList *domains = NULL;
uint32_t i;
NTSTATUS status = NT_STATUS_OK;
+ struct dcesrv_handle *h;
+
+ DCESRV_PULL_HANDLE(h, r->in.handle, LSA_HANDLE_POLICY);
if (r->in.level < LSA_LOOKUP_NAMES_ALL ||
r->in.level > LSA_LOOKUP_NAMES_RODC_REFERRAL_TO_FULL_DC) {
return NT_STATUS_INVALID_PARAMETER;
}
+ state = h->data;
+
*r->out.domains = NULL;
/* NOTE: the WSPP test suite tries SIDs with invalid revision numbers,
@@ -563,11 +568,6 @@ NTSTATUS dcesrv_lsa_LookupSids2(struct dcesrv_call_state *dce_call,
MS-DTYP 2.4.2
*/
- status = dcesrv_lsa_get_policy_state(dce_call, mem_ctx, &state);
- if (!NT_STATUS_IS_OK(status)) {
- return status;
- }
-
domains = talloc_zero(r->out.domains, struct lsa_RefDomainList);
if (domains == NULL) {
return NT_STATUS_NO_MEMORY;