s3:winbindd: make use of rpccli_netlogon_network_logon()
authorStefan Metzmacher <metze@samba.org>
Mon, 16 Sep 2013 22:56:15 +0000 (00:56 +0200)
committerAndrew Bartlett <abartlet@samba.org>
Tue, 10 Dec 2013 22:29:10 +0000 (11:29 +1300)
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
source3/winbindd/winbindd_pam.c

index 21f555c86e378962355712776dbf78e1994a8cab..a3a1ddbc2203a577e532e4ca0e813cdfe99f0c18 100644 (file)
@@ -1228,6 +1228,8 @@ static NTSTATUS winbind_samlogon_retry_loop(struct winbindd_domain *domain,
 
        do {
                struct rpc_pipe_client *netlogon_pipe;
+               uint8_t authoritative = 0;
+               uint32_t flags = 0;
 
                ZERO_STRUCTP(info3);
                retry = false;
@@ -1276,19 +1278,19 @@ static NTSTATUS winbind_samlogon_retry_loop(struct winbindd_domain *domain,
                }
                netr_attempts = 0;
 
-               result = rpccli_netlogon_sam_network_logon(
-                                       netlogon_pipe,
-                                       mem_ctx,
-                                       logon_parameters,
-                                       server,         /* server name */
-                                       username,       /* user name */
-                                       domainname,     /* target domain */
-                                       workstation,    /* workstation */
-                                       chal,
-                                       -1, /* ignored */
-                                       lm_response,
-                                       nt_response,
-                                       info3);
+               result = rpccli_netlogon_network_logon(domain->conn.netlogon_creds,
+                                               netlogon_pipe->binding_handle,
+                                               mem_ctx,
+                                               logon_parameters,
+                                               username,
+                                               domainname,
+                                               workstation,
+                                               chal,
+                                               lm_response,
+                                               nt_response,
+                                               &authoritative,
+                                               &flags,
+                                               info3);
 
                /*
                 * we increment this after the "feature negotiation"