mirror of
https://github.com/samba-team/samba.git
synced 2025-01-29 21:47:30 +03:00
Return the 'freindly' NT error message if at all possible.
Andrew Bartlett (This used to be commit 90d05176534cfd97ed3827bddfeb3a0cb7f22683)
This commit is contained in:
parent
674c750df7
commit
f9d66d10c2
@ -121,7 +121,8 @@ static int pam_winbind_request(enum winbindd_cmd req_type,
|
||||
/* Copy reply data from socket */
|
||||
if (response->result != WINBINDD_OK) {
|
||||
if (response->data.auth.pam_error != PAM_SUCCESS) {
|
||||
_pam_log(LOG_ERR, "request failed, PAM error was %d, NT error was %s",
|
||||
_pam_log(LOG_ERR, "request failed: %s, PAM error was %d, NT error was %s",
|
||||
response->data.auth.error_string,
|
||||
response->data.auth.pam_error,
|
||||
response->data.auth.nt_status_string);
|
||||
return response->data.auth.pam_error;
|
||||
|
@ -142,7 +142,7 @@ done:
|
||||
|
||||
state->response.data.auth.nt_status = NT_STATUS_V(result);
|
||||
fstrcpy(state->response.data.auth.nt_status_string, nt_errstr(result));
|
||||
fstrcpy(state->response.data.auth.error_string, nt_errstr(result));
|
||||
fstrcpy(state->response.data.auth.error_string, get_friendly_nt_error_msg(result));
|
||||
state->response.data.auth.pam_error = nt_status_to_pam(result);
|
||||
|
||||
DEBUG(NT_STATUS_IS_OK(result) ? 5 : 2, ("Plain-text authentication for user %s returned %s (PAM: %d)\n",
|
||||
|
Loading…
x
Reference in New Issue
Block a user