summaryrefslogtreecommitdiffstats
path: root/nss_engine_init.c
diff options
context:
space:
mode:
Diffstat (limited to 'nss_engine_init.c')
-rw-r--r--nss_engine_init.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/nss_engine_init.c b/nss_engine_init.c
index 2569c8d..50b623d 100644
--- a/nss_engine_init.c
+++ b/nss_engine_init.c
@@ -145,6 +145,7 @@ static void nss_init_SSLLibrary(server_rec *base_server)
int fipsenabled = FALSE;
int ocspenabled = FALSE;
int ocspdefault = FALSE;
+ char *dbdir = NULL;
const char * ocspurl = NULL;
const char * ocspname = NULL;
@@ -186,7 +187,11 @@ static void nss_init_SSLLibrary(server_rec *base_server)
else
return;
}
- if (chdir(mc->pCertificateDatabase) != 0) {
+ if (strncasecmp(mc->pCertificateDatabase, "sql:", 4) == 0)
+ dbdir = mc->pCertificateDatabase + 4;
+ else
+ dbdir = mc->pCertificateDatabase;
+ if (chdir(dbdir) != 0) {
ap_log_error(APLOG_MARK, APLOG_ERR, 0, base_server,
"Unable to change directory to %s", mc->pCertificateDatabase);
if (mc->nInitCount == 1)