Note: server-cmod doesn't seem to do things right... from loading
cmod.cnf, it tries to load libssl_conf.so.
Reviewed-by: Rich Salz <rsalz@openssl.org>
(cherry picked from commit
16c6deed2c42d4cf4a7676a32b718d6a867f482a)
const char *connect_str = "localhost:4433";
int nargs = argc - 1;
- ERR_load_crypto_strings();
- ERR_load_SSL_strings();
- SSL_library_init();
-
ctx = SSL_CTX_new(TLS_client_method());
cctx = SSL_CONF_CTX_new();
SSL_CONF_CTX_set_flags(cctx, SSL_CONF_FLAG_CLIENT);
const char *connect_str = "localhost:4433";
long errline = -1;
- ERR_load_crypto_strings();
- ERR_load_SSL_strings();
- SSL_library_init();
-
conf = NCONF_new(NULL);
if (NCONF_load(conf, "connect.cnf", &errline) <= 0) {
static int done = 0;
-void interrupt()
+void interrupt(int sig)
{
done = 1;
}
else
port = argv[1];
- SSL_load_error_strings();
-
- /* Add ciphers and message digests */
- OpenSSL_add_ssl_algorithms();
-
ctx = SSL_CTX_new(TLS_server_method());
if (!SSL_CTX_use_certificate_chain_file(ctx, CERT_FILE))
goto err;
sock_init();
#endif
- /* Lets get nice error messages */
- SSL_load_error_strings();
-
- /* Setup all the global SSL stuff */
- OpenSSL_add_ssl_algorithms();
ssl_ctx = SSL_CTX_new(TLS_client_method());
/* Enable trust chain verification */
*/
#include <stdio.h>
+#include <string.h>
#include <signal.h>
#include <openssl/err.h>
#include <openssl/ssl.h>
char **args = argv + 1;
int nargs = argc - 1;
- SSL_load_error_strings();
-
- /* Add ciphers and message digests */
- OpenSSL_add_ssl_algorithms();
-
ctx = SSL_CTX_new(TLS_server_method());
cctx = SSL_CONF_CTX_new();
SSL_CTX *ctx;
int ret = 1, i;
- SSL_load_error_strings();
-
- /* Add ciphers and message digests */
- OpenSSL_add_ssl_algorithms();
-
if (CONF_modules_load_file("cmod.cnf", "testapp", 0) <= 0) {
fprintf(stderr, "Error processing config file\n");
goto err;
*/
#include <stdio.h>
+#include <string.h>
#include <signal.h>
#include <openssl/err.h>
#include <openssl/ssl.h>
char buf[512];
int ret = 1, i;
- SSL_load_error_strings();
-
- /* Add ciphers and message digests */
- OpenSSL_add_ssl_algorithms();
conf = NCONF_new(NULL);