]> granicus.if.org Git - apache/commitdiff
mod_reqtimeout: follow up to r1853906: adjust hooks priorities comments.
authorYann Ylavic <ylavic@apache.org>
Tue, 19 Feb 2019 18:22:11 +0000 (18:22 +0000)
committerYann Ylavic <ylavic@apache.org>
Tue, 19 Feb 2019 18:22:11 +0000 (18:22 +0000)
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1853908 13f79535-47bb-0310-9956-ffa450edef68

modules/filters/mod_reqtimeout.c

index a29091c57649d8212ab508c2adf3e31f92368696..80aa7db4f55d223cbfcb6bb90f1fcc77fd4e61fb 100644 (file)
@@ -607,8 +607,7 @@ static void reqtimeout_hooks(apr_pool_t *pool)
 {
     /*
      * mod_ssl is AP_FTYPE_CONNECTION + 5 and mod_reqtimeout needs to
-     * be called before mod_ssl. Otherwise repeated reads during the ssl
-     * handshake can prevent the timeout from triggering.
+     * be called before mod_ssl for the handshake stage to catch SSL traffic.
      */
     ap_register_input_filter(reqtimeout_filter_name, reqtimeout_filter, NULL,
                              AP_FTYPE_CONNECTION + 8);
@@ -625,8 +624,11 @@ static void reqtimeout_hooks(apr_pool_t *pool)
      * mod_reqtimeout needs to be called before ap_process_http_request (which
      * is run at APR_HOOK_REALLY_LAST) but after all other protocol modules.
      * This ensures that it only influences normal http connections and not
-     * e.g. mod_ftp. Also, if mod_reqtimeout used the pre_connection hook, it
-     * would be inserted on mod_proxy's backend connections.
+     * e.g. mod_ftp. We still process it first though, for the handshake stage
+     * to work with/before mod_ssl, but since it's disabled by default it won't
+     * influence non-HTTP modules unless configured explicitely. Also, if
+     * mod_reqtimeout used the pre_connection hook, it would be inserted on
+     * mod_proxy's backend connections, and we don't want this.
      */
     ap_hook_process_connection(reqtimeout_init, NULL, NULL, APR_HOOK_FIRST);