View | Details | Raw Unified | Return to bug 705 | Differences between
and this patch

Collapse All | Expand All

(-)auth-pam.c (-7 / +7 lines)
Lines 264-270 import_environments(Buffer *b) Link Here
264
 * Conversation function for authentication thread.
264
 * Conversation function for authentication thread.
265
 */
265
 */
266
static int
266
static int
267
sshpam_thread_conv(int n, const struct pam_message **msg,
267
sshpam_thread_conv(int n, struct pam_message **msg,
268
    struct pam_response **resp, void *data)
268
    struct pam_response **resp, void *data)
269
{
269
{
270
	Buffer buffer;
270
	Buffer buffer;
Lines 362-368 sshpam_thread(void *ctxtp) Link Here
362
	u_int i;
362
	u_int i;
363
	const char *pam_user;
363
	const char *pam_user;
364
364
365
	pam_get_item(sshpam_handle, PAM_USER, (const void **)&pam_user);
365
	pam_get_item(sshpam_handle, PAM_USER, (void **)&pam_user);
366
	setproctitle("%s [pam]", pam_user);
366
	setproctitle("%s [pam]", pam_user);
367
	environ[0] = NULL;
367
	environ[0] = NULL;
368
#endif
368
#endif
Lines 450-456 sshpam_thread_cleanup(void) Link Here
450
}
450
}
451
451
452
static int
452
static int
453
sshpam_null_conv(int n, const struct pam_message **msg,
453
sshpam_null_conv(int n, struct pam_message **msg,
454
    struct pam_response **resp, void *data)
454
    struct pam_response **resp, void *data)
455
{
455
{
456
	debug3("PAM: %s entering, %d messages", __func__, n);
456
	debug3("PAM: %s entering, %d messages", __func__, n);
Lines 488-494 sshpam_init(Authctxt *authctxt) Link Here
488
	if (sshpam_handle != NULL) {
488
	if (sshpam_handle != NULL) {
489
		/* We already have a PAM context; check if the user matches */
489
		/* We already have a PAM context; check if the user matches */
490
		sshpam_err = pam_get_item(sshpam_handle,
490
		sshpam_err = pam_get_item(sshpam_handle,
491
		    PAM_USER, (const void **)&pam_user);
491
		    PAM_USER, (void **)&pam_user);
492
		if (sshpam_err == PAM_SUCCESS && strcmp(user, pam_user) == 0)
492
		if (sshpam_err == PAM_SUCCESS && strcmp(user, pam_user) == 0)
493
			return (0);
493
			return (0);
494
		pam_end(sshpam_handle, sshpam_err);
494
		pam_end(sshpam_handle, sshpam_err);
Lines 786-792 do_pam_setcred(int init) Link Here
786
}
786
}
787
787
788
static int
788
static int
789
sshpam_tty_conv(int n, const struct pam_message **msg,
789
sshpam_tty_conv(int n, struct pam_message **msg,
790
    struct pam_response **resp, void *data)
790
    struct pam_response **resp, void *data)
791
{
791
{
792
	char input[PAM_MAX_MSG_SIZE];
792
	char input[PAM_MAX_MSG_SIZE];
Lines 863-869 do_pam_chauthtok(void) Link Here
863
}
863
}
864
864
865
static int
865
static int
866
sshpam_store_conv(int n, const struct pam_message **msg,
866
sshpam_store_conv(int n, struct pam_message **msg,
867
    struct pam_response **resp, void *data)
867
    struct pam_response **resp, void *data)
868
{
868
{
869
	struct pam_response *reply;
869
	struct pam_response *reply;
Lines 978-984 free_pam_environment(char **env) Link Here
978
 * display.
978
 * display.
979
 */
979
 */
980
static int
980
static int
981
sshpam_passwd_conv(int n, const struct pam_message **msg,
981
sshpam_passwd_conv(int n, struct pam_message **msg,
982
    struct pam_response **resp, void *data)
982
    struct pam_response **resp, void *data)
983
{
983
{
984
	struct pam_response *reply;
984
	struct pam_response *reply;

Return to bug 705