From 25c3d15ed7edcb8483dc3de7a55cf4579f6504c4 Mon Sep 17 00:00:00 2001 From: Mounir IDRASSI Date: Sun, 28 Dec 2014 19:04:05 +0100 Subject: Windows: support loading TrueCrypt volumes. Implement converting TrueCrypt volumes to VeraCrypt using the change password functionality. --- src/Common/Pkcs5.c | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) (limited to 'src/Common/Pkcs5.c') diff --git a/src/Common/Pkcs5.c b/src/Common/Pkcs5.c index 8f0c3645..e522a360 100644 --- a/src/Common/Pkcs5.c +++ b/src/Common/Pkcs5.c @@ -665,19 +665,22 @@ char *get_pkcs5_prf_name (int pkcs5_prf_id) -int get_pkcs5_iteration_count (int pkcs5_prf_id, BOOL bBoot) +int get_pkcs5_iteration_count (int pkcs5_prf_id, BOOL truecryptMode, BOOL bBoot) { switch (pkcs5_prf_id) { case RIPEMD160: - return bBoot? 327661 : 655331; + if (truecryptMode) + return bBoot ? 1000 : 2000; + else + return bBoot? 327661 : 655331; case SHA512: - return 500000; + return truecryptMode? 1000 : 500000; case WHIRLPOOL: - return 500000; + return truecryptMode? 1000 : 500000; case SHA256: return bBoot? 200000 : 500000; -- cgit v1.2.3