X-Git-Url: https://tinc-vpn.org/git/browse?a=blobdiff_plain;f=src%2Ftincd.c;h=20443101a369c690ecd82f1cc1586b0b36cdd74c;hb=8c69f42d7d9b4d9d5f6b6656cfc1bf1e1abee854;hp=c0c12addae28f763228cb3f56c4430b068610998;hpb=f8733d1935ed83399c4851a31f4be710eb8c825f;p=tinc diff --git a/src/tincd.c b/src/tincd.c index c0c12add..20443101 100644 --- a/src/tincd.c +++ b/src/tincd.c @@ -31,13 +31,18 @@ #include #endif +#include +#include +#include +#include +#include + #include LZO1X_H #include #include "conf.h" #include "control.h" -#include "crypto.h" #include "device.h" #include "logger.h" #include "net.h" @@ -104,6 +109,7 @@ static void usage(bool status) " -L, --mlock Lock tinc into main memory.\n" " --logfile[=FILENAME] Write log entries to a logfile.\n" " --controlsocket=FILENAME Open control socket at FILENAME.\n" + " --bypass-security Disables meta protocol security, for debugging.\n" " --help Display this help and exit.\n" " --version Output version information and exit.\n\n")); printf(_("Report bugs to tinc@tinc-vpn.org.\n")); @@ -212,7 +218,7 @@ static void make_names(void) #endif if(!controlsocketname) - asprintf(&controlsocketname, LOCALSTATEDIR "/run/%s.control", identname); + asprintf(&controlsocketname, "%s/run/%s.control/socket", LOCALSTATEDIR, identname); if(!logfilename) asprintf(&logfilename, LOCALSTATEDIR "/log/%s.log", identname); @@ -289,7 +295,12 @@ int main(int argc, char **argv) /* Slllluuuuuuurrrrp! */ srand(time(NULL)); - crypto_init(); + RAND_load_file("/dev/urandom", 1024); + + ENGINE_load_builtin_engines(); + ENGINE_register_all_complete(); + + OpenSSL_add_all_algorithms(); if(!read_server_config()) return 1; @@ -342,7 +353,7 @@ end: exit_control(); #endif - crypto_exit(); - + EVP_cleanup(); + return status; }