mirror of
https://github.com/clearml/dropbear
synced 2025-02-07 13:21:15 +00:00
burn the buffer a bit earlier
--HG-- extra : convert_revision : 1f069f6a8a2ecee6f2e22b51751b73982606accb
This commit is contained in:
parent
418f3b4042
commit
2a2fdc168c
@ -87,6 +87,8 @@ void svr_auth_password() {
|
|||||||
|
|
||||||
/* the first bytes of passwdcrypt are the salt */
|
/* the first bytes of passwdcrypt are the salt */
|
||||||
testcrypt = crypt((char*)password, passwdcrypt);
|
testcrypt = crypt((char*)password, passwdcrypt);
|
||||||
|
m_burn(password, passwordlen);
|
||||||
|
m_free(password);
|
||||||
|
|
||||||
if (strcmp(testcrypt, passwdcrypt) == 0) {
|
if (strcmp(testcrypt, passwdcrypt) == 0) {
|
||||||
/* successful authentication */
|
/* successful authentication */
|
||||||
@ -101,8 +103,6 @@ void svr_auth_password() {
|
|||||||
send_msg_userauth_failure(0, 1);
|
send_msg_userauth_failure(0, 1);
|
||||||
}
|
}
|
||||||
|
|
||||||
m_burn(password, passwordlen);
|
|
||||||
m_free(password);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
#endif /* DROPBEAR_PASSWORD_AUTH */
|
#endif /* DROPBEAR_PASSWORD_AUTH */
|
||||||
|
Loading…
Reference in New Issue
Block a user