aboutsummaryrefslogtreecommitdiffstats
path: root/crypto/dsa/dsatest.c
diff options
context:
space:
mode:
authorGeoff Thorpe <geoff@openssl.org>2001-09-25 20:23:40 +0000
committerGeoff Thorpe <geoff@openssl.org>2001-09-25 20:23:40 +0000
commitcb78486d97328121add07df466b7578076650a90 (patch)
tree44de53e7516cf07786dcfaa9add109319fad16ac /crypto/dsa/dsatest.c
parent9c9aa4f145588500cd2d734d1901a31039f145b9 (diff)
downloadopenssl-cb78486d97328121add07df466b7578076650a90.tar.gz
This commits changes to various parts of libcrypto required by the recent
ENGINE surgery. DH, DSA, RAND, and RSA now use *both* "method" and ENGINE pointers to manage their hooking with ENGINE. Previously their use of "method" pointers was replaced by use of ENGINE references. See crypto/engine/README for details. Also, remove the ENGINE iterations from evp_test - even when the cipher/digest code is committed in, this functionality would require a different set of API calls.
Diffstat (limited to 'crypto/dsa/dsatest.c')
-rw-r--r--crypto/dsa/dsatest.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/crypto/dsa/dsatest.c b/crypto/dsa/dsatest.c
index 5f24b59554..12da64f9f4 100644
--- a/crypto/dsa/dsatest.c
+++ b/crypto/dsa/dsatest.c
@@ -65,6 +65,7 @@
#include <openssl/rand.h>
#include <openssl/bio.h>
#include <openssl/err.h>
+#include <openssl/engine.h>
#ifdef OPENSSL_SYS_WINDOWS
#include "../bio/bss_file.c"
#endif
@@ -136,9 +137,6 @@ int main(int argc, char **argv)
unsigned char sig[256];
unsigned int siglen;
- ERR_load_crypto_strings();
- RAND_seed(rnd_seed, sizeof rnd_seed);
-
if (bio_err == NULL)
bio_err=BIO_new_fp(stderr,BIO_NOCLOSE);
@@ -146,6 +144,9 @@ int main(int argc, char **argv)
CRYPTO_dbg_set_options(V_CRYPTO_MDEBUG_ALL);
CRYPTO_mem_ctrl(CRYPTO_MEM_CHECK_ON);
+ ERR_load_crypto_strings();
+ RAND_seed(rnd_seed, sizeof rnd_seed);
+
BIO_printf(bio_err,"test generation of DSA parameters\n");
dsa=DSA_generate_parameters(512,seed,20,&counter,&h,dsa_cb,bio_err);
@@ -204,6 +205,7 @@ end:
if (dsa != NULL) DSA_free(dsa);
CRYPTO_cleanup_all_ex_data();
ERR_remove_state(0);
+ ERR_free_strings();
CRYPTO_mem_leaks(bio_err);
if (bio_err != NULL)
{