Loading apps/apps.c +5 −1 Original line number Diff line number Diff line Loading @@ -1535,11 +1535,13 @@ static ENGINE *try_load_engine(BIO *err, const char *engine, int debug) } return e; } #endif ENGINE *setup_engine(BIO *err, const char *engine, int debug) { ENGINE *e = NULL; #ifndef OPENSSL_NO_ENGINE if (engine) { if (strcmp(engine, "auto") == 0) { BIO_printf(err, "enabling auto ENGINE support\n"); Loading @@ -1565,16 +1567,18 @@ ENGINE *setup_engine(BIO *err, const char *engine, int debug) BIO_printf(err, "engine \"%s\" set.\n", ENGINE_get_id(e)); } #endif return e; } void release_engine(ENGINE *e) { #ifndef OPENSSL_NO_ENGINE if (e != NULL) /* Free our "structural" reference. */ ENGINE_free(e); } #endif } int load_config(BIO *err, CONF *cnf) { Loading apps/apps.h +1 −2 Original line number Diff line number Diff line Loading @@ -259,10 +259,9 @@ STACK_OF(X509_CRL) *load_crls(BIO *err, const char *file, int format, const char *pass, ENGINE *e, const char *cert_descrip); X509_STORE *setup_verify(BIO *bp, char *CAfile, char *CApath); # ifndef OPENSSL_NO_ENGINE ENGINE *setup_engine(BIO *err, const char *engine, int debug); void release_engine(ENGINE *e); # endif # ifndef OPENSSL_NO_OCSP OCSP_RESPONSE *process_responder(BIO *err, OCSP_REQUEST *req, Loading apps/ca.c +1 −8 Original line number Diff line number Diff line Loading @@ -319,9 +319,7 @@ int MAIN(int argc, char **argv) #define BSIZE 256 MS_STATIC char buf[3][BSIZE]; char *randfile = NULL; #ifndef OPENSSL_NO_ENGINE char *engine = NULL; #endif char *tofree = NULL; DB_ATTR db_attr; Loading Loading @@ -595,9 +593,7 @@ int MAIN(int argc, char **argv) if (!load_config(bio_err, conf)) goto err; #ifndef OPENSSL_NO_ENGINE e = setup_engine(bio_err, engine, 0); #endif /* Lets get the config section we are using */ if (section == NULL) { Loading Loading @@ -1485,10 +1481,7 @@ int MAIN(int argc, char **argv) X509_CRL_free(crl); NCONF_free(conf); NCONF_free(extconf); #ifndef OPENSSL_NO_ENGINE if (e != NULL) release_engine(e); #endif OBJ_cleanup(); apps_shutdown(); OPENSSL_EXIT(ret); Loading apps/cms.c +1 −8 Original line number Diff line number Diff line Loading @@ -143,9 +143,7 @@ int MAIN(int argc, char **argv) const EVP_MD *sign_md = NULL; int informat = FORMAT_SMIME, outformat = FORMAT_SMIME; int rctformat = FORMAT_SMIME, keyform = FORMAT_PEM; # ifndef OPENSSL_NO_ENGINE char *engine = NULL; # endif unsigned char *secret_key = NULL, *secret_keyid = NULL; unsigned char *pwri_pass = NULL, *pwri_tmp = NULL; size_t secret_keylen = 0, secret_keyidlen = 0; Loading Loading @@ -665,9 +663,7 @@ int MAIN(int argc, char **argv) "cert.pem recipient certificate(s) for encryption\n"); goto end; } # ifndef OPENSSL_NO_ENGINE e = setup_engine(bio_err, engine, 0); # endif if (!app_passwd(bio_err, passargin, NULL, &passin, NULL)) { BIO_printf(bio_err, "Error getting password\n"); Loading Loading @@ -1170,10 +1166,7 @@ int MAIN(int argc, char **argv) EVP_PKEY_free(key); CMS_ContentInfo_free(cms); CMS_ContentInfo_free(rcms); #ifndef OPENSSL_NO_ENGINE if (e != NULL) release_engine(e); #endif BIO_free(rctin); BIO_free(in); BIO_free(indata); Loading apps/dgst.c +1 −4 Original line number Diff line number Diff line Loading @@ -537,10 +537,7 @@ int MAIN(int argc, char **argv) OPENSSL_free(sigbuf); if (bmd != NULL) BIO_free(bmd); #ifndef OPENSSL_NO_ENGINE if (e != NULL) release_engine(e); #endif apps_shutdown(); OPENSSL_EXIT(err); } Loading Loading
apps/apps.c +5 −1 Original line number Diff line number Diff line Loading @@ -1535,11 +1535,13 @@ static ENGINE *try_load_engine(BIO *err, const char *engine, int debug) } return e; } #endif ENGINE *setup_engine(BIO *err, const char *engine, int debug) { ENGINE *e = NULL; #ifndef OPENSSL_NO_ENGINE if (engine) { if (strcmp(engine, "auto") == 0) { BIO_printf(err, "enabling auto ENGINE support\n"); Loading @@ -1565,16 +1567,18 @@ ENGINE *setup_engine(BIO *err, const char *engine, int debug) BIO_printf(err, "engine \"%s\" set.\n", ENGINE_get_id(e)); } #endif return e; } void release_engine(ENGINE *e) { #ifndef OPENSSL_NO_ENGINE if (e != NULL) /* Free our "structural" reference. */ ENGINE_free(e); } #endif } int load_config(BIO *err, CONF *cnf) { Loading
apps/apps.h +1 −2 Original line number Diff line number Diff line Loading @@ -259,10 +259,9 @@ STACK_OF(X509_CRL) *load_crls(BIO *err, const char *file, int format, const char *pass, ENGINE *e, const char *cert_descrip); X509_STORE *setup_verify(BIO *bp, char *CAfile, char *CApath); # ifndef OPENSSL_NO_ENGINE ENGINE *setup_engine(BIO *err, const char *engine, int debug); void release_engine(ENGINE *e); # endif # ifndef OPENSSL_NO_OCSP OCSP_RESPONSE *process_responder(BIO *err, OCSP_REQUEST *req, Loading
apps/ca.c +1 −8 Original line number Diff line number Diff line Loading @@ -319,9 +319,7 @@ int MAIN(int argc, char **argv) #define BSIZE 256 MS_STATIC char buf[3][BSIZE]; char *randfile = NULL; #ifndef OPENSSL_NO_ENGINE char *engine = NULL; #endif char *tofree = NULL; DB_ATTR db_attr; Loading Loading @@ -595,9 +593,7 @@ int MAIN(int argc, char **argv) if (!load_config(bio_err, conf)) goto err; #ifndef OPENSSL_NO_ENGINE e = setup_engine(bio_err, engine, 0); #endif /* Lets get the config section we are using */ if (section == NULL) { Loading Loading @@ -1485,10 +1481,7 @@ int MAIN(int argc, char **argv) X509_CRL_free(crl); NCONF_free(conf); NCONF_free(extconf); #ifndef OPENSSL_NO_ENGINE if (e != NULL) release_engine(e); #endif OBJ_cleanup(); apps_shutdown(); OPENSSL_EXIT(ret); Loading
apps/cms.c +1 −8 Original line number Diff line number Diff line Loading @@ -143,9 +143,7 @@ int MAIN(int argc, char **argv) const EVP_MD *sign_md = NULL; int informat = FORMAT_SMIME, outformat = FORMAT_SMIME; int rctformat = FORMAT_SMIME, keyform = FORMAT_PEM; # ifndef OPENSSL_NO_ENGINE char *engine = NULL; # endif unsigned char *secret_key = NULL, *secret_keyid = NULL; unsigned char *pwri_pass = NULL, *pwri_tmp = NULL; size_t secret_keylen = 0, secret_keyidlen = 0; Loading Loading @@ -665,9 +663,7 @@ int MAIN(int argc, char **argv) "cert.pem recipient certificate(s) for encryption\n"); goto end; } # ifndef OPENSSL_NO_ENGINE e = setup_engine(bio_err, engine, 0); # endif if (!app_passwd(bio_err, passargin, NULL, &passin, NULL)) { BIO_printf(bio_err, "Error getting password\n"); Loading Loading @@ -1170,10 +1166,7 @@ int MAIN(int argc, char **argv) EVP_PKEY_free(key); CMS_ContentInfo_free(cms); CMS_ContentInfo_free(rcms); #ifndef OPENSSL_NO_ENGINE if (e != NULL) release_engine(e); #endif BIO_free(rctin); BIO_free(in); BIO_free(indata); Loading
apps/dgst.c +1 −4 Original line number Diff line number Diff line Loading @@ -537,10 +537,7 @@ int MAIN(int argc, char **argv) OPENSSL_free(sigbuf); if (bmd != NULL) BIO_free(bmd); #ifndef OPENSSL_NO_ENGINE if (e != NULL) release_engine(e); #endif apps_shutdown(); OPENSSL_EXIT(err); } Loading