diff options
author | Mounir IDRASSI <mounir.idrassi@idrix.fr> | 2016-08-15 14:17:59 +0200 |
---|---|---|
committer | Mounir IDRASSI <mounir.idrassi@idrix.fr> | 2016-08-15 14:19:11 +0200 |
commit | 5d5a645083c8eb885b0820361e5f49b1af2a2737 (patch) | |
tree | 30d4519cd6274c4933b51ef3f2eff8a7b0913c62 /src/Common/Volumes.c | |
parent | 15069164872bc6324a9c4201b91329d92cd23cfa (diff) | |
download | VeraCrypt-5d5a645083c8eb885b0820361e5f49b1af2a2737.tar.gz VeraCrypt-5d5a645083c8eb885b0820361e5f49b1af2a2737.zip |
Windows: fix error caused by requesting large number of random bytes when writing randomly generated data to unused/reserved header areas.
Diffstat (limited to 'src/Common/Volumes.c')
-rw-r--r-- | src/Common/Volumes.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/Common/Volumes.c b/src/Common/Volumes.c index 3228aadc..67b072d6 100644 --- a/src/Common/Volumes.c +++ b/src/Common/Volumes.c @@ -1302,7 +1302,7 @@ int WriteRandomDataToReservedHeaderAreas (HWND hwndDlg, HANDLE dev, CRYPTO_INFO { // encrypt random data instead of existing data for better entropy, except in case of primary // header of an in-place encrypted disk - RandgetBytes (hwndDlg, buf + TC_VOLUME_HEADER_EFFECTIVE_SIZE, sizeof (buf) - TC_VOLUME_HEADER_EFFECTIVE_SIZE, FALSE); + RandgetBytesFull (hwndDlg, buf + TC_VOLUME_HEADER_EFFECTIVE_SIZE, sizeof (buf) - TC_VOLUME_HEADER_EFFECTIVE_SIZE, FALSE, TRUE); } EncryptBuffer (buf + TC_VOLUME_HEADER_EFFECTIVE_SIZE, sizeof (buf) - TC_VOLUME_HEADER_EFFECTIVE_SIZE, cryptoInfo); |