summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNikos Mavrogiannopoulos <nmav@redhat.com>2015-06-03 15:38:09 +0200
committerNikos Mavrogiannopoulos <nmav@redhat.com>2015-06-03 15:38:09 +0200
commit3171e74eb8fdb2ce3096a82bae35fe068ab459f1 (patch)
treefde0cb72235275b3f6289115d59770445d7a7226
parent5b01b381efee128852042a353ab664516385da07 (diff)
downloadgnutls-3171e74eb8fdb2ce3096a82bae35fe068ab459f1.tar.gz
fips140: reset the reseed counter only on reseed
-rw-r--r--lib/nettle/int/drbg-aes.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/nettle/int/drbg-aes.c b/lib/nettle/int/drbg-aes.c
index 6835385356..f8b693bcd1 100644
--- a/lib/nettle/int/drbg-aes.c
+++ b/lib/nettle/int/drbg-aes.c
@@ -67,7 +67,6 @@ drbg_aes_update(struct drbg_aes_ctx *ctx,
memcpy(ctx->v, &tmp[DRBG_AES_KEY_SIZE], AES_BLOCK_SIZE);
- ctx->reseed_counter = 1;
ctx->seeded = 1;
}
@@ -93,6 +92,7 @@ drbg_aes_reseed(struct drbg_aes_ctx *ctx,
memxor(tmp, entropy, entropy_size);
drbg_aes_update(ctx, tmp);
+ ctx->reseed_counter = 1;
return 1;
}