(krb5_generate_random_block): check return value from RAND_bytes
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@16748 ec53bebd-3082-4978-b11e-865c3cabbd6b
This commit is contained in:
@@ -3789,7 +3789,8 @@ krb5_generate_random_block(void *buf, size_t len)
|
|||||||
rng_initialized = 1;
|
rng_initialized = 1;
|
||||||
}
|
}
|
||||||
HEIMDAL_MUTEX_unlock(&crypto_mutex);
|
HEIMDAL_MUTEX_unlock(&crypto_mutex);
|
||||||
RAND_bytes(buf, len);
|
if (RAND_bytes(buf, len) != 1)
|
||||||
|
krb5_abortx(NULL, "Failed to generate random block");
|
||||||
}
|
}
|
||||||
|
|
||||||
#else
|
#else
|
||||||
|
Reference in New Issue
Block a user