[gnutls-devel] GnuTLS | nettle/rnd-fips: add FIPS 140-2 continuous RNG test (!1034)

Development of GNU's TLS library gnutls-devel at lists.gnutls.org
Tue Jun 25 14:58:44 CEST 2019




Nikos Mavrogiannopoulos commented on a discussion on lib/nettle/rnd-fips.c: https://gitlab.com/gnutls/gnutls/merge_requests/1034#note_185146804

> -	if (ret < 0)
> -		return gnutls_assert_val(ret);
> -
> -	ret = drbg_aes_init(ctx, sizeof(buffer), buffer, PSTRING_SIZE, (void*)PSTRING);
> +	ret = drbg_aes_init(ctx, length, buffer, PSTRING_SIZE, (void*)PSTRING);
>  	if (ret == 0)
>  		return gnutls_assert_val(GNUTLS_E_RANDOM_FAILED);
>  
> -	zeroize_key(buffer, sizeof(buffer));
> -
>  	return 0;
>  }
>  
>  /* Reseed a generator. */
> -static int drbg_reseed(struct drbg_aes_ctx *ctx)
> +static int drbg_reseed(struct drbg_aes_ctx *ctx,

Alternatively, why not pass the fips context and do the call to get_entropy as before?

-- 
Reply to this email directly or view it on GitLab: https://gitlab.com/gnutls/gnutls/merge_requests/1034#note_185146804
You're receiving this email because of your account on gitlab.com.


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.gnupg.org/pipermail/gnutls-devel/attachments/20190625/ab1af20a/attachment-0001.html>


More information about the Gnutls-devel mailing list