VeraCrypt
aboutsummaryrefslogtreecommitdiff
path: root/src/Crypto/Aeskey.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/Crypto/Aeskey.c')
-rw-r--r--src/Crypto/Aeskey.c13
1 files changed, 13 insertions, 0 deletions
diff --git a/src/Crypto/Aeskey.c b/src/Crypto/Aeskey.c
index c9ab0269..9b7bfd18 100644
--- a/src/Crypto/Aeskey.c
+++ b/src/Crypto/Aeskey.c
@@ -26,8 +26,9 @@
*/
#include "Aesopt.h"
#include "Aestab.h"
+#include "Common/Tcdefs.h"
#ifdef USE_VIA_ACE_IF_PRESENT
# include "aes_via_ace.h"
#endif
@@ -94,8 +95,10 @@ AES_RETURN aes_encrypt_key128(const unsigned char *key, aes_encrypt_ctx cx[1])
if(VIA_ACE_AVAILABLE)
cx->inf.b[1] = 0xff;
#endif
+ burn(ss, sizeof(ss));
+
#if defined( AES_ERR_CHK )
return EXIT_SUCCESS;
#endif
}
@@ -146,8 +149,10 @@ AES_RETURN aes_encrypt_key192(const unsigned char *key, aes_encrypt_ctx cx[1])
if(VIA_ACE_AVAILABLE)
cx->inf.b[1] = 0xff;
#endif
+ burn(ss, sizeof(ss));
+
#if defined( AES_ERR_CHK )
return EXIT_SUCCESS;
#endif
}
@@ -201,8 +206,10 @@ AES_RETURN aes_encrypt_key256(const unsigned char *key, aes_encrypt_ctx cx[1])
if(VIA_ACE_AVAILABLE)
cx->inf.b[1] = 0xff;
#endif
+ burn(ss, sizeof(ss));
+
#if defined( AES_ERR_CHK )
return EXIT_SUCCESS;
#endif
}
@@ -351,8 +358,10 @@ AES_RETURN aes_decrypt_key128(const unsigned char *key, aes_decrypt_ctx cx[1])
if(VIA_ACE_AVAILABLE)
cx->inf.b[1] = 0xff;
#endif
+ burn(ss, sizeof(ss));
+
#if defined( AES_ERR_CHK )
return EXIT_SUCCESS;
#endif
}
@@ -438,8 +447,10 @@ AES_RETURN aes_decrypt_key192(const unsigned char *key, aes_decrypt_ctx cx[1])
if(VIA_ACE_AVAILABLE)
cx->inf.b[1] = 0xff;
#endif
+ burn(ss, sizeof(ss));
+
#if defined( AES_ERR_CHK )
return EXIT_SUCCESS;
#endif
}
@@ -537,8 +548,10 @@ AES_RETURN aes_decrypt_key256(const unsigned char *key, aes_decrypt_ctx cx[1])
if(VIA_ACE_AVAILABLE)
cx->inf.b[1] = 0xff;
#endif
+ burn(ss, sizeof(ss));
+
#if defined( AES_ERR_CHK )
return EXIT_SUCCESS;
#endif
}