Re: [PATCH v2 1/6] SP800-90A Deterministic Random Bit Generator

2014-03-20 Thread Stephan Mueller
Am Donnerstag, 20. März 2014, 09:12:55 schrieb Clemens Ladisch: Hi Clemens, > Stephan Mueller wrote: > > This is a clean-room implementation of the DRBG defined in SP800-90A. > > Why? I guess it's for certification? As per SP800-131A, the ANSI X9.31 DRNG is sunset by the end of 2014 and not

Re: [PATCH v2 1/6] SP800-90A Deterministic Random Bit Generator

2014-03-20 Thread Clemens Ladisch
Stephan Mueller wrote: > This is a clean-room implementation of the DRBG defined in SP800-90A. Why? I guess it's for certification? > +static bool drbg_fips_continuous_test(struct drbg_state *drbg, > + unsigned char *buf) > ... > + ret = memcmp(drbg->prev,

Re: [PATCH v2 1/6] SP800-90A Deterministic Random Bit Generator

2014-03-20 Thread Clemens Ladisch
Stephan Mueller wrote: This is a clean-room implementation of the DRBG defined in SP800-90A. Why? I guess it's for certification? +static bool drbg_fips_continuous_test(struct drbg_state *drbg, + unsigned char *buf) ... + ret = memcmp(drbg-prev, buf,

Re: [PATCH v2 1/6] SP800-90A Deterministic Random Bit Generator

2014-03-20 Thread Stephan Mueller
Am Donnerstag, 20. März 2014, 09:12:55 schrieb Clemens Ladisch: Hi Clemens, Stephan Mueller wrote: This is a clean-room implementation of the DRBG defined in SP800-90A. Why? I guess it's for certification? As per SP800-131A, the ANSI X9.31 DRNG is sunset by the end of 2014 and not

Re: [PATCH v2 1/6] SP800-90A Deterministic Random Bit Generator

2014-03-19 Thread Stephan Mueller
Am Montag, 17. März 2014, 08:34:06 schrieb Stephan Mueller: > +static int drbg_seed(struct drbg_state *drbg, struct drbg_string *pers, > + bool reseed) > +{ > + int ret = 0; > + unsigned char *entropy = NULL; > + size_t entropylen = 0; > + struct drbg_string

Re: [PATCH v2 1/6] SP800-90A Deterministic Random Bit Generator

2014-03-19 Thread Stephan Mueller
Am Montag, 17. März 2014, 08:34:06 schrieb Stephan Mueller: +static int drbg_seed(struct drbg_state *drbg, struct drbg_string *pers, + bool reseed) +{ + int ret = 0; + unsigned char *entropy = NULL; + size_t entropylen = 0; + struct drbg_string data1; +