Mercurial > dropbear
diff svr-authpasswd.c @ 809:0e17269254b6
merge
author | Matt Johnston <matt@ucc.asn.au> |
---|---|
date | Sun, 26 May 2013 18:42:17 +0800 |
parents | 7bd88d546627 |
children | a625f9e135a4 |
line wrap: on
line diff
--- a/svr-authpasswd.c Sun May 26 18:39:24 2013 +0800 +++ b/svr-authpasswd.c Sun May 26 18:42:17 2013 +0800 @@ -66,6 +66,14 @@ m_burn(password, passwordlen); m_free(password); + if (testcrypt == NULL) { + /* crypt() with an invalid salt like "!!" */ + dropbear_log(LOG_WARNING, "User account '%s' is locked", + ses.authstate.pw_name); + send_msg_userauth_failure(0, 1); + return; + } + /* check for empty password */ if (passwdcrypt[0] == '\0') { dropbear_log(LOG_WARNING, "User '%s' has blank password, rejected",