(merge from 3.0)
authorAndrew Bartlett <abartlet@samba.org>
Tue, 6 Jan 2004 00:41:13 +0000 (00:41 +0000)
committerAndrew Bartlett <abartlet@samba.org>
Tue, 6 Jan 2004 00:41:13 +0000 (00:41 +0000)
Ensure that for wbinfo --set-auth-user, we actually use the domain.

Andrew Bartlett
(This used to be commit 8a63bed29315acb3fe9cc2973426ef8392987c8c)

source3/nsswitch/winbindd_cm.c

index ebf342b35504e89e1675b59b68d866174e8e1988..c255d21102f48671c8d03f05f453b833257b5f44 100644 (file)
@@ -181,7 +181,7 @@ static NTSTATUS cm_open_connection(const struct winbindd_domain *domain, const i
 
                                if (!NT_STATUS_IS_OK(result = cli_session_setup_spnego(new_conn->cli, machine_krb5_principal, 
                                                              machine_password, 
-                                                             domain->name))) {
+                                                             lp_workgroup()))) {
                                        DEBUG(4,("failed kerberos session setup with %s\n", nt_errstr(result)));
                                        if (NT_STATUS_IS_OK(result)) 
                                                result = NT_STATUS_UNSUCCESSFUL;
@@ -203,7 +203,7 @@ static NTSTATUS cm_open_connection(const struct winbindd_domain *domain, const i
                                if (!cli_session_setup(new_conn->cli, ipc_username, 
                                                       ipc_password, strlen(ipc_password)+1, 
                                                       ipc_password, strlen(ipc_password)+1, 
-                                                      domain->name)) {
+                                                      ipc_domain)) {
                                        result = cli_nt_error(new_conn->cli);
                                        DEBUG(4,("failed authenticated session setup with %s\n", nt_errstr(result)));
                                        if (NT_STATUS_IS_OK(result))