mirror of
https://gitlab.com/cryptsetup/cryptsetup.git
synced 2025-12-05 16:00:05 +01:00
Do not use uninitialized memory for cipher check.
We do not care about the bufer content, but valgrind do, just wipe the buffer before test.
This commit is contained in:
@@ -49,6 +49,7 @@ int LUKS2_check_cipher(struct crypt_device *cd,
|
||||
if (r < 0)
|
||||
goto out;
|
||||
|
||||
memset(buf, 0, sizeof(buf));
|
||||
r = crypt_storage_decrypt(s, 0, sizeof(buf), buf);
|
||||
crypt_storage_destroy(s);
|
||||
out:
|
||||
|
||||
Reference in New Issue
Block a user