altarch-user / rpms / httpd

Forked from rpms/httpd 2 years ago
Clone

Blame SOURCES/httpd-2.4.6-r1537535.patch

008793
# ./pullrev.sh 1537535
008793
008793
http://svn.apache.org/viewvc?view=revision&revision=1537535
008793
008793
--- httpd-2.4.6/modules/ssl/ssl_engine_config.c.r1537535
008793
+++ httpd-2.4.6/modules/ssl/ssl_engine_config.c
008793
@@ -198,7 +198,7 @@ static SSLSrvConfigRec *ssl_config_serve
008793
     SSLSrvConfigRec *sc = apr_palloc(p, sizeof(*sc));
008793
 
008793
     sc->mc                     = NULL;
008793
-    sc->enabled                = SSL_ENABLED_FALSE;
008793
+    sc->enabled                = SSL_ENABLED_UNSET;
008793
     sc->proxy_enabled          = UNSET;
008793
     sc->vhost_id               = NULL;  /* set during module init */
008793
     sc->vhost_id_len           = 0;     /* set during module init */
008793
--- httpd-2.4.6/modules/ssl/ssl_engine_init.c.r1537535
008793
+++ httpd-2.4.6/modules/ssl/ssl_engine_init.c
008793
@@ -289,13 +289,16 @@ int ssl_init_Module(apr_pool_t *p, apr_p
008793
         sc->vhost_id = ssl_util_vhostid(p, s);
008793
         sc->vhost_id_len = strlen(sc->vhost_id);
008793
 
008793
-        if (ap_get_server_protocol(s) &&
008793
-            strcmp("https", ap_get_server_protocol(s)) == 0) {
008793
+        /* Default to enabled if SSLEngine is not set explicitly, and
008793
+         * the protocol is https. */
008793
+        if (ap_get_server_protocol(s) 
008793
+            && strcmp("https", ap_get_server_protocol(s)) == 0
008793
+            && sc->enabled == SSL_ENABLED_UNSET) {
008793
             sc->enabled = SSL_ENABLED_TRUE;
008793
         }
008793
 
008793
-       /* If sc->enabled is UNSET, then SSL is optional on this vhost  */
008793
-        /* Fix up stuff that may not have been set */
008793
+        /* Fix up stuff that may not have been set.  If sc->enabled is
008793
+         * UNSET, then SSL is disabled on this vhost.  */
008793
         if (sc->enabled == SSL_ENABLED_UNSET) {
008793
             sc->enabled = SSL_ENABLED_FALSE;
008793
         }