From: Stefan Eissing Date: Fri, 14 Aug 2015 12:56:21 +0000 (+0000) Subject: removed H2Engine directive X-Git-Tag: 2.5.0-alpha~2963 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=1f0bb9e838359dfaf5cbcf6564c14ed7a6442611;p=thirdparty%2Fapache%2Fhttpd.git removed H2Engine directive git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1695885 13f79535-47bb-0310-9956-ffa450edef68 --- diff --git a/docs/manual/mod/mod_h2.xml b/docs/manual/mod/mod_h2.xml index 120041f919c..47a0e99c566 100644 --- a/docs/manual/mod/mod_h2.xml +++ b/docs/manual/mod/mod_h2.xml @@ -37,40 +37,6 @@ - - H2Engine - H2 Engine Operation Switch - H2Engine on|off - H2Engine off - - server config - virtual host - - - -

- This directive toggles the usage of the HTTP/2 Protocol Engine. This - should be used inside a - VirtualHost - section to enable HTTP/2 for that virtual host. By default the - HTTP/2 Protocol Engine is disabled for both the main server and all - configured virtual hosts. -

- Example - -<VirtualHost _default_:443> - H2Engine on - #... -</VirtualHost> - - -

- The HTTP/2 engine is usable in TLS and plain scenarios, supporting - the 'h2' and 'h2c' variants of the protocol. -

-
-
- H2Direct H2 Direct Protocol Switch diff --git a/modules/http2/h2_config.c b/modules/http2/h2_config.c index b038b5982f3..4a589f3243c 100644 --- a/modules/http2/h2_config.c +++ b/modules/http2/h2_config.c @@ -36,7 +36,6 @@ static h2_config defconf = { "default", - 0, /* enabled */ 100, /* max_streams */ 16 * 1024, /* max_hl_size */ 64 * 1024, /* window_size */ @@ -68,7 +67,6 @@ static void *h2_config_create(apr_pool_t *pool, strcat(name, "]"); conf->name = name; - conf->h2_enabled = DEF_VAL; conf->h2_max_streams = DEF_VAL; conf->h2_max_hl_size = DEF_VAL; conf->h2_window_size = DEF_VAL; @@ -113,7 +111,6 @@ void *h2_config_merge(apr_pool_t *pool, void *basev, void *addv) strcat(name, "]"); n->name = name; - n->h2_enabled = H2_CONFIG_GET(add, base, h2_enabled); n->h2_max_streams = H2_CONFIG_GET(add, base, h2_max_streams); n->h2_max_hl_size = H2_CONFIG_GET(add, base, h2_max_hl_size); n->h2_window_size = H2_CONFIG_GET(add, base, h2_window_size); @@ -137,8 +134,6 @@ void *h2_config_merge(apr_pool_t *pool, void *basev, void *addv) int h2_config_geti(h2_config *conf, h2_config_var_t var) { switch(var) { - case H2_CONF_ENABLED: - return H2_CONFIG_GET(conf, &defconf, h2_enabled); case H2_CONF_MAX_STREAMS: return H2_CONFIG_GET(conf, &defconf, h2_max_streams); case H2_CONF_MAX_HL_SIZE: @@ -183,23 +178,6 @@ h2_config *h2_config_sget(server_rec *s) } -static const char *h2_conf_set_engine(cmd_parms *parms, - void *arg, const char *value) -{ - h2_config *cfg = h2_config_sget(parms->server); - if (!strcasecmp(value, "On")) { - cfg->h2_enabled = 1; - return NULL; - } - else if (!strcasecmp(value, "Off")) { - cfg->h2_enabled = 0; - return NULL; - } - - (void)arg; - return "value must be On or Off"; -} - static const char *h2_conf_set_max_streams(cmd_parms *parms, void *arg, const char *value) { @@ -425,8 +403,6 @@ static const char *h2_conf_set_buffer_output(cmd_parms *parms, #pragma GCC diagnostic ignored "-Wmissing-braces" const command_rec h2_cmds[] = { - AP_INIT_TAKE1("H2Engine", h2_conf_set_engine, NULL, - RSRC_CONF, "on to enable HTTP/2 protocol handling"), AP_INIT_TAKE1("H2MaxSessionStreams", h2_conf_set_max_streams, NULL, RSRC_CONF, "maximum number of open streams per session"), AP_INIT_TAKE1("H2WindowSize", h2_conf_set_window_size, NULL, diff --git a/modules/http2/h2_config.h b/modules/http2/h2_config.h index 1ed0e58478d..2de6f876ca8 100644 --- a/modules/http2/h2_config.h +++ b/modules/http2/h2_config.h @@ -23,7 +23,6 @@ #undef PACKAGE_BUGREPORT typedef enum { - H2_CONF_ENABLED, H2_CONF_MAX_STREAMS, H2_CONF_MAX_HL_SIZE, H2_CONF_WIN_SIZE, @@ -45,7 +44,6 @@ typedef enum { /* Apache httpd module configuration for h2. */ typedef struct h2_config { const char *name; - int h2_enabled; /* if mod_h2 is active at all here */ int h2_max_streams; /* max concurrent # streams (http2) */ int h2_max_hl_size; /* max header list size (http2) */ int h2_window_size; /* stream window size (http2) */ diff --git a/modules/http2/h2_switch.c b/modules/http2/h2_switch.c index 6a2f00934be..2d521fc9396 100644 --- a/modules/http2/h2_switch.c +++ b/modules/http2/h2_switch.c @@ -91,12 +91,6 @@ static int h2_protocol_propose(conn_rec *c, request_rec *r, cfg = h2_config_sget(s); - if (!h2_config_geti(cfg, H2_CONF_ENABLED)) { - ap_log_cerror(APLOG_MARK, APLOG_DEBUG, 0, c, - "protocol propose, h2 disabled for config %s", cfg->name); - return DECLINED; - } - if (r) { const char *p; /* So far, this indicates an HTTP/1 Upgrade header initiated