summaryrefslogtreecommitdiff
path: root/source3/winbindd
diff options
context:
space:
mode:
Diffstat (limited to 'source3/winbindd')
-rw-r--r--source3/winbindd/winbindd_pam.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/source3/winbindd/winbindd_pam.c b/source3/winbindd/winbindd_pam.c
index 74b82370bf..aa804c801f 100644
--- a/source3/winbindd/winbindd_pam.c
+++ b/source3/winbindd/winbindd_pam.c
@@ -2014,6 +2014,10 @@ void winbindd_pam_chauthtok(struct winbindd_cli_state *state)
struct winbindd_domain *contact_domain;
NTSTATUS nt_status = NT_STATUS_UNSUCCESSFUL;
+ /* Ensure null termination */
+ state->request->data.chauthtok.user[
+ sizeof(state->request->data.chauthtok.user)-1]='\0';
+
DEBUG(3, ("[%5lu]: pam chauthtok %s\n", (unsigned long)state->pid,
state->request->data.chauthtok.user));