summaryrefslogtreecommitdiffstats
path: root/sys/geom
diff options
context:
space:
mode:
authordelphij <delphij@FreeBSD.org>2014-02-22 00:30:33 +0000
committerdelphij <delphij@FreeBSD.org>2014-02-22 00:30:33 +0000
commit4d109458105a7906bfebae94d6a703111555c925 (patch)
tree1eecd0857baa4a8ac51d1f2338d726345f7cd222 /sys/geom
parent6e3a96834a9382ab2242aa2df7de41f16f7c82c6 (diff)
downloadFreeBSD-src-4d109458105a7906bfebae94d6a703111555c925.zip
FreeBSD-src-4d109458105a7906bfebae94d6a703111555c925.tar.gz
MFC r261618:
In g_eli_crypto_hmac_init(), zero out after using the ipad buffer, k_ipad. Note that the two consumers in geli(4) are not affected by this issue because the way the code is constructed and as such, we believe there is no security impact with or without this change with geli(4)'s usage. Reported by: Serge van den Boom <serge vdboom.org> Reviewed by: pjd
Diffstat (limited to 'sys/geom')
-rw-r--r--sys/geom/eli/g_eli_crypto.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/sys/geom/eli/g_eli_crypto.c b/sys/geom/eli/g_eli_crypto.c
index 8cf9ec1..91c36ec 100644
--- a/sys/geom/eli/g_eli_crypto.c
+++ b/sys/geom/eli/g_eli_crypto.c
@@ -265,6 +265,7 @@ g_eli_crypto_hmac_init(struct hmac_ctx *ctx, const uint8_t *hkey,
/* Perform inner SHA512. */
SHA512_Init(&ctx->shactx);
SHA512_Update(&ctx->shactx, k_ipad, sizeof(k_ipad));
+ bzero(k_ipad, sizeof(k_ipad));
}
void
OpenPOWER on IntegriCloud