From b583af94a59caa3ea3a379709149899062931b25 Mon Sep 17 00:00:00 2001 From: Johny Mattsson Date: Thu, 23 Jul 2015 16:48:59 +1000 Subject: [PATCH] Fixed long key bug in HMAC calculation. --- app/crypto/digests.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/crypto/digests.c b/app/crypto/digests.c index ccac6e67..e68cdb95 100644 --- a/app/crypto/digests.c +++ b/app/crypto/digests.c @@ -140,7 +140,7 @@ int ICACHE_FLASH_ATTR crypto_hmac (const digest_mech_info_t *mi, mi->update (ctx, key, key_len); mi->finalize (digest, ctx); key = digest; - key_len = mi->block_size; + key_len = mi->digest_size; } const size_t bs = mi->block_size;