From d92c7c1c7d3226a8671b59c1fd20ae49ee62f43b Mon Sep 17 00:00:00 2001 From: =?utf8?q?Julio=20S=C3=A1nchez=20Fern=C3=A1ndez?= Date: Thu, 15 Jul 1999 15:04:02 +0000 Subject: [PATCH] A couple of options for TLS configuration. Still a conflict here, the default context is initialized before the config file is read, so the locations are not know at context initialization. --- servers/slapd/config.c | 18 +++++++++++++++++- 1 file changed, 17 insertions(+), 1 deletion(-) diff --git a/servers/slapd/config.c b/servers/slapd/config.c index 7f38737a9b..f95adad34f 100644 --- a/servers/slapd/config.c +++ b/servers/slapd/config.c @@ -45,7 +45,7 @@ read_config( char *fname ) char *line, *savefname, *saveline; int cargc, savelineno; char *cargv[MAXARGS]; - int lineno, i; + int lineno, i, rc; static BackendInfo *bi = NULL; static BackendDB *be = NULL; @@ -600,6 +600,22 @@ read_config( char *fname ) #endif /*SLAPD_MODULES*/ +#ifdef HAVE_TLS + } else if ( !strcasecmp( cargv[0], "SSLCertificateFile" ) ) { + rc = ldap_pvt_tls_set_option( NULL, + LDAP_OPT_X_TLS_CERTFILE, + cargv[1] ); + if ( rc ) + return rc; + + } else if ( !strcasecmp( cargv[0], "SSLCertificateKeyFile" ) ) { + rc = ldap_pvt_tls_set_option( NULL, + LDAP_OPT_X_TLS_KEYFILE, + cargv[1] ); + if ( rc ) + return rc; +#endif + /* pass anything else to the current backend info/db config routine */ } else { if ( bi != NULL ) { -- 2.39.5