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-04 13:42:11 +0200
commit1744d407fdd132a9141a88bdcbaecd7ae329f134 (patch)
treea1dfb131df3acd0906c814fc993d43660f4aeaed
parent73c8cd1f83754bb588f019f7450a914ea18cc49a (diff)
downloadgnutls-1744d407fdd132a9141a88bdcbaecd7ae329f134.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;
}