VeraCrypt
aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorMounir IDRASSI <mounir.idrassi@idrix.fr>2014-06-03 09:09:09 +0200
committerMounir IDRASSI <mounir.idrassi@idrix.fr>2014-11-08 23:19:13 +0100
commit9b19baf73e8c9dbd60ee36bcd1cb910bf01fa3d7 (patch)
tree4ed3dbd241fdb60485f00776908fa6a301bc2562 /src
parent5ebd79745d84faa9fb352ed2bc58931f37975d85 (diff)
downloadVeraCrypt-9b19baf73e8c9dbd60ee36bcd1cb910bf01fa3d7.tar.gz
VeraCrypt-9b19baf73e8c9dbd60ee36bcd1cb910bf01fa3d7.zip
use burn instead of memset when clearing RIPEMD context to ensure the compiler won't optimize it
Diffstat (limited to 'src')
-rw-r--r--src/Crypto/Rmd160.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/Crypto/Rmd160.c b/src/Crypto/Rmd160.c
index cd215668..f90bf296 100644
--- a/src/Crypto/Rmd160.c
+++ b/src/Crypto/Rmd160.c
@@ -140,7 +140,7 @@ void RMD160Final(unsigned char *digest, RMD160_CTX *ctx)
if (digest) {
for (i = 0; i < 5; i++)
PUT_32BIT_LE(digest + i * 4, ctx->state[i]);
- memset (ctx, 0, sizeof(*ctx));
+ burn (ctx, sizeof(*ctx));
}
}