winbind: Query domain from msrpc name_to_sid
authorChristof Schmitt <cs@samba.org>
Mon, 11 Mar 2019 22:53:51 +0000 (15:53 -0700)
committerChristof Schmitt <cs@samba.org>
Thu, 18 Apr 2019 17:21:17 +0000 (17:21 +0000)
BUG: https://bugzilla.samba.org/show_bug.cgi?id=13831

Signed-off-by: Christof Schmitt <cs@samba.org>
Reviewed-by: Volker Lendecke <vl@samba.org>
source3/winbindd/winbindd_msrpc.c

index 203fbc6b56a9d018041ec4cfbb9525744925ca3d..69a049556ddd0dbcd9906a60988710dac98de6a1 100644 (file)
@@ -226,6 +226,7 @@ static NTSTATUS msrpc_name_to_sid(struct winbindd_domain *domain,
        enum lsa_SidType *types = NULL;
        char *full_name = NULL;
        const char *names[1];
+       const char **domains;
        NTSTATUS name_map_status = NT_STATUS_UNSUCCESSFUL;
        char *mapped_name = NULL;
 
@@ -260,7 +261,7 @@ static NTSTATUS msrpc_name_to_sid(struct winbindd_domain *domain,
        names[0] = full_name;
 
        result = winbindd_lookup_names(mem_ctx, domain, 1,
-                                      names, NULL,
+                                      names, &domains,
                                       &sids, &types);
        if (!NT_STATUS_IS_OK(result))
                return result;