Skip to content

Commit fbf57b8

Browse files
committed
mod_ssl: Disallow SSLOpenSSLConfCmd within vhost context since it
has global effect. * modules/ssl/ssl_engine_config.c (ssl_cmd_SSLOpenSSLConfCmd): Disallow use within vhost context. PR: 69397 git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1921336 13f79535-47bb-0310-9956-ffa450edef68
1 parent 584ed86 commit fbf57b8

File tree

3 files changed

+7
-2
lines changed

3 files changed

+7
-2
lines changed

changes-entries/pr69397.txt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
*) mod_ssl: Disallow use of "SSLOpenSSLConfCmd" in <VirtualHost>
2+
context. PR 69397. [Joe Orton]

docs/manual/mod/mod_ssl.xml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2935,8 +2935,7 @@ forward secrecy.</p>
29352935
<name>SSLOpenSSLConfCmd</name>
29362936
<description>Configure OpenSSL parameters through its <em>SSL_CONF</em> API</description>
29372937
<syntax>SSLOpenSSLConfCmd <em>command-name</em> <em>command-value</em></syntax>
2938-
<contextlist><context>server config</context>
2939-
<context>virtual host</context></contextlist>
2938+
<contextlist><context>server config</context></contextlist>
29402939
<compatibility>Available in httpd 2.4.8 and later, if using OpenSSL 1.0.2 or later</compatibility>
29412940

29422941
<usage>

modules/ssl/ssl_engine_config.c

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2162,6 +2162,10 @@ const char *ssl_cmd_SSLOpenSSLConfCmd(cmd_parms *cmd, void *dcfg,
21622162
const char *err;
21632163
ssl_ctx_param_t *param;
21642164

2165+
if ((err = ap_check_cmd_context(cmd, GLOBAL_ONLY))) {
2166+
return err;
2167+
}
2168+
21652169
if (value_type == SSL_CONF_TYPE_UNKNOWN) {
21662170
return apr_psprintf(cmd->pool,
21672171
"'%s': invalid OpenSSL configuration command",

0 commit comments

Comments
 (0)