diff --git a/src/tools/sysdb/main.c b/src/tools/sysdb/main.c
index e9e2202635d1d89dcb238a6e6c18dd7b295695cb..e4922e9b939587c914fd7d28ef172ce0fa4a59fb 100644 (file)
--- a/src/tools/sysdb/main.c
+++ b/src/tools/sysdb/main.c
#include "utils/llist.h"
#include "utils/strbuf.h"
#include "utils/os.h"
+#include "utils/ssl.h"
#include <errno.h>
# endif
#endif /* READLINEs */
-#include <openssl/ssl.h>
-#include <openssl/err.h>
-
#ifndef DEFAULT_SOCKET
# define DEFAULT_SOCKET "unix:"LOCALSTATEDIR"/run/sysdbd.sock"
#endif
if (! input.user)
exit(1);
- SSL_load_error_strings();
- OpenSSL_add_ssl_algorithms();
+ if (sdb_ssl_init())
+ exit(1);
input.client = sdb_client_create(host);
if (! input.client) {
}
sdb_log(SDB_LOG_INFO, "SysDB client "SDB_CLIENT_VERSION_STRING
- SDB_CLIENT_VERSION_EXTRA" (libsysdbclient %s%s)\n",
+ SDB_CLIENT_VERSION_EXTRA" (libsysdbclient %s%s)",
sdb_client_version_string(), sdb_client_version_extra());
+ sdb_command_print_server_version(&input);
+ printf("\n");
using_history();
}
sdb_input_reset(&input);
-
- ERR_free_strings();
+ sdb_ssl_shutdown();
return 0;
} /* main */