Mercurial > dropbear
comparison svr-authpam.c @ 1629:258b57b208ae
Fix for issue successfull login of disabled user (#78)
This commit introduces fix for scenario:
1. Root login disabled on dropbear
2. PAM authentication model enabled
While login as root user, after prompt for password
user is being notified about login failrue, but
after second attempt of prompt for password within
same session, login becames succesfull.
Signed-off-by: Pawel Rapkiewicz <[email protected]>
author | vincentto13 <33652988+vincentto13@users.noreply.github.com> |
---|---|
date | Wed, 20 Mar 2019 15:03:40 +0100 |
parents | 5d2d1021ca00 |
children |
comparison
equal
deleted
inserted
replaced
1628:ff3f274ea56c | 1629:258b57b208ae |
---|---|
273 | 273 |
274 if (!valid_user) { | 274 if (!valid_user) { |
275 /* PAM auth succeeded but the username isn't allowed in for another reason | 275 /* PAM auth succeeded but the username isn't allowed in for another reason |
276 (checkusername() failed) */ | 276 (checkusername() failed) */ |
277 send_msg_userauth_failure(0, 1); | 277 send_msg_userauth_failure(0, 1); |
278 goto cleanup; | |
278 } | 279 } |
279 | 280 |
280 /* successful authentication */ | 281 /* successful authentication */ |
281 dropbear_log(LOG_NOTICE, "PAM password auth succeeded for '%s' from %s", | 282 dropbear_log(LOG_NOTICE, "PAM password auth succeeded for '%s' from %s", |
282 ses.authstate.pw_name, | 283 ses.authstate.pw_name, |