View | Details | Raw Unified | Return to bug 47256
Collapse All | Expand All

(-)a/modules/ssl/mod_ssl.c (+7 lines)
Lines 442-447 static int ssl_hook_pre_connection(conn_rec *c, void *csd) Link Here
442
    }
442
    }
443
443
444
    /*
444
    /*
445
     * If SSL port is set, and the connection is to a different port, then decline
446
     */
447
    if (sc && sc->port>0 && c && c->local_addr && (sc->port != c->local_addr->port)) {
448
        return DECLINED;
449
    }
450
451
    /*
445
     * Create SSL context
452
     * Create SSL context
446
     */
453
     */
447
    if (!sslconn) {
454
    if (!sslconn) {
(-)a/modules/ssl/ssl_engine_config.c (-1 / +13 lines)
Lines 169-174 static SSLSrvConfigRec *ssl_config_server_new(apr_pool_t *p) Link Here
169
    sc->vhost_id_len           = 0;     /* set during module init */
169
    sc->vhost_id_len           = 0;     /* set during module init */
170
    sc->session_cache_timeout  = UNSET;
170
    sc->session_cache_timeout  = UNSET;
171
    sc->cipher_server_pref     = UNSET;
171
    sc->cipher_server_pref     = UNSET;
172
    sc->port                   = 0;
172
173
173
    modssl_ctx_init_proxy(sc, p);
174
    modssl_ctx_init_proxy(sc, p);
174
175
Lines 256-261 void *ssl_config_server_merge(apr_pool_t *p, void *basev, void *addv) Link Here
256
    cfgMerge(enabled, SSL_ENABLED_UNSET);
257
    cfgMerge(enabled, SSL_ENABLED_UNSET);
257
    cfgMergeBool(proxy_enabled);
258
    cfgMergeBool(proxy_enabled);
258
    cfgMergeInt(session_cache_timeout);
259
    cfgMergeInt(session_cache_timeout);
260
    cfgMergeInt(port);
259
    cfgMergeBool(cipher_server_pref);
261
    cfgMergeBool(cipher_server_pref);
260
262
261
    modssl_ctx_cfg_merge_proxy(base->proxy, add->proxy, mrg->proxy);
263
    modssl_ctx_cfg_merge_proxy(base->proxy, add->proxy, mrg->proxy);
Lines 615-622 const char *ssl_cmd_SSLEngine(cmd_parms *cmd, void *dcfg, const char *arg) Link Here
615
        sc->enabled = SSL_ENABLED_OPTIONAL;
617
        sc->enabled = SSL_ENABLED_OPTIONAL;
616
        return NULL;
618
        return NULL;
617
    }
619
    }
620
    else {
621
        // Try to parse the argument as a port number
622
        apr_port_t port;
623
        port = atoi(arg);
624
        if (port>0) {
625
            sc->enabled = SSL_ENABLED_TRUE;
626
            sc->port = port;
627
            return NULL;
628
        }
629
    }
618
630
619
    return "Argument must be On, Off, or Optional";
631
    return "Argument must be On, Off, Optional, or a port number";
620
}
632
}
621
633
622
const char *ssl_cmd_SSLCipherSuite(cmd_parms *cmd,
634
const char *ssl_cmd_SSLCipherSuite(cmd_parms *cmd,
(-)a/modules/ssl/ssl_private.h (-1 / +1 lines)
Lines 449-454 struct SSLSrvConfigRec { Link Here
449
    BOOL             cipher_server_pref;
449
    BOOL             cipher_server_pref;
450
    modssl_ctx_t    *server;
450
    modssl_ctx_t    *server;
451
    modssl_ctx_t    *proxy;
451
    modssl_ctx_t    *proxy;
452
    apr_port_t       port;
452
};
453
};
453
454
454
/**
455
/**
455
- 

Return to bug 47256