HomePhabricator

Fix crypto_free zeroing of encryption keys

Authored by Simo Sorce <simo@redhat.com> on Oct 3 2018, 3:14 PM.

Description

Fix crypto_free zeroing of encryption keys

The zeroing MUST use the correct cipher length as keys can be both
longer or shorter than the digest. In one case only some part of the key
may end up being zeroed, in the other memory corruption may happen as
we zero memory we do not own.

Signed-off-by: Simo Sorce <simo@redhat.com>
Reviewed-by: Anderson Toshiyuki Sasaki <ansasaki@redhat.com>
Reviewed-by: Andreas Schneider <asn@cryptomilk.org>

Details

Committed
asnThu, Mar 7, 12:02 PM
Parents
rLIBSSH7c444c09d7bd: sftp: Document how to free memory retruned by sftp_canonicalize_path()
Branches
Unknown
Tags
Unknown

Event Timeline