From 1ff352c814a81b19b6348b96845f425d2711fc57 Mon Sep 17 00:00:00 2001 From: Nokis Mavrogiannopoulos Date: Wed, 1 Oct 2008 16:06:35 +0000 Subject: Allow openpgp-only sites --- src/gnutls_hooks.c | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) (limited to 'src') diff --git a/src/gnutls_hooks.c b/src/gnutls_hooks.c index 57d3aaf..57bfeba 100644 --- a/src/gnutls_hooks.c +++ b/src/gnutls_hooks.c @@ -409,8 +409,9 @@ mgs_hook_post_config(apr_pool_t * p, apr_pool_t * plog, } #endif - if (sc->certs_x509[0] == NULL - && sc->enabled == GNUTLS_ENABLED_TRUE) { + if (sc->certs_x509[0] == NULL && + sc->cert_pgp == NULL && + sc->enabled == GNUTLS_ENABLED_TRUE) { ap_log_error(APLOG_MARK, APLOG_EMERG, 0, s, "[GnuTLS] - Host '%s:%d' is missing a " "Certificate File!", s->server_hostname, @@ -418,8 +419,9 @@ mgs_hook_post_config(apr_pool_t * p, apr_pool_t * plog, exit(-1); } - if (sc->privkey_x509 == NULL - && sc->enabled == GNUTLS_ENABLED_TRUE) { + if (sc->enabled == GNUTLS_ENABLED_TRUE && + ((sc->certs_x509[0] != NULL && sc->privkey_x509 == NULL) || + (sc->cert_pgp != NULL && sc->privkey_pgp == NULL))) { ap_log_error(APLOG_MARK, APLOG_EMERG, 0, s, "[GnuTLS] - Host '%s:%d' is missing a " "Private Key File!", -- cgit