mirror of
https://github.com/veracrypt/VeraCrypt
synced 2024-11-10 21:23:40 +01:00
Securely erase and protect buffer holding decrypted volume header.
This commit is contained in:
parent
7d6347f468
commit
8e2c5ca45e
@ -249,6 +249,7 @@ int ReadVolumeHeader (BOOL bBoot, char *encryptedHeader, Password *password, int
|
||||
#if !defined(DEVICE_DRIVER)
|
||||
VirtualLock (&keyInfo, sizeof (keyInfo));
|
||||
VirtualLock (&dk, sizeof (dk));
|
||||
VirtualLock (&header, sizeof (header));
|
||||
#endif
|
||||
#endif // !defined(_UEFI)
|
||||
|
||||
@ -571,10 +572,12 @@ KeyReady: ;
|
||||
ret:
|
||||
burn (&keyInfo, sizeof (keyInfo));
|
||||
burn (dk, sizeof(dk));
|
||||
burn (header, sizeof(header));
|
||||
|
||||
#if !defined(DEVICE_DRIVER) && !defined(_UEFI)
|
||||
VirtualUnlock (&keyInfo, sizeof (keyInfo));
|
||||
VirtualUnlock (&dk, sizeof (dk));
|
||||
VirtualUnlock (&header, sizeof (header));
|
||||
#endif
|
||||
|
||||
#if !defined(_UEFI)
|
||||
|
Loading…
Reference in New Issue
Block a user