From 0fca588275c58e5db940deed12db9e4958a961b6 Mon Sep 17 00:00:00 2001 From: Mounir IDRASSI Date: Sun, 24 Jul 2016 23:39:33 +0200 Subject: Crypto: Workaround for AES-NI issue under Hyper-V on Windows Server 2008 R2 which masks AES-NI from applications although it is available. --- src/Common/Crypto.c | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'src/Common/Crypto.c') diff --git a/src/Common/Crypto.c b/src/Common/Crypto.c index 134a1715..dea4ff02 100644 --- a/src/Common/Crypto.c +++ b/src/Common/Crypto.c @@ -21,6 +21,7 @@ #include "EncryptionThreadPool.h" #endif #include "Volumes.h" +#include "cpu.h" /* Update the following when adding a new cipher or EA: @@ -1051,7 +1052,11 @@ BOOL IsAesHwCpuSupported () if (!stateValid) { +#ifdef TC_WINDOWS_BOOT_AES state = is_aes_hw_cpu_supported() ? TRUE : FALSE; +#else + state = g_hasAESNI ? TRUE : FALSE; +#endif stateValid = TRUE; } -- cgit v1.2.3