summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHenning Brauer <henning@cvs.openbsd.org>2003-10-02 16:21:32 +0000
committerHenning Brauer <henning@cvs.openbsd.org>2003-10-02 16:21:32 +0000
commit67345882cdf8dbbc20c98c25ad6a491397daa5c6 (patch)
tree828b4a24eb482c09161d8988c0f4abc86aec80c7
parent02f575f72dcdb0c22272484c87ccbed738ab04e3 (diff)
chroot handling for SSLCertificateChainFile, problem found and fix tested by
Sandor Palfy <netchan@cotse.net>
-rw-r--r--usr.sbin/httpd/src/modules/ssl/ssl_engine_config.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/usr.sbin/httpd/src/modules/ssl/ssl_engine_config.c b/usr.sbin/httpd/src/modules/ssl/ssl_engine_config.c
index 94b5d15e397..3ff679ea1a4 100644
--- a/usr.sbin/httpd/src/modules/ssl/ssl_engine_config.c
+++ b/usr.sbin/httpd/src/modules/ssl/ssl_engine_config.c
@@ -603,9 +603,10 @@ const char *ssl_cmd_SSLCertificateChainFile(
char *cpPath;
cpPath = ssl_util_server_root_relative(cmd->pool, "certkey", arg);
- if (!ssl_util_path_check(SSL_PCM_EXISTS|SSL_PCM_ISREG|SSL_PCM_ISNONZERO, cpPath))
+ if (!ap_server_is_chrooted() && !ssl_util_path_check(SSL_PCM_EXISTS|SSL_PCM_ISREG|SSL_PCM_ISNONZERO, cpPath))
return ap_pstrcat(cmd->pool, "SSLCertificateChainFile: file '",
cpPath, "' not exists or empty", NULL);
+ ap_server_strip_chroot(cpPath, 0);
sc->szCertificateChain = cpPath;
return NULL;
}