VeraCrypt
aboutsummaryrefslogtreecommitdiff
path: root/src/Common/EncryptionThreadPool.c
diff options
context:
space:
mode:
authorMounir IDRASSI <mounir.idrassi@idrix.fr>2014-10-14 17:14:54 +0200
committerMounir IDRASSI <mounir.idrassi@idrix.fr>2014-11-08 23:23:53 +0100
commit68f16dae244752e8bdf112e8feeb6a0839088a3e (patch)
tree94b1f5ab11b4d08661d838704bf08c14eb2e46a4 /src/Common/EncryptionThreadPool.c
parentf38cf0b6943da24c802424f53588b54aada48fd8 (diff)
downloadVeraCrypt-68f16dae244752e8bdf112e8feeb6a0839088a3e.tar.gz
VeraCrypt-68f16dae244752e8bdf112e8feeb6a0839088a3e.zip
Implement support for creating and booting encrypted partition using SHA-256. Support SHA-256 for normal volumes as well.
Diffstat (limited to 'src/Common/EncryptionThreadPool.c')
-rw-r--r--src/Common/EncryptionThreadPool.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/Common/EncryptionThreadPool.c b/src/Common/EncryptionThreadPool.c
index f213ea34..1ec78139 100644
--- a/src/Common/EncryptionThreadPool.c
+++ b/src/Common/EncryptionThreadPool.c
@@ -173,6 +173,11 @@ static TC_THREAD_PROC EncryptionThreadProc (void *threadArg)
workItem->KeyDerivation.IterationCount, workItem->KeyDerivation.DerivedKey, GetMaxPkcs5OutSize());
break;
+ case SHA256:
+ derive_key_sha256 (workItem->KeyDerivation.Password, workItem->KeyDerivation.PasswordLength, workItem->KeyDerivation.Salt, PKCS5_SALT_SIZE,
+ workItem->KeyDerivation.IterationCount, workItem->KeyDerivation.DerivedKey, GetMaxPkcs5OutSize());
+ break;
+
default:
TC_THROW_FATAL_EXCEPTION;
}