mirror of
https://github.com/openbsd/src.git
synced 2024-12-22 07:27:59 -08:00
remove ssl_init()
it's a noop; nowadays both LibreSSL and OpenSSL libcrypto and libssl initialize themselves automatically before doing anything. ok tb
This commit is contained in:
parent
8d3b03ab73
commit
4958adbcc0
@ -1,4 +1,4 @@
|
||||
/* $OpenBSD: config.c,v 1.43 2021/12/05 13:48:14 jsg Exp $ */
|
||||
/* $OpenBSD: config.c,v 1.44 2023/06/25 08:07:38 op Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 2011 - 2014 Reyk Floeter <reyk@openbsd.org>
|
||||
@ -293,7 +293,6 @@ config_getcfg(struct relayd *env, struct imsg *imsg)
|
||||
}
|
||||
|
||||
if (env->sc_conf.flags & (F_TLS|F_TLSCLIENT)) {
|
||||
ssl_init(env);
|
||||
if (what & CONFIG_CA_ENGINE)
|
||||
ca_engine_init(env);
|
||||
}
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $OpenBSD: relayd.c,v 1.190 2022/11/10 00:00:11 mbuhl Exp $ */
|
||||
/* $OpenBSD: relayd.c,v 1.191 2023/06/25 08:07:38 op Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 2007 - 2016 Reyk Floeter <reyk@openbsd.org>
|
||||
@ -255,9 +255,6 @@ main(int argc, char *argv[])
|
||||
exit(0);
|
||||
}
|
||||
|
||||
if (env->sc_conf.flags & (F_TLS|F_TLSCLIENT))
|
||||
ssl_init(env);
|
||||
|
||||
/* rekey the TLS tickets before pushing the config */
|
||||
parent_tls_ticket_rekey(0, 0, env);
|
||||
if (parent_configure(env) == -1)
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $OpenBSD: relayd.h,v 1.270 2023/06/21 07:54:54 claudio Exp $ */
|
||||
/* $OpenBSD: relayd.h,v 1.271 2023/06/25 08:07:39 op Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 2006 - 2016 Reyk Floeter <reyk@openbsd.org>
|
||||
@ -1293,7 +1293,6 @@ void script_done(struct relayd *, struct ctl_script *);
|
||||
int script_exec(struct relayd *, struct ctl_script *);
|
||||
|
||||
/* ssl.c */
|
||||
void ssl_init(struct relayd *);
|
||||
char *ssl_load_key(struct relayd *, const char *, off_t *, char *);
|
||||
uint8_t *ssl_update_certificate(const uint8_t *, size_t, EVP_PKEY *,
|
||||
EVP_PKEY *, X509 *, size_t *);
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $OpenBSD: ssl.c,v 1.36 2021/12/08 19:25:04 tb Exp $ */
|
||||
/* $OpenBSD: ssl.c,v 1.37 2023/06/25 08:07:39 op Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 2007 - 2014 Reyk Floeter <reyk@openbsd.org>
|
||||
@ -27,30 +27,11 @@
|
||||
|
||||
#include <openssl/ssl.h>
|
||||
#include <openssl/err.h>
|
||||
#include <openssl/engine.h>
|
||||
|
||||
#include "relayd.h"
|
||||
|
||||
int ssl_password_cb(char *, int, int, void *);
|
||||
|
||||
void
|
||||
ssl_init(struct relayd *env)
|
||||
{
|
||||
static int initialized = 0;
|
||||
|
||||
if (initialized)
|
||||
return;
|
||||
|
||||
SSL_library_init();
|
||||
SSL_load_error_strings();
|
||||
|
||||
/* Init hardware crypto engines. */
|
||||
ENGINE_load_builtin_engines();
|
||||
ENGINE_register_all_complete();
|
||||
|
||||
initialized = 1;
|
||||
}
|
||||
|
||||
int
|
||||
ssl_password_cb(char *buf, int size, int rwflag, void *u)
|
||||
{
|
||||
@ -73,9 +54,6 @@ ssl_load_key(struct relayd *env, const char *name, off_t *len, char *pass)
|
||||
long size;
|
||||
char *data, *buf = NULL;
|
||||
|
||||
/* Initialize SSL library once */
|
||||
ssl_init(env);
|
||||
|
||||
/*
|
||||
* Read (possibly) encrypted key from file
|
||||
*/
|
||||
|
Loading…
Reference in New Issue
Block a user