diff options
author | Bodo Möller <bodo@openssl.org> | 2000-01-14 18:43:22 +0000 |
---|---|---|
committer | Bodo Möller <bodo@openssl.org> | 2000-01-14 18:43:22 +0000 |
commit | 105c0be00fc59c3f550c95a73ce683369a4da1aa (patch) | |
tree | 8d55227f8c4a5b92f39c5071ea14e02f4b431516 /crypto/rsa | |
parent | 7f5b6f0f19fd30356807a0010053c28a3a66b870 (diff) |
Let "make test" survive without DEVRANDOM
(and rename a target in test/Makefile.ssl to make it
easier to guess the name of the file executed by it)
Diffstat (limited to 'crypto/rsa')
-rw-r--r-- | crypto/rsa/rsa_oaep_test.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/crypto/rsa/rsa_oaep_test.c b/crypto/rsa/rsa_oaep_test.c index 9405e88f1a..e5ae0c1f69 100644 --- a/crypto/rsa/rsa_oaep_test.c +++ b/crypto/rsa/rsa_oaep_test.c @@ -7,6 +7,7 @@ #include <openssl/crypto.h> #include <openssl/err.h> +#include <openssl/rand.h> #ifdef NO_RSA int main(int argc, char *argv[]) { @@ -203,6 +204,8 @@ static int pad_unknown(void) return(0); } +static const char rnd_seed[] = "string to make the random number generator think it has entropy"; + int main(int argc, char *argv[]) { int err=0; @@ -216,6 +219,8 @@ int main(int argc, char *argv[]) int clen = 0; int num; + RAND_seed(rnd_seed, sizeof rnd_seed); /* or OAEP may fail */ + CRYPTO_mem_ctrl(CRYPTO_MEM_CHECK_ON); plen = sizeof(ptext_ex) - 1; |