changed RNG_REAL to RNG_TRUE

This commit is contained in:
Andreas Steffen
2009-04-29 09:13:20 +00:00
parent de92b9e70c
commit f67eebccc8
9 changed files with 12 additions and 12 deletions
@@ -141,10 +141,10 @@ static status_t compute_prime(private_gmp_rsa_private_key_t *this,
rng_t *rng;
chunk_t random_bytes;
rng = lib->crypto->create_rng(lib->crypto, RNG_REAL);
rng = lib->crypto->create_rng(lib->crypto, RNG_TRUE);
if (!rng)
{
DBG1("no RNG of quality %N found", rng_quality_names, RNG_REAL);
DBG1("no RNG of quality %N found", rng_quality_names, RNG_TRUE);
return FAILED;
}
@@ -159,7 +159,7 @@ plugin_t *plugin_create()
if (this->features & PADLOCK_RNG_ENABLED)
{
lib->crypto->add_rng(lib->crypto, RNG_REAL,
lib->crypto->add_rng(lib->crypto, RNG_TRUE,
(rng_constructor_t)padlock_rng_create);
lib->crypto->add_rng(lib->crypto, RNG_STRONG,
(rng_constructor_t)padlock_rng_create);
@@ -126,7 +126,7 @@ padlock_rng_t *padlock_rng_create(rng_quality_t quality)
case RNG_STRONG:
this->quality = PADLOCK_QF1;
break;
case RNG_REAL:
case RNG_TRUE:
this->quality = PADLOCK_QF3;
break;
}
@@ -54,7 +54,7 @@ plugin_t *plugin_create()
lib->crypto->add_rng(lib->crypto, RNG_STRONG,
(rng_constructor_t)random_rng_create);
lib->crypto->add_rng(lib->crypto, RNG_REAL,
lib->crypto->add_rng(lib->crypto, RNG_TRUE,
(rng_constructor_t)random_rng_create);
return &this->public.plugin;
@@ -114,7 +114,7 @@ random_rng_t *random_rng_create(rng_quality_t quality)
this->public.rng.allocate_bytes = (void (*) (rng_t *, size_t, chunk_t*)) allocate_bytes;
this->public.rng.destroy = (void (*) (rng_t *))destroy;
if (quality == RNG_REAL)
if (quality == RNG_TRUE)
{
this->file = DEV_RANDOM;
}