[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH] messages: use predefined macro for clearing sensitive data
[Thread Prev] | [Thread Next]
- Subject: [PATCH] messages: use predefined macro for clearing sensitive data
- From: Luka Perkov <luka.perkov@xxxxxxxxxx>
- Reply-to: libssh@xxxxxxxxxx
- Date: Thu, 20 Mar 2014 22:54:17 +0000
- To: libssh@xxxxxxxxxx
- Cc: Luka Perkov <luka.perkov@xxxxxxxxxx>
Signed-off-by: Luka Perkov <luka.perkov@xxxxxxxxxx> --- src/messages.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/messages.c b/src/messages.c index 4246c63..e7bf39f 100644 --- a/src/messages.c +++ b/src/messages.c @@ -508,8 +508,7 @@ void ssh_message_free(ssh_message msg){ case SSH_REQUEST_AUTH: SAFE_FREE(msg->auth_request.username); if (msg->auth_request.password) { - memset(msg->auth_request.password, 0, - strlen(msg->auth_request.password)); + BURN_STRING(msg->auth_request.password); SAFE_FREE(msg->auth_request.password); } ssh_key_free(msg->auth_request.pubkey); -- 1.9.1
Archive administrator: postmaster@lists.cynapses.org