aboutsummaryrefslogtreecommitdiffstats
path: root/src/gnutls_config.c
diff options
context:
space:
mode:
authorGravatar Nikos Mavrogiannopoulos 2008-02-20 19:50:09 +0000
committerGravatar Nokis Mavrogiannopoulos 2008-02-20 19:50:09 +0000
commit787dab7316f5a9a314b538d0876a9e57af977dc3 (patch)
treee1fb01b994eba94e6d357fddffb1459d9fddd018 /src/gnutls_config.c
parent2cdc2649f2201af83d570fc418a984fe936d6fe0 (diff)
added option to disable srp (for distributions that disable it in gnutls)
Diffstat (limited to 'src/gnutls_config.c')
-rw-r--r--src/gnutls_config.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/gnutls_config.c b/src/gnutls_config.c
index f08512e..e290d90 100644
--- a/src/gnutls_config.c
+++ b/src/gnutls_config.c
@@ -281,6 +281,8 @@ const char *mgs_set_pgpkey_file(cmd_parms * parms, void *dummy,
281} 281}
282 282
283 283
284#ifdef ENABLE_SRP
285
284const char *mgs_set_srp_tpasswd_file(cmd_parms * parms, void *dummy, 286const char *mgs_set_srp_tpasswd_file(cmd_parms * parms, void *dummy,
285 const char *arg) 287 const char *arg)
286{ 288{
@@ -307,6 +309,8 @@ const char *mgs_set_srp_tpasswd_conf_file(cmd_parms * parms, void *dummy,
307 return NULL; 309 return NULL;
308} 310}
309 311
312#endif
313
310const char *mgs_set_cache(cmd_parms * parms, void *dummy, 314const char *mgs_set_cache(cmd_parms * parms, void *dummy,
311 const char *type, const char *arg) 315 const char *type, const char *arg)
312{ 316{
@@ -543,6 +547,7 @@ void *mgs_config_server_create(apr_pool_t * p, server_rec * s)
543 ": (%d) %s", ret, gnutls_strerror(ret)); 547 ": (%d) %s", ret, gnutls_strerror(ret));
544 } 548 }
545 549
550#ifdef ENABLE_SRP
546 ret = gnutls_srp_allocate_server_credentials(&sc->srp_creds); 551 ret = gnutls_srp_allocate_server_credentials(&sc->srp_creds);
547 if (ret < 0) { 552 if (ret < 0) {
548 return apr_psprintf(p, "GnuTLS: Failed to initialize" 553 return apr_psprintf(p, "GnuTLS: Failed to initialize"
@@ -551,6 +556,8 @@ void *mgs_config_server_create(apr_pool_t * p, server_rec * s)
551 556
552 sc->srp_tpasswd_conf_file = NULL; 557 sc->srp_tpasswd_conf_file = NULL;
553 sc->srp_tpasswd_file = NULL; 558 sc->srp_tpasswd_file = NULL;
559#endif
560
554 sc->privkey_x509 = NULL; 561 sc->privkey_x509 = NULL;
555 memset( sc->certs_x509, 0, sizeof(sc->certs_x509)); 562 memset( sc->certs_x509, 0, sizeof(sc->certs_x509));
556 sc->certs_x509_num = 0; 563 sc->certs_x509_num = 0;