diff options
Diffstat (limited to 'mod_authnz_pam.c')
-rw-r--r-- | mod_authnz_pam.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/mod_authnz_pam.c b/mod_authnz_pam.c index 968b567..87d3150 100644 --- a/mod_authnz_pam.c +++ b/mod_authnz_pam.c @@ -61,7 +61,11 @@ static int pam_authenticate_conv(int num_msg, const struct pam_message ** msg, s response[i].resp = 0; response[i].resp_retcode = 0; if (msg[i]->msg_style == PAM_PROMPT_ECHO_OFF) { - response[i].resp = strdup(appdata_ptr); + if (i == 0) { + response[i].resp = strdup(appdata_ptr); + } else { + response[i].resp = NULL; + } } else { free(response); return PAM_CONV_ERR; |