[apache2] 01/01: New upstream version 2.4.29

Ondřej Surý ondrej at debian.org
Tue Oct 24 18:36:26 UTC 2017


This is an automated email from the git hooks/post-receive script.

ondrej pushed a commit to branch upstream
in repository apache2.

commit 85aea019d6ee4da991e0bf70d199d46ce2490d0b
Author: Ondřej Surý <ondrej at sury.org>
Date:   Sun Oct 22 10:41:15 2017 +0000

    New upstream version 2.4.29
---
 .gdbinit                                          | 128 ++-
 Apache-apr2.dsw                                   |  30 -
 Apache.dsw                                        |  18 -
 CHANGES                                           |  96 ++-
 LICENSE                                           |  45 --
 Makefile.in                                       |  40 +-
 acinclude.m4                                      |  18 +-
 build/config_vars.sh.in                           |   2 +
 buildconf                                         | 157 +++-
 configure                                         | 931 ++++++++++++++++++----
 configure.in                                      |  31 +-
 docs/conf/mime.types                              |  10 +-
 docs/manual/caching.html.fr                       |   4 +-
 docs/manual/howto/access.html.en                  |   2 +-
 docs/manual/howto/access.html.es                  |   4 +
 docs/manual/howto/access.html.fr                  |   2 +-
 docs/manual/images/feather.png                    | Bin 6090 -> 21145 bytes
 docs/manual/index.html.en                         |   1 +
 docs/manual/index.html.es                         |   4 +
 docs/manual/index.html.fr                         |   2 +
 docs/manual/index.html.tr.utf8                    |   1 +
 docs/manual/mod/core.html.en                      |  28 +-
 docs/manual/mod/core.html.fr                      |  32 +-
 docs/manual/mod/core.html.tr.utf8                 |  19 +-
 docs/manual/mod/mod_autoindex.html.tr.utf8        |  11 +-
 docs/manual/mod/mod_proxy.html.en                 |  39 +-
 docs/manual/mod/mod_proxy.html.fr                 |  53 +-
 docs/manual/mod/mod_proxy_balancer.html.en        |   4 +
 docs/manual/mod/mod_proxy_balancer.html.fr        |   4 +
 docs/manual/mod/mod_proxy_express.html.en         |   4 +
 docs/manual/mod/mod_proxy_express.html.fr         |   4 +
 docs/manual/mod/mod_proxy_fcgi.html.en            |   5 +-
 docs/manual/mod/mod_proxy_fcgi.html.fr            |  10 +-
 docs/manual/mod/mod_proxy_wstunnel.html.en        |   4 +-
 docs/manual/mod/mod_reqtimeout.html.fr            |   2 +-
 docs/manual/mod/mpm_common.html.en                |  21 +
 docs/manual/mod/mpm_common.html.fr                |  26 +
 docs/manual/mod/mpm_common.html.tr.utf8           |   1 +
 docs/manual/mod/overrides.html                    |   5 +
 docs/manual/mod/overrides.html.en                 | 767 ++++++++++++++++++
 docs/manual/mod/quickreference.html.en            |   2 +-
 docs/manual/mod/quickreference.html.fr            |   2 +-
 docs/manual/mod/quickreference.html.ko.euc-kr     |   2 +-
 docs/manual/mod/quickreference.html.zh-cn.utf8    |   2 +-
 docs/manual/rewrite/flags.html.en                 |   2 +-
 docs/manual/rewrite/flags.html.fr                 |   2 +-
 docs/manual/rewrite/rewritemap.html.en            |   7 +-
 docs/manual/rewrite/rewritemap.html.fr            |   2 +
 docs/manual/sitemap.html.en                       |   1 +
 docs/manual/sitemap.html.es                       |   4 +
 docs/manual/sitemap.html.fr                       |   2 +
 docs/manual/sitemap.html.tr.utf8                  |   1 +
 docs/manual/style/css/manual.css                  |   6 +
 docs/manual/style/modulesynopsis.dtd              |   8 +
 docs/manual/style/scripts/prettify.js             |   2 +-
 docs/manual/style/scripts/prettify.min.js         |   2 +-
 docs/manual/style/version.ent                     |   2 +-
 httpd.spec                                        |   2 +-
 include/ap_release.h                              |   2 +-
 libhttpd.dsp                                      |  29 +
 libhttpd.mak                                      |  37 +-
 modules/aaa/mod_authz_dbd.c                       |  10 +-
 modules/core/mod_watchdog.c                       |  20 +-
 modules/dav/main/mod_dav.c                        |  15 +-
 modules/generators/mod_cgi.c                      |   5 -
 modules/generators/mod_cgid.c                     |   5 -
 modules/http2/config2.m4                          |  18 +-
 modules/http2/h2_bucket_beam.c                    | 346 ++++----
 modules/http2/h2_bucket_beam.h                    |  19 +-
 modules/http2/h2_mplx.c                           |  11 -
 modules/http2/h2_stream.c                         |  46 +-
 modules/http2/h2_task.c                           |  71 +-
 modules/http2/h2_util.c                           |  81 +-
 modules/http2/h2_util.h                           |   9 -
 modules/http2/h2_version.h                        |   4 +-
 modules/http2/h2_workers.c                        |   2 +
 modules/mappers/mod_rewrite.c                     |  22 +-
 modules/mappers/mod_speling.c                     |   8 +-
 modules/metadata/mod_unique_id.c                  | 150 +---
 modules/proxy/balancers/mod_lbmethod_bybusyness.c |   3 +-
 modules/proxy/balancers/mod_lbmethod_byrequests.c |   3 +-
 modules/proxy/balancers/mod_lbmethod_bytraffic.c  |   3 +-
 modules/proxy/balancers/mod_lbmethod_heartbeat.c  |   3 +-
 modules/proxy/mod_proxy.c                         |  21 +-
 modules/proxy/mod_proxy.h                         |   1 +
 modules/proxy/mod_proxy_balancer.c                |  37 +-
 modules/proxy/mod_proxy_hcheck.c                  |  36 +-
 modules/proxy/mod_proxy_wstunnel.c                |  11 +-
 modules/proxy/proxy_util.c                        |   2 +-
 modules/ssl/mod_ssl.c                             |  10 +-
 modules/ssl/ssl_engine_init.c                     |  10 +-
 modules/ssl/ssl_engine_io.c                       |   8 +-
 modules/ssl/ssl_engine_kernel.c                   |   4 +-
 modules/ssl/ssl_engine_vars.c                     |   2 +-
 modules/ssl/ssl_private.h                         |  29 +-
 modules/ssl/ssl_util.c                            |   8 +-
 modules/ssl/ssl_util_ssl.h                        |   2 +-
 server/config.c                                   |   4 +-
 server/core.c                                     |  30 +-
 server/listen.c                                   |  50 +-
 server/log.c                                      |  36 +-
 server/main.c                                     |  25 +-
 server/mpm/event/event.c                          | 718 +++++++++++------
 server/mpm/prefork/prefork.c                      |  10 +
 server/protocol.c                                 | 100 ++-
 server/util.c                                     |   3 +-
 server/util_expr_eval.c                           |  18 +-
 support/ab.c                                      |  12 +-
 support/htdigest.c                                |  24 +-
 109 files changed, 3408 insertions(+), 1341 deletions(-)

diff --git a/.gdbinit b/.gdbinit
index 6b3f9b7..7b3b9a7 100644
--- a/.gdbinit
+++ b/.gdbinit
@@ -18,6 +18,25 @@ document dump_table
     Print the key/value pairs in a table.
 end
 
+define dump_skiplist
+    set $sl = (apr_skiplist *)$arg0
+    set $m = $sl->bottom
+    printf "skiplist@%p: size=%lu: height=%d\n", $sl, $sl->size, $sl->height
+    while ($m)
+        printf "(%p,%.12lx)", $m, $m->data
+        set $u = $m->up
+        while ($u)
+            printf " (%p,%.12lx)", $u, $u->data
+            set $u = $u->up
+        end
+        printf "\n"
+        set $m = $m->next
+    end
+end
+document dump_skiplist
+    Print the nodes/values in a skiplist
+end
+
 define dump_string_hash
     set $h = $arg0->array
     set $n = $arg0->max
@@ -355,8 +374,8 @@ define dump_allocator
         if $node != 0
             printf " #%2d: ", $i
             while $node != 0
-                printf "%d, ", 4096 << $node->index
-                set $kb = $kb + (4 << $node->index)
+                printf "%d, ", ($node->index + 1) << 12
+                set $kb = $kb + (($node->index + 1) << 2)
                 set $node = $node->next
             end
             printf "ends.\n"
@@ -377,7 +396,7 @@ define dump_one_pool
     set $node = $arg0->active
     set $done = 0
     while $done == 0
-        set $size = $size + (4096 << $node->index)
+        set $size = $size + (($node->index + 1) << 12)
         set $free = $free + ($node->endp - $node->first_avail)
         set $nodes = $nodes + 1
         set $node = $node->next
@@ -385,7 +404,108 @@ define dump_one_pool
             set $done = 1
         end
     end
-    printf "Pool '%s' [%p]: %d/%d free (%d blocks)\n", $p->tag, $p, $free, $size, $nodes
+    printf "Pool '"
+    if $p->tag
+        printf "%s", $p->tag
+    else
+        printf "no tag"
+    end
+    printf "' [%p]: %d/%d free (%d blocks)\n", $p, $free, $size, $nodes
+end
+
+define dump_all_pools
+    set $root = $arg0
+    while $root->parent
+        set $root = $root->parent
+    end
+    dump_pool_and_children $root
+end
+document dump_all_pools
+    Dump the whole pool hierarchy starting from apr_global_pool. Requires an arbitrary pool as starting parameter.
+end
+
+python
+
+from __future__ import print_function
+
+class DumpPoolAndChilds (gdb.Command):
+  """Dump the whole pool hierarchy starting from the given pool."""
+
+  def __init__ (self):
+    super (DumpPoolAndChilds, self).__init__ ("dump_pool_and_children", gdb.COMMAND_USER)
+
+  def _allocator_free_blocks(self, alloc):
+    salloc = "%s" % (alloc)
+    if self.total_free_blocks.get(salloc) != None:
+      return self.total_free_blocks[salloc]
+    i = 0
+    dalloc = alloc.dereference()
+    max =(dalloc['free'].type.sizeof)/(dalloc['free'][0].type.sizeof)
+    kb = 0
+    while i < max:
+      node = dalloc['free'][i]
+      if node != 0:
+        while node != 0:
+          noded = node.dereference()
+          kb = kb + ((int(noded['index']) + 1) << 2)
+          node = noded['next']
+      i = i + 1
+    self.total_free_blocks[salloc] = kb
+    return kb
+
+
+  def _dump_one_pool(self, arg):
+    size = 0
+    free = 0
+    nodes = 0
+    darg = arg.dereference()
+    active = darg['active']
+    node = active
+    done = 0
+    while done == 0:
+      noded = node.dereference()
+      size = size + ((int(noded['index']) + 1) << 12)
+      free = free + (noded['endp'] - noded['first_avail'])
+      nodes = nodes + 1
+      node = noded['next']
+      if node == active:
+        done = 1
+    if darg['tag'] != 0:
+      tag = darg['tag'].string()
+    else:
+      tag = "No tag"
+    print("Pool '%s' [%s]: %d/%d free (%d blocks) allocator: %s free blocks in allocator: %i kiB" % (tag, arg, free, size, nodes, darg['allocator'], self._allocator_free_blocks(darg['allocator'])))
+    self.free = self.free + free
+    self.size = self.size + size
+    self.nodes = self.nodes + nodes
+
+  def _dump(self, arg, depth):
+    pool = arg
+    print("%*c" % (depth * 4 + 1, " "), end="")
+    self._dump_one_pool(pool)
+    if pool['child'] != 0:
+      self._dump(pool['child'], depth + 1)
+    s = pool['sibling']
+    if s != 0:
+      self._dump(s, depth)
+
+  def invoke (self, arg, from_tty):
+    pool = gdb.parse_and_eval(arg)
+    self.free = 0
+    self.size = 0
+    self.nodes = 0
+    self.total_free_blocks = {}
+    self._dump(pool, 0)
+    print("Total %d/%d free (%d blocks)" % (self.free, self.size, self.nodes))
+    sum = 0
+    for key in self.total_free_blocks:
+      sum = sum + self.total_free_blocks[key]
+    print("Total free allocator blocks: %i kiB" % (sum))
+
+DumpPoolAndChilds ()
+end
+document dump_pool_and_children
+    Dump the whole pool hierarchy starting from the given pool.
 end
 
 # Set sane defaults for common signals:
diff --git a/Apache-apr2.dsw b/Apache-apr2.dsw
index 2dfc391..c3f75e6 100644
--- a/Apache-apr2.dsw
+++ b/Apache-apr2.dsw
@@ -446,9 +446,6 @@ Package=<5>
 
 Package=<4>
 {{{
-    Begin Project Dependency
-    Project_Dep_Name expat_static
-    End Project Dependency
 }}}
 
 ###############################################################################
@@ -573,30 +570,6 @@ Package=<4>
 
 ###############################################################################
 
-Project: "expat"=".\srclib\expat\lib\expat.dsp" - Package Owner=<4>
-
-Package=<5>
-{{{
-}}}
-
-Package=<4>
-{{{
-}}}
-
-###############################################################################
-
-Project: "expat_static"=".\srclib\expat\lib\expat_static.dsp" - Package Owner=<4>
-
-Package=<5>
-{{{
-}}}
-
-Package=<4>
-{{{
-}}}
-
-###############################################################################
-
 Project: "fcgistarter"=.\support\fcgistarter.dsp - Package Owner=<4>
 
 Package=<5>
@@ -710,9 +683,6 @@ Package=<5>
 
 Package=<4>
 {{{
-    Begin Project Dependency
-    Project_Dep_Name expat
-    End Project Dependency
 }}}
 
 ###############################################################################
diff --git a/Apache.dsw b/Apache.dsw
index d5c97b9..30866bc 100644
--- a/Apache.dsw
+++ b/Apache.dsw
@@ -494,9 +494,6 @@ Package=<4>
     Begin Project Dependency
     Project_Dep_Name apriconv
     End Project Dependency
-    Begin Project Dependency
-    Project_Dep_Name xml
-    End Project Dependency
 }}}
 
 ###############################################################################
@@ -866,9 +863,6 @@ Package=<4>
     Begin Project Dependency
     Project_Dep_Name libapriconv
     End Project Dependency
-    Begin Project Dependency
-    Project_Dep_Name xml
-    End Project Dependency
 }}}
 
 ###############################################################################
@@ -3521,18 +3515,6 @@ Package=<4>
 
 ###############################################################################
 
-Project: "xml"=".\srclib\apr-util\xml\expat\lib\xml.dsp" - Package Owner=<4>
-
-Package=<5>
-{{{
-}}}
-
-Package=<4>
-{{{
-}}}
-
-###############################################################################
-
 Global:
 
 Package=<5>
diff --git a/CHANGES b/CHANGES
index 9d560e4..ab0cd5d 100644
--- a/CHANGES
+++ b/CHANGES
@@ -1,7 +1,101 @@
                                                          -*- coding: utf-8 -*-
+Changes with Apache 2.4.29
+
+  *) mod_unique_id: Use output of the PRNG rather than IP address and
+     pid, avoiding sleep() call and possible DNS issues at startup,
+     plus improving randomness for IPv6-only hosts.  [Jan Kaluza]
+
+  *) mod_rewrite, core: Avoid the 'Vary: Host' response header when HTTP_HOST
+     is used in a condition that evaluates to true. PR 58231 [Luca Toscano]
+
+  *) mod_http2: v0.10.12, removed optimization for mutex handling in bucket
+     beams that could lead to assertion failure in edge cases.
+     [Stefan Eissing] 
+
+  *) mod_proxy: Fix regression for non decimal loadfactor parameter introduced
+     in 2.4.28.  [Jim Jagielski]
+
+  *) mod_authz_dbd: fix a segmentation fault if AuthzDBDQuery is not set.
+     PR 61546.  [Lubos Uhliarik <luhliari redhat.com>]
+
+  *) mod_rewrite: Add support for starting External Rewriting Programs
+     as non-root user on UNIX systems by specifying username and group
+     name as third argument of RewriteMap directive.  [Jan Kaluza]
+
+  *) core: Rewrite the Content-Length filter to avoid excessive memory
+     consumption. Chunked responses will be generated in more cases
+     than in previous releases.  PR 61222.  [Joe Orton, Ruediger Pluem]
+
+  *) mod_ssl: Fix SessionTicket callback return value, which does seem to
+     matter with OpenSSL 1.1. [Yann Ylavic]
+
+Changes with Apache 2.4.28
+
+  *) SECURITY: CVE-2017-9798 (cve.mitre.org)
+     Corrupted or freed memory access. <Limit[Except]> must now be used in the
+     main configuration file (httpd.conf) to register HTTP methods before the
+     .htaccess files.  [Yann Ylavic]
+
+  *) event: Avoid possible blocking in the listener thread when shutting down
+     connections. PR 60956.  [Yann Ylavic]
+
+  *) mod_speling: Don't embed referer data in a link in error page.
+     PR 38923 [Nick Kew]
+
+  *) htdigest: prevent a buffer overflow when a string exceeds the allowed max
+     length in a password file.
+     [Luca Toscano, Hanno Böck <hanno hboeck de>]
+
+  *) mod_proxy: loadfactor parameter can now be a decimal number (eg: 1.25).
+     [Jim Jagielski]
+
+  *) mod_proxy_wstunnel: Allow upgrade to any protocol dynamically.
+     PR 61142.
+
+  *) mod_watchdog/mod_proxy_hcheck: Time intervals can now be spefified
+     down to the millisecond. Supports 'mi' (minute), 'ms' (millisecond),
+     's' (second) and 'hr' (hour!) time suffixes. [Jim Jagielski]
+
+  *) mod_http2: Fix for stalling when more than 32KB are written to a
+     suspended stream.  [Stefan Eissing]
+
+  *) build: allow configuration without APR sources.  [Jacob Champion]
+
+  *) mod_ssl, ab: Fix compatibility with LibreSSL.  PR 61184.
+     [Bernard Spil <brnrd freebsd.org>, Michael Schlenker <msc contact.de>,
+      Yann Ylavic]
+
+  *) core/log: Support use of optional "tag" in syslog entries.
+     PR 60525. [Ben Rubson <ben.rubson gmail.com>, Jim Jagielski]
+
+  *) mod_proxy: Fix ProxyAddHeaders merging.  [Joe Orton]
+ 
+  *) core: Disallow multiple Listen on the same IP:port when listener buckets
+     are configured (ListenCoresBucketsRatio > 0), consistently with the single
+     bucket case (default), thus avoiding the leak of the corresponding socket
+     descriptors on graceful restart.  [Yann Ylavic]
+
+  *) event: Avoid listener periodic wake ups by using the pollset wake-ability
+     when available.  PR 57399.  [Yann Ylavic, Luca Toscano]
+
+  *) mod_proxy_wstunnel: Fix detection of unresponded request which could have
+     led to spurious HTTP 502 error messages sent on upgrade connections.
+     PR 61283.  [Yann Ylavic]
 
 Changes with Apache 2.4.27
 
+  *) SECURITY: CVE-2017-9789 (cve.mitre.org)
+     mod_http2: Read after free. When under stress, closing many connections,
+     the HTTP/2 handling code would sometimes access memory after it has been
+     freed, resulting in potentially erratic behaviour.
+     [Stefan Eissing]
+
+  *) SECURITY: CVE-2017-9788 (cve.mitre.org)
+     mod_auth_digest: Uninitialized memory reflection.  The value placeholder
+     in [Proxy-]Authorization headers type 'Digest' was not initialized or
+     reset before or between successive key=value assignments.
+     [William Rowe]
+
   *) COMPATIBILITY: mod_lua: Remove the undocumented exported 'apr_table'
      global variable when using Lua 5.2 or later. This was exported as a
      side effect from luaL_register, which is no longer supported as of
@@ -22,7 +116,7 @@ Changes with Apache 2.4.27
   *) mod_http2: Simplify ready queue, less memory and better performance. Update
      mod_http2 version to 1.10.7. [Stefan Eissing]
   
-  *) Allow single-char field names inadvertantly disallowed in 2.4.25.
+  *) Allow single-char field names inadvertently disallowed in 2.4.25.
      PR 61220. [Yann Ylavic]
 
   *) htpasswd / htdigest: Do not apply the strict permissions of the temporary
diff --git a/LICENSE b/LICENSE
index cfe4716..de66166 100644
--- a/LICENSE
+++ b/LICENSE
@@ -472,25 +472,6 @@ For the srclib\apr-util\test\testmd4.c component:
  * documentation and/or software.
  */
 
-For the srclib\apr-util\xml\expat\conftools\install-sh component:
-
-#
-# install - install a program, script, or datafile
-# This comes from X11R5 (mit/util/scripts/install.sh).
-#
-# Copyright 1991 by the Massachusetts Institute of Technology
-#
-# Permission to use, copy, modify, distribute, and sell this software and its
-# documentation for any purpose is hereby granted without fee, provided that
-# the above copyright notice appear in all copies and that both that
-# copyright notice and this permission notice appear in supporting
-# documentation, and that the name of M.I.T. not be used in advertising or
-# publicity pertaining to distribution of the software without specific,
-# written prior permission.  M.I.T. makes no representations about the
-# suitability of this software for any purpose.  It is provided "as is"
-# without express or implied warranty.
-#
-
 For the test\zb.c component:
 
 /*                          ZeusBench V1.01
@@ -520,29 +501,3 @@ Thanks to the following people for their input:
 
 */
 
-For the expat xml parser component:
-
-Copyright (c) 1998, 1999, 2000 Thai Open Source Software Center Ltd
-                               and Clark Cooper
-
-Permission is hereby granted, free of charge, to any person obtaining
-a copy of this software and associated documentation files (the
-"Software"), to deal in the Software without restriction, including
-without limitation the rights to use, copy, modify, merge, publish,
-distribute, sublicense, and/or sell copies of the Software, and to
-permit persons to whom the Software is furnished to do so, subject to
-the following conditions:
-	
-The above copyright notice and this permission notice shall be included
-in all copies or substantial portions of the Software.
-	
-THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
-IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
-CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
-TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
-SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-
-
-====================================================================
diff --git a/Makefile.in b/Makefile.in
index 6d952b2..6ded87e 100644
--- a/Makefile.in
+++ b/Makefile.in
@@ -45,7 +45,7 @@ install-conf:
 	    	if [ -f $$i ] ; then \
 	    	( \
 	    		n_lm=`awk 'BEGIN {n=0} /@@LoadModule@@/ {n+=1} END {print n}' < $$i`; \
-	    		if test $$n_lm -eq 0 -o "x$(DSO_MODULES)" = "x"; then \
+	    		if test $$n_lm -eq 0 -o "x$(MPM_MODULES)$(DSO_MODULES)" = "x"; then \
 	    			sed -e 's#@@ServerRoot@@#$(prefix)#g' \
 	    				-e 's#@@Port@@#$(PORT)#g' \
 	    				-e 's#@@SSLPort@@#$(SSLPORT)#g' \
@@ -68,28 +68,38 @@ install-conf:
 	    			else \
 	    				have_cgid="0"; \
 	    			fi; \
-	    			for j in $(DSO_MODULES) "^EOL^"; do \
+	    			for j in $(MPM_MODULES) "^EOL^"; do \
 	    				if test $$j != "^EOL^"; then \
-	    					if echo ",$(ENABLED_DSO_MODULES),"|$(EGREP) ",$$j," > /dev/null ; then \
+	    					if echo ",$(ENABLED_MPM_MODULE),"|$(EGREP) ",$$j," > /dev/null ; then \
 	    						loading_disabled=""; \
 	    					else \
 	    						loading_disabled="#"; \
 	    					fi; \
-	    					if test "$(LOAD_ALL_MODULES)" = "yes"; then \
+						echo "$${loading_disabled}LoadModule $${j}_module $(rel_libexecdir)/mod_$${j}.so"; \
+					fi; \
+	    			done; \
+	    			for j in $(DSO_MODULES) "^EOL^"; do \
+	    				if test $$j != "^EOL^"; then \
+	    					if echo ",$(ENABLED_DSO_MODULES),"|$(EGREP) ",$$j," > /dev/null ; then \
 	    						loading_disabled=""; \
+	    					else \
+	    						loading_disabled="#"; \
+		    					if test "$(LOAD_ALL_MODULES)" = "yes"; then \
+		    						loading_disabled=""; \
+	    						fi; \
 	    					fi; \
-							if test $$j = "cgid" -a "$$have_cgi" = "1"; then \
-								echo "<IfModule !mpm_prefork_module>"; \
-								echo "	$${loading_disabled}LoadModule $${j}_module $(rel_libexecdir)/mod_$${j}.so"; \
-								echo "</IfModule>"; \
-							elif test $$j = "cgi" -a "$$have_cgid" = "1"; then \
-								echo "<IfModule mpm_prefork_module>"; \
-								echo "	$${loading_disabled}LoadModule $${j}_module $(rel_libexecdir)/mod_$${j}.so"; \
-								echo "</IfModule>"; \
-							else \
-								echo "$${loading_disabled}LoadModule $${j}_module $(rel_libexecdir)/mod_$${j}.so"; \
-							fi; \
+						if test $$j = "cgid" -a "$$have_cgi" = "1"; then \
+							echo "<IfModule !mpm_prefork_module>"; \
+							echo "	$${loading_disabled}LoadModule $${j}_module $(rel_libexecdir)/mod_$${j}.so"; \
+							echo "</IfModule>"; \
+						elif test $$j = "cgi" -a "$$have_cgid" = "1"; then \
+							echo "<IfModule mpm_prefork_module>"; \
+							echo "	$${loading_disabled}LoadModule $${j}_module $(rel_libexecdir)/mod_$${j}.so"; \
+							echo "</IfModule>"; \
+						else \
+							echo "$${loading_disabled}LoadModule $${j}_module $(rel_libexecdir)/mod_$${j}.so"; \
 						fi; \
+					fi; \
 	    			done; \
 	    			sed -e '1,/@@LoadModule@@/d' \
 	    				-e '/@@LoadModule@@/d' \
diff --git a/acinclude.m4 b/acinclude.m4
index 0fdf1d4..90ca74f 100644
--- a/acinclude.m4
+++ b/acinclude.m4
@@ -90,6 +90,8 @@ AC_DEFUN([APACHE_GEN_CONFIG_VARS],[
   APACHE_SUBST(MK_IMPLIB)
   APACHE_SUBST(MKDEP)
   APACHE_SUBST(INSTALL_PROG_FLAGS)
+  APACHE_SUBST(MPM_MODULES)
+  APACHE_SUBST(ENABLED_MPM_MODULE)
   APACHE_SUBST(DSO_MODULES)
   APACHE_SUBST(ENABLED_DSO_MODULES)
   APACHE_SUBST(LOAD_ALL_MODULES)
@@ -262,10 +264,10 @@ DISTCLEAN_TARGETS = modules.mk
 static =
 shared = $libname
 EOF
-            DSO_MODULES="$DSO_MODULES mpm_$1"
+            MPM_MODULES="$MPM_MODULES mpm_$1"
             # add default MPM to LoadModule list
             if test $1 = $default_mpm; then
-                ENABLED_DSO_MODULES="${ENABLED_DSO_MODULES},mpm_$1"
+                ENABLED_MPM_MODULE="mpm_$1"
             fi
         fi
         $4
@@ -724,22 +726,26 @@ YES_IS_DEFINED
 ])
 
 dnl
-dnl APACHE_ADD_GCC_CFLAGS
+dnl APACHE_ADD_GCC_CFLAG
 dnl
-dnl Check if compiler is gcc and supports flag. If yes, add to CFLAGS.
+dnl Check if compiler is gcc and supports flag. If yes, add to NOTEST_CFLAGS.
+dnl NOTEST_CFLAGS is merged lately, thus it won't accumulate in CFLAGS here.
+dnl Also, AC_LANG_PROGRAM() itself is known to trigger [-Wstrict-prototypes]
+dnl with some autoconf versions, so we force -Wno-strict-prototypes for the
+dnl check to avoid spurious failures when adding flags like -Werror.
 dnl
 AC_DEFUN([APACHE_ADD_GCC_CFLAG], [
   define([ap_gcc_ckvar], [ac_cv_gcc_]translit($1, [-:.=], [____]))
   if test "$GCC" = "yes"; then
     AC_CACHE_CHECK([whether gcc accepts $1], ap_gcc_ckvar, [
       save_CFLAGS="$CFLAGS"
-      CFLAGS="$CFLAGS $1"
+      CFLAGS="$CFLAGS $1 -Wno-strict-prototypes"
       AC_COMPILE_IFELSE([AC_LANG_PROGRAM()],
         [ap_gcc_ckvar=yes], [ap_gcc_ckvar=no])
       CFLAGS="$save_CFLAGS"
     ])
     if test "$]ap_gcc_ckvar[" = "yes" ; then
-       APR_ADDTO(CFLAGS,[$1])
+       APR_ADDTO(NOTEST_CFLAGS,[$1])
     fi
   fi
   undefine([ap_gcc_ckvar])
diff --git a/build/config_vars.sh.in b/build/config_vars.sh.in
index cbb4a39..6525a4e 100644
--- a/build/config_vars.sh.in
+++ b/build/config_vars.sh.in
@@ -46,6 +46,8 @@ exec sed "
 /MPM_LIB/d
 /APACHECTL_ULIMIT/d
 /[a-z]*_LTFLAGS/d
+/^MPM_MODULES/d
+/^ENABLED_MPM_MODULE/d
 /^DSO_MODULES/d
 /^MODULE_/d
 /^PORT/d
diff --git a/buildconf b/buildconf
index a58845d..4b35969 100755
--- a/buildconf
+++ b/buildconf
@@ -39,32 +39,80 @@ apu_src_dir=""
 
 while test $# -gt 0 
 do
-  # Normalize
-  case "$1" in
-  -*=*) optarg=`echo "$1" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
-  *) optarg= ;;
-  esac
-
-  case "$1" in
-  --with-apr=*)
-  apr_src_dir=$optarg
-  ;;
-  esac
-
-  case "$1" in
-  --with-apr-util=*)
-  apu_src_dir=$optarg
-  ;;
-  esac
-
-  shift
+    # Normalize
+    case "$1" in
+    -*=*) optarg=`echo "$1" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
+    *) optarg= ;;
+    esac
+
+    case "$1" in
+    --with-apr=*)
+        apr_src_dir=$optarg
+        ;;
+
+    --with-apr-util=*)
+        apu_src_dir=$optarg
+        ;;
+
+    -h|--help)
+        cat <<EOF
+buildconf: generates the files needed to configure httpd.
+
+Usage: $0 [OPTION]...
+
+Configuration:
+  -h, --help               display this help and exit
+
+  --with-apr=SRCDIR        define a space-separated list of directories to
+                           search for the APR source code. If, instead of a
+                           directory, an apr-config executable name is passed,
+                           APR-Config Mode is enabled (see below). Defaults to
+                           "srclib/apr ../apr"
+  --with-apr-util=SRCDIR   define a space-separated list of directories to
+                           search for the APR-util source code. Defaults to the
+                           same location as the --with-apr SRCDIR, but with
+                           "apr" replaced with "apr-util" or "aprutil". Ignored
+                           in APR-Config Mode.
+
+APR-Config Mode:
+
+  When passing an apr-config executable to --with-apr, buildconf will attempt to
+  copy build scripts from various installed locations on your system instead of
+  an APR source tree. This allows you to configure httpd from source without
+  also requiring you to download the APR and/or APR-util sources.
+
+  For example:
+
+      ./buildconf --with-apr=apr-1-config
+
+  For this functionality to work reliably, you must have automake >= 1.12 and be
+  using a distribution that includes both find_apr.m4 and find_apu.m4 in the
+  --installbuilddir pointed to by apr-config.
+
+Environment variables used by buildconf:
+  AUTOCONF           autoconf executable name [autoconf]
+  AUTOMAKE           automake executable name [automake]
+  AUTOHEADER         autoheader executable name [autoheader]
+EOF
+        exit
+        ;;
+
+    *)
+        echo "unknown option $1 (try --help for usage)"
+        exit 1
+        ;;
+    esac
+
+    shift
 done
 
 #
-# Check to be sure that we have the srclib dependencies checked-out
+# Check to be sure that we have the srclib dependencies checked-out, or that a
+# working apr-config installation has been specified.
 #
 
 should_exit=0
+apr_config=         # path to apr-config (empty if using a source directory)
 apr_found=0
 apu_found=0
 apr_major_version=2
@@ -76,6 +124,25 @@ do
         apr_src_dir=$dir
         apr_found=1
         break
+    elif which "${dir}" >/dev/null 2>&1; then
+        # We're using apr-config. Do a sanity check.
+        apr_config=`which "${dir}"`
+        echo "testing apr-config executable: ${apr_config}"
+
+        version=`"${apr_config}" --version`
+        version=`echo "${version}" | sed -n '/^[0-9][0-9]*\.[0-9][0-9]*\.[0-9][0-9]*$/p'`
+
+        if [ -z "${version}" ]; then
+            echo "apr-config gave us an invalid --version"
+            apr_config=
+            continue
+        fi
+
+        echo "using apr-config version ${version}"
+        apr_major_version=${version} # we'll make a real "major version" later
+        apr_src_dir=`"${apr_config}" --installbuilddir`
+        apr_found=1
+        break
     fi
 done
 
@@ -89,12 +156,18 @@ if [ $apr_found -lt 1 ]; then
     echo "   svn co http://svn.apache.org/repos/asf/apr/apr/trunk srclib/apr"
     echo ""
     should_exit=1
+elif [ -n "${apr_config}" ]; then
+    apr_major_version=`echo "${apr_major_version}" | sed 's/\..*//'`
 else
     apr_major_version=`grep "#define APR_MAJOR_VERSION" \
                       $apr_src_dir/include/apr_version.h | sed 's/[^0-9]//g'`
 fi
 
-if [ $apr_major_version -lt 2 ] ; then
+# Find APR-util. Note: if we're using apr-config, we can completely skip this,
+# even if APR is version 1. That's because we only end up caring about
+# find_apu.m4, which is not actually installed in the standard APR-util
+# distribution to begin with.
+if [ -z "${apr_config}" -a $apr_major_version -lt 2 ] ; then
     if test -z "$apu_src_dir"; then
         apu_src_dir=`echo $apr_src_dir | sed -e 's#/apr#/apr-util#g;'`
         apu_src_dir="$apu_src_dir `echo $apr_src_dir | sed -e 's#/apr#/aprutil#;g'`"
@@ -177,23 +250,43 @@ if [ $apr_major_version -lt 2 ] ; then
 fi
 
 echo copying build files
-cp $apr_src_dir/build/config.guess $apr_src_dir/build/config.sub \
-   $apr_src_dir/build/PrintPath $apr_src_dir/build/apr_common.m4 \
-   $apr_src_dir/build/find_apr.m4 build
-if [ $apr_major_version -lt 2 ] ; then
-    cp $apu_src_dir/build/find_apu.m4 build
+if [ -n "${apr_config}" ]; then
+    # If we're using apr-config, we switch things up a little bit:
+    # - use automake's config.* scripts instead of APR's
+    # - use the included PrintPath instead of copying from APR
+    # - assume find_apu.m4 is also in APR's --installbuilddir
+
+    # Figure out where to copy config.* from.
+    automake=${AUTOMAKE:-automake}
+    am_libdir=`"${automake}" --print-libdir`
+    cp "${am_libdir}/config.guess" "${am_libdir}/config.sub" build
+
+    # Remember that in this case, $apr_src_dir points to the build directory.
+    cp "$apr_src_dir/apr_common.m4" "$apr_src_dir/find_apr.m4" build
+    if [ $apr_major_version -lt 2 ] ; then
+        cp "$apr_src_dir/find_apu.m4" build
+    fi
+else
+    cp $apr_src_dir/build/config.guess $apr_src_dir/build/config.sub \
+       $apr_src_dir/build/PrintPath $apr_src_dir/build/apr_common.m4 \
+       $apr_src_dir/build/find_apr.m4 build
+    if [ $apr_major_version -lt 2 ] ; then
+        cp $apu_src_dir/build/find_apu.m4 build
+    fi
 fi
 
 # Remove any libtool files so one can switch between libtool 1.3
 # and libtool 1.4 by simply rerunning the buildconf script.
 (cd build ; rm -f ltconfig ltmain.sh)
 
-# Optionally copy libtool-1.3.x files
-if [ -f $apr_src_dir/build/ltconfig ]; then
-    cp $apr_src_dir/build/ltconfig build
-fi
-if [ -f $apr_src_dir/build/ltmain.sh ]; then
-    cp $apr_src_dir/build/ltmain.sh build
+if [ -z "${apr_config}" ]; then
+    # Optionally copy libtool-1.3.x files
+    if [ -f $apr_src_dir/build/ltconfig ]; then
+        cp $apr_src_dir/build/ltconfig build
+    fi
+    if [ -f $apr_src_dir/build/ltmain.sh ]; then
+        cp $apr_src_dir/build/ltmain.sh build
+    fi
 fi
 
 echo rebuilding $config_h_in
diff --git a/configure b/configure
index 3362234..a4aab88 100755
--- a/configure
+++ b/configure
@@ -637,6 +637,8 @@ APR_BINDIR
 LOAD_ALL_MODULES
 ENABLED_DSO_MODULES
 DSO_MODULES
+ENABLED_MPM_MODULE
+MPM_MODULES
 INSTALL_PROG_FLAGS
 MK_IMPLIB
 SH_LIBTOOL
@@ -7949,49 +7951,28 @@ if test "${enable_maintainer_mode+set}" = set; then :
   enableval=$enable_maintainer_mode;
   if test "$enableval" = "yes"; then
 
-  if test "x$CPPFLAGS" = "x"; then
-    test "x$silent" != "xyes" && echo "  setting CPPFLAGS to \"-DAP_DEBUG\""
-    CPPFLAGS="-DAP_DEBUG"
+  if test "x$NOTEST_CPPFLAGS" = "x"; then
+    test "x$silent" != "xyes" && echo "  setting NOTEST_CPPFLAGS to \"-DAP_DEBUG\""
+    NOTEST_CPPFLAGS="-DAP_DEBUG"
   else
     apr_addto_bugger="-DAP_DEBUG"
     for i in $apr_addto_bugger; do
       apr_addto_duplicate="0"
-      for j in $CPPFLAGS; do
+      for j in $NOTEST_CPPFLAGS; do
         if test "x$i" = "x$j"; then
           apr_addto_duplicate="1"
           break
         fi
       done
       if test $apr_addto_duplicate = "0"; then
-        test "x$silent" != "xyes" && echo "  adding \"$i\" to CPPFLAGS"
-        CPPFLAGS="$CPPFLAGS $i"
+        test "x$silent" != "xyes" && echo "  adding \"$i\" to NOTEST_CPPFLAGS"
+        NOTEST_CPPFLAGS="$NOTEST_CPPFLAGS $i"
       fi
     done
   fi
 
     if test "$GCC" = "yes"; then
 
-  if test "x$CFLAGS" = "x"; then
-    test "x$silent" != "xyes" && echo "  setting CFLAGS to \"-Wall -Wmissing-prototypes -Wstrict-prototypes -Wmissing-declarations -Wpointer-arith\""
-    CFLAGS="-Wall -Wmissing-prototypes -Wstrict-prototypes -Wmissing-declarations -Wpointer-arith"
-  else
-    apr_addto_bugger="-Wall -Wmissing-prototypes -Wstrict-prototypes -Wmissing-declarations -Wpointer-arith"
-    for i in $apr_addto_bugger; do
-      apr_addto_duplicate="0"
-      for j in $CFLAGS; do
-        if test "x$i" = "x$j"; then
-          apr_addto_duplicate="1"
-          break
-        fi
-      done
-      if test $apr_addto_duplicate = "0"; then
-        test "x$silent" != "xyes" && echo "  adding \"$i\" to CFLAGS"
-        CFLAGS="$CFLAGS $i"
-      fi
-    done
-  fi
-
-
 
   if test "$GCC" = "yes"; then
     { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gcc accepts -std=c89" >&5
@@ -8001,7 +7982,7 @@ if ${ac_cv_gcc__std_c89+:} false; then :
 else
 
       save_CFLAGS="$CFLAGS"
-      CFLAGS="$CFLAGS -std=c89"
+      CFLAGS="$CFLAGS -std=c89 -Wno-strict-prototypes"
       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
 /* end confdefs.h.  */
 
@@ -8026,22 +8007,22 @@ fi
 $as_echo "$ac_cv_gcc__std_c89" >&6; }
     if test "$ac_cv_gcc__std_c89" = "yes" ; then
 
-  if test "x$CFLAGS" = "x"; then
-    test "x$silent" != "xyes" && echo "  setting CFLAGS to \"-std=c89\""
-    CFLAGS="-std=c89"
+  if test "x$NOTEST_CFLAGS" = "x"; then
+    test "x$silent" != "xyes" && echo "  setting NOTEST_CFLAGS to \"-std=c89\""
+    NOTEST_CFLAGS="-std=c89"
   else
     apr_addto_bugger="-std=c89"
     for i in $apr_addto_bugger; do
       apr_addto_duplicate="0"
-      for j in $CFLAGS; do
+      for j in $NOTEST_CFLAGS; do
         if test "x$i" = "x$j"; then
           apr_addto_duplicate="1"
           break
         fi
       done
       if test $apr_addto_duplicate = "0"; then
-        test "x$silent" != "xyes" && echo "  adding \"$i\" to CFLAGS"
-        CFLAGS="$CFLAGS $i"
+        test "x$silent" != "xyes" && echo "  adding \"$i\" to NOTEST_CFLAGS"
+        NOTEST_CFLAGS="$NOTEST_CFLAGS $i"
       fi
     done
   fi
@@ -8060,7 +8041,7 @@ if ${ac_cv_gcc__Werror+:} false; then :
 else
 
       save_CFLAGS="$CFLAGS"
-      CFLAGS="$CFLAGS -Werror"
+      CFLAGS="$CFLAGS -Werror -Wno-strict-prototypes"
       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
 /* end confdefs.h.  */
 
@@ -8085,22 +8066,258 @@ fi
 $as_echo "$ac_cv_gcc__Werror" >&6; }
     if test "$ac_cv_gcc__Werror" = "yes" ; then
 
-  if test "x$CFLAGS" = "x"; then
-    test "x$silent" != "xyes" && echo "  setting CFLAGS to \"-Werror\""
-    CFLAGS="-Werror"
+  if test "x$NOTEST_CFLAGS" = "x"; then
+    test "x$silent" != "xyes" && echo "  setting NOTEST_CFLAGS to \"-Werror\""
+    NOTEST_CFLAGS="-Werror"
   else
     apr_addto_bugger="-Werror"
     for i in $apr_addto_bugger; do
       apr_addto_duplicate="0"
-      for j in $CFLAGS; do
+      for j in $NOTEST_CFLAGS; do
         if test "x$i" = "x$j"; then
           apr_addto_duplicate="1"
           break
         fi
       done
       if test $apr_addto_duplicate = "0"; then
-        test "x$silent" != "xyes" && echo "  adding \"$i\" to CFLAGS"
-        CFLAGS="$CFLAGS $i"
+        test "x$silent" != "xyes" && echo "  adding \"$i\" to NOTEST_CFLAGS"
+        NOTEST_CFLAGS="$NOTEST_CFLAGS $i"
+      fi
+    done
+  fi
+
+    fi
+  fi
+
+
+
+
+  if test "$GCC" = "yes"; then
+    { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gcc accepts -Wall" >&5
+$as_echo_n "checking whether gcc accepts -Wall... " >&6; }
+if ${ac_cv_gcc__Wall+:} false; then :
+  $as_echo_n "(cached) " >&6
+else
+
+      save_CFLAGS="$CFLAGS"
+      CFLAGS="$CFLAGS -Wall -Wno-strict-prototypes"
+      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h.  */
+
+int
+main ()
+{
+
+  ;
+  return 0;
+}
+_ACEOF
+if ac_fn_c_try_compile "$LINENO"; then :
+  ac_cv_gcc__Wall=yes
+else
+  ac_cv_gcc__Wall=no
+fi
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+      CFLAGS="$save_CFLAGS"
+
+fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_gcc__Wall" >&5
+$as_echo "$ac_cv_gcc__Wall" >&6; }
+    if test "$ac_cv_gcc__Wall" = "yes" ; then
+
+  if test "x$NOTEST_CFLAGS" = "x"; then
+    test "x$silent" != "xyes" && echo "  setting NOTEST_CFLAGS to \"-Wall\""
+    NOTEST_CFLAGS="-Wall"
+  else
+    apr_addto_bugger="-Wall"
+    for i in $apr_addto_bugger; do
+      apr_addto_duplicate="0"
+      for j in $NOTEST_CFLAGS; do
+        if test "x$i" = "x$j"; then
+          apr_addto_duplicate="1"
+          break
+        fi
+      done
+      if test $apr_addto_duplicate = "0"; then
+        test "x$silent" != "xyes" && echo "  adding \"$i\" to NOTEST_CFLAGS"
+        NOTEST_CFLAGS="$NOTEST_CFLAGS $i"
+      fi
+    done
+  fi
+
+    fi
+  fi
+
+
+
+
+  if test "$GCC" = "yes"; then
+    { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gcc accepts -Wstrict-prototypes" >&5
+$as_echo_n "checking whether gcc accepts -Wstrict-prototypes... " >&6; }
+if ${ac_cv_gcc__Wstrict_prototypes+:} false; then :
+  $as_echo_n "(cached) " >&6
+else
+
+      save_CFLAGS="$CFLAGS"
+      CFLAGS="$CFLAGS -Wstrict-prototypes -Wno-strict-prototypes"
+      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h.  */
+
+int
+main ()
+{
+
+  ;
+  return 0;
+}
+_ACEOF
+if ac_fn_c_try_compile "$LINENO"; then :
+  ac_cv_gcc__Wstrict_prototypes=yes
+else
+  ac_cv_gcc__Wstrict_prototypes=no
+fi
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+      CFLAGS="$save_CFLAGS"
+
+fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_gcc__Wstrict_prototypes" >&5
+$as_echo "$ac_cv_gcc__Wstrict_prototypes" >&6; }
+    if test "$ac_cv_gcc__Wstrict_prototypes" = "yes" ; then
+
+  if test "x$NOTEST_CFLAGS" = "x"; then
+    test "x$silent" != "xyes" && echo "  setting NOTEST_CFLAGS to \"-Wstrict-prototypes\""
+    NOTEST_CFLAGS="-Wstrict-prototypes"
+  else
+    apr_addto_bugger="-Wstrict-prototypes"
+    for i in $apr_addto_bugger; do
+      apr_addto_duplicate="0"
+      for j in $NOTEST_CFLAGS; do
+        if test "x$i" = "x$j"; then
+          apr_addto_duplicate="1"
+          break
+        fi
+      done
+      if test $apr_addto_duplicate = "0"; then
+        test "x$silent" != "xyes" && echo "  adding \"$i\" to NOTEST_CFLAGS"
+        NOTEST_CFLAGS="$NOTEST_CFLAGS $i"
+      fi
+    done
+  fi
+
+    fi
+  fi
+
+
+
+
+  if test "$GCC" = "yes"; then
+    { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gcc accepts -Wmissing-prototypes" >&5
+$as_echo_n "checking whether gcc accepts -Wmissing-prototypes... " >&6; }
+if ${ac_cv_gcc__Wmissing_prototypes+:} false; then :
+  $as_echo_n "(cached) " >&6
+else
+
+      save_CFLAGS="$CFLAGS"
+      CFLAGS="$CFLAGS -Wmissing-prototypes -Wno-strict-prototypes"
+      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h.  */
+
+int
+main ()
+{
+
+  ;
+  return 0;
+}
+_ACEOF
+if ac_fn_c_try_compile "$LINENO"; then :
+  ac_cv_gcc__Wmissing_prototypes=yes
+else
+  ac_cv_gcc__Wmissing_prototypes=no
+fi
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+      CFLAGS="$save_CFLAGS"
+
+fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_gcc__Wmissing_prototypes" >&5
+$as_echo "$ac_cv_gcc__Wmissing_prototypes" >&6; }
+    if test "$ac_cv_gcc__Wmissing_prototypes" = "yes" ; then
+
+  if test "x$NOTEST_CFLAGS" = "x"; then
+    test "x$silent" != "xyes" && echo "  setting NOTEST_CFLAGS to \"-Wmissing-prototypes\""
+    NOTEST_CFLAGS="-Wmissing-prototypes"
+  else
+    apr_addto_bugger="-Wmissing-prototypes"
+    for i in $apr_addto_bugger; do
+      apr_addto_duplicate="0"
+      for j in $NOTEST_CFLAGS; do
+        if test "x$i" = "x$j"; then
+          apr_addto_duplicate="1"
+          break
+        fi
+      done
+      if test $apr_addto_duplicate = "0"; then
+        test "x$silent" != "xyes" && echo "  adding \"$i\" to NOTEST_CFLAGS"
+        NOTEST_CFLAGS="$NOTEST_CFLAGS $i"
+      fi
+    done
+  fi
+
+    fi
+  fi
+
+
+
+
+  if test "$GCC" = "yes"; then
+    { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gcc accepts -Wmissing-declarations" >&5
+$as_echo_n "checking whether gcc accepts -Wmissing-declarations... " >&6; }
+if ${ac_cv_gcc__Wmissing_declarations+:} false; then :
+  $as_echo_n "(cached) " >&6
+else
+
+      save_CFLAGS="$CFLAGS"
+      CFLAGS="$CFLAGS -Wmissing-declarations -Wno-strict-prototypes"
+      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h.  */
+
+int
+main ()
+{
+
+  ;
+  return 0;
+}
+_ACEOF
+if ac_fn_c_try_compile "$LINENO"; then :
+  ac_cv_gcc__Wmissing_declarations=yes
+else
+  ac_cv_gcc__Wmissing_declarations=no
+fi
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+      CFLAGS="$save_CFLAGS"
+
+fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_gcc__Wmissing_declarations" >&5
+$as_echo "$ac_cv_gcc__Wmissing_declarations" >&6; }
+    if test "$ac_cv_gcc__Wmissing_declarations" = "yes" ; then
+
+  if test "x$NOTEST_CFLAGS" = "x"; then
+    test "x$silent" != "xyes" && echo "  setting NOTEST_CFLAGS to \"-Wmissing-declarations\""
+    NOTEST_CFLAGS="-Wmissing-declarations"
+  else
+    apr_addto_bugger="-Wmissing-declarations"
+    for i in $apr_addto_bugger; do
+      apr_addto_duplicate="0"
+      for j in $NOTEST_CFLAGS; do
+        if test "x$i" = "x$j"; then
+          apr_addto_duplicate="1"
+          break
+        fi
+      done
+      if test $apr_addto_duplicate = "0"; then
+        test "x$silent" != "xyes" && echo "  adding \"$i\" to NOTEST_CFLAGS"
+        NOTEST_CFLAGS="$NOTEST_CFLAGS $i"
       fi
     done
   fi
@@ -8119,7 +8336,7 @@ if ${ac_cv_gcc__Wdeclaration_after_statement+:} false; then :
 else
 
       save_CFLAGS="$CFLAGS"
-      CFLAGS="$CFLAGS -Wdeclaration-after-statement"
+      CFLAGS="$CFLAGS -Wdeclaration-after-statement -Wno-strict-prototypes"
       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
 /* end confdefs.h.  */
 
@@ -8144,22 +8361,81 @@ fi
 $as_echo "$ac_cv_gcc__Wdeclaration_after_statement" >&6; }
     if test "$ac_cv_gcc__Wdeclaration_after_statement" = "yes" ; then
 
-  if test "x$CFLAGS" = "x"; then
-    test "x$silent" != "xyes" && echo "  setting CFLAGS to \"-Wdeclaration-after-statement\""
-    CFLAGS="-Wdeclaration-after-statement"
+  if test "x$NOTEST_CFLAGS" = "x"; then
+    test "x$silent" != "xyes" && echo "  setting NOTEST_CFLAGS to \"-Wdeclaration-after-statement\""
+    NOTEST_CFLAGS="-Wdeclaration-after-statement"
   else
     apr_addto_bugger="-Wdeclaration-after-statement"
     for i in $apr_addto_bugger; do
       apr_addto_duplicate="0"
-      for j in $CFLAGS; do
+      for j in $NOTEST_CFLAGS; do
         if test "x$i" = "x$j"; then
           apr_addto_duplicate="1"
           break
         fi
       done
       if test $apr_addto_duplicate = "0"; then
-        test "x$silent" != "xyes" && echo "  adding \"$i\" to CFLAGS"
-        CFLAGS="$CFLAGS $i"
+        test "x$silent" != "xyes" && echo "  adding \"$i\" to NOTEST_CFLAGS"
+        NOTEST_CFLAGS="$NOTEST_CFLAGS $i"
+      fi
+    done
+  fi
+
+    fi
+  fi
+
+
+
+
+  if test "$GCC" = "yes"; then
+    { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gcc accepts -Wpointer-arith" >&5
+$as_echo_n "checking whether gcc accepts -Wpointer-arith... " >&6; }
+if ${ac_cv_gcc__Wpointer_arith+:} false; then :
+  $as_echo_n "(cached) " >&6
+else
+
+      save_CFLAGS="$CFLAGS"
+      CFLAGS="$CFLAGS -Wpointer-arith -Wno-strict-prototypes"
+      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h.  */
+
+int
+main ()
+{
+
+  ;
+  return 0;
+}
+_ACEOF
+if ac_fn_c_try_compile "$LINENO"; then :
+  ac_cv_gcc__Wpointer_arith=yes
+else
+  ac_cv_gcc__Wpointer_arith=no
+fi
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+      CFLAGS="$save_CFLAGS"
+
+fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_gcc__Wpointer_arith" >&5
+$as_echo "$ac_cv_gcc__Wpointer_arith" >&6; }
+    if test "$ac_cv_gcc__Wpointer_arith" = "yes" ; then
+
+  if test "x$NOTEST_CFLAGS" = "x"; then
+    test "x$silent" != "xyes" && echo "  setting NOTEST_CFLAGS to \"-Wpointer-arith\""
+    NOTEST_CFLAGS="-Wpointer-arith"
+  else
+    apr_addto_bugger="-Wpointer-arith"
+    for i in $apr_addto_bugger; do
+      apr_addto_duplicate="0"
+      for j in $NOTEST_CFLAGS; do
+        if test "x$i" = "x$j"; then
+          apr_addto_duplicate="1"
+          break
+        fi
+      done
+      if test $apr_addto_duplicate = "0"; then
+        test "x$silent" != "xyes" && echo "  adding \"$i\" to NOTEST_CFLAGS"
+        NOTEST_CFLAGS="$NOTEST_CFLAGS $i"
       fi
     done
   fi
@@ -8178,7 +8454,7 @@ if ${ac_cv_gcc__Wformat+:} false; then :
 else
 
       save_CFLAGS="$CFLAGS"
-      CFLAGS="$CFLAGS -Wformat"
+      CFLAGS="$CFLAGS -Wformat -Wno-strict-prototypes"
       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
 /* end confdefs.h.  */
 
@@ -8203,22 +8479,22 @@ fi
 $as_echo "$ac_cv_gcc__Wformat" >&6; }
     if test "$ac_cv_gcc__Wformat" = "yes" ; then
 
-  if test "x$CFLAGS" = "x"; then
-    test "x$silent" != "xyes" && echo "  setting CFLAGS to \"-Wformat\""
-    CFLAGS="-Wformat"
+  if test "x$NOTEST_CFLAGS" = "x"; then
+    test "x$silent" != "xyes" && echo "  setting NOTEST_CFLAGS to \"-Wformat\""
+    NOTEST_CFLAGS="-Wformat"
   else
     apr_addto_bugger="-Wformat"
     for i in $apr_addto_bugger; do
       apr_addto_duplicate="0"
-      for j in $CFLAGS; do
+      for j in $NOTEST_CFLAGS; do
         if test "x$i" = "x$j"; then
           apr_addto_duplicate="1"
           break
         fi
       done
       if test $apr_addto_duplicate = "0"; then
-        test "x$silent" != "xyes" && echo "  adding \"$i\" to CFLAGS"
-        CFLAGS="$CFLAGS $i"
+        test "x$silent" != "xyes" && echo "  adding \"$i\" to NOTEST_CFLAGS"
+        NOTEST_CFLAGS="$NOTEST_CFLAGS $i"
       fi
     done
   fi
@@ -8237,7 +8513,7 @@ if ${ac_cv_gcc__Wformat_security+:} false; then :
 else
 
       save_CFLAGS="$CFLAGS"
-      CFLAGS="$CFLAGS -Wformat-security"
+      CFLAGS="$CFLAGS -Wformat-security -Wno-strict-prototypes"
       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
 /* end confdefs.h.  */
 
@@ -8262,22 +8538,22 @@ fi
 $as_echo "$ac_cv_gcc__Wformat_security" >&6; }
     if test "$ac_cv_gcc__Wformat_security" = "yes" ; then
 
-  if test "x$CFLAGS" = "x"; then
-    test "x$silent" != "xyes" && echo "  setting CFLAGS to \"-Wformat-security\""
-    CFLAGS="-Wformat-security"
+  if test "x$NOTEST_CFLAGS" = "x"; then
+    test "x$silent" != "xyes" && echo "  setting NOTEST_CFLAGS to \"-Wformat-security\""
+    NOTEST_CFLAGS="-Wformat-security"
   else
     apr_addto_bugger="-Wformat-security"
     for i in $apr_addto_bugger; do
       apr_addto_duplicate="0"
-      for j in $CFLAGS; do
+      for j in $NOTEST_CFLAGS; do
         if test "x$i" = "x$j"; then
           apr_addto_duplicate="1"
           break
         fi
       done
       if test $apr_addto_duplicate = "0"; then
-        test "x$silent" != "xyes" && echo "  adding \"$i\" to CFLAGS"
-        CFLAGS="$CFLAGS $i"
+        test "x$silent" != "xyes" && echo "  adding \"$i\" to NOTEST_CFLAGS"
+        NOTEST_CFLAGS="$NOTEST_CFLAGS $i"
       fi
     done
   fi
@@ -8296,7 +8572,7 @@ if ${ac_cv_gcc__Wunused+:} false; then :
 else
 
       save_CFLAGS="$CFLAGS"
-      CFLAGS="$CFLAGS -Wunused"
+      CFLAGS="$CFLAGS -Wunused -Wno-strict-prototypes"
       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
 /* end confdefs.h.  */
 
@@ -8321,22 +8597,22 @@ fi
 $as_echo "$ac_cv_gcc__Wunused" >&6; }
     if test "$ac_cv_gcc__Wunused" = "yes" ; then
 
-  if test "x$CFLAGS" = "x"; then
-    test "x$silent" != "xyes" && echo "  setting CFLAGS to \"-Wunused\""
-    CFLAGS="-Wunused"
+  if test "x$NOTEST_CFLAGS" = "x"; then
+    test "x$silent" != "xyes" && echo "  setting NOTEST_CFLAGS to \"-Wunused\""
+    NOTEST_CFLAGS="-Wunused"
   else
     apr_addto_bugger="-Wunused"
     for i in $apr_addto_bugger; do
       apr_addto_duplicate="0"
-      for j in $CFLAGS; do
+      for j in $NOTEST_CFLAGS; do
         if test "x$i" = "x$j"; then
           apr_addto_duplicate="1"
           break
         fi
       done
       if test $apr_addto_duplicate = "0"; then
-        test "x$silent" != "xyes" && echo "  adding \"$i\" to CFLAGS"
-        CFLAGS="$CFLAGS $i"
+        test "x$silent" != "xyes" && echo "  adding \"$i\" to NOTEST_CFLAGS"
+        NOTEST_CFLAGS="$NOTEST_CFLAGS $i"
       fi
     done
   fi
@@ -8347,22 +8623,22 @@ $as_echo "$ac_cv_gcc__Wunused" >&6; }
 
     elif test "$AIX_XLC" = "yes"; then
 
-  if test "x$CFLAGS" = "x"; then
-    test "x$silent" != "xyes" && echo "  setting CFLAGS to \"-qfullpath -qinitauto=FE -qcheck=all -qinfo=pro\""
-    CFLAGS="-qfullpath -qinitauto=FE -qcheck=all -qinfo=pro"
+  if test "x$NOTEST_CFLAGS" = "x"; then
+    test "x$silent" != "xyes" && echo "  setting NOTEST_CFLAGS to \"-qfullpath -qinitauto=FE -qcheck=all -qinfo=pro\""
+    NOTEST_CFLAGS="-qfullpath -qinitauto=FE -qcheck=all -qinfo=pro"
   else
     apr_addto_bugger="-qfullpath -qinitauto=FE -qcheck=all -qinfo=pro"
     for i in $apr_addto_bugger; do
       apr_addto_duplicate="0"
-      for j in $CFLAGS; do
+      for j in $NOTEST_CFLAGS; do
         if test "x$i" = "x$j"; then
           apr_addto_duplicate="1"
           break
         fi
       done
       if test $apr_addto_duplicate = "0"; then
-        test "x$silent" != "xyes" && echo "  adding \"$i\" to CFLAGS"
-        CFLAGS="$CFLAGS $i"
+        test "x$silent" != "xyes" && echo "  adding \"$i\" to NOTEST_CFLAGS"
+        NOTEST_CFLAGS="$NOTEST_CFLAGS $i"
       fi
     done
   fi
@@ -8387,48 +8663,322 @@ if test "${enable_debugger_mode+set}" = set; then :
   enableval=$enable_debugger_mode;
   if test "$enableval" = "yes"; then
 
-  if test "x$CPPFLAGS" = "x"; then
-    test "x$silent" != "xyes" && echo "  setting CPPFLAGS to \"-DAP_DEBUG\""
-    CPPFLAGS="-DAP_DEBUG"
+  if test "x$NOTEST_CPPFLAGS" = "x"; then
+    test "x$silent" != "xyes" && echo "  setting NOTEST_CPPFLAGS to \"-DAP_DEBUG\""
+    NOTEST_CPPFLAGS="-DAP_DEBUG"
   else
     apr_addto_bugger="-DAP_DEBUG"
     for i in $apr_addto_bugger; do
       apr_addto_duplicate="0"
-      for j in $CPPFLAGS; do
+      for j in $NOTEST_CPPFLAGS; do
         if test "x$i" = "x$j"; then
           apr_addto_duplicate="1"
           break
         fi
       done
       if test $apr_addto_duplicate = "0"; then
-        test "x$silent" != "xyes" && echo "  adding \"$i\" to CPPFLAGS"
-        CPPFLAGS="$CPPFLAGS $i"
+        test "x$silent" != "xyes" && echo "  adding \"$i\" to NOTEST_CPPFLAGS"
+        NOTEST_CPPFLAGS="$NOTEST_CPPFLAGS $i"
       fi
     done
   fi
 
     if test "$GCC" = "yes"; then
 
-  if test "x$CFLAGS" = "x"; then
-    test "x$silent" != "xyes" && echo "  setting CFLAGS to \"-Wall -Wmissing-prototypes -Wstrict-prototypes -Wmissing-declarations -Wpointer-arith -O0\""
-    CFLAGS="-Wall -Wmissing-prototypes -Wstrict-prototypes -Wmissing-declarations -Wpointer-arith -O0"
+
+  if test "$GCC" = "yes"; then
+    { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gcc accepts -O0" >&5
+$as_echo_n "checking whether gcc accepts -O0... " >&6; }
+if ${ac_cv_gcc__O0+:} false; then :
+  $as_echo_n "(cached) " >&6
+else
+
+      save_CFLAGS="$CFLAGS"
+      CFLAGS="$CFLAGS -O0 -Wno-strict-prototypes"
+      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h.  */
+
+int
+main ()
+{
+
+  ;
+  return 0;
+}
+_ACEOF
+if ac_fn_c_try_compile "$LINENO"; then :
+  ac_cv_gcc__O0=yes
+else
+  ac_cv_gcc__O0=no
+fi
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+      CFLAGS="$save_CFLAGS"
+
+fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_gcc__O0" >&5
+$as_echo "$ac_cv_gcc__O0" >&6; }
+    if test "$ac_cv_gcc__O0" = "yes" ; then
+
+  if test "x$NOTEST_CFLAGS" = "x"; then
+    test "x$silent" != "xyes" && echo "  setting NOTEST_CFLAGS to \"-O0\""
+    NOTEST_CFLAGS="-O0"
   else
-    apr_addto_bugger="-Wall -Wmissing-prototypes -Wstrict-prototypes -Wmissing-declarations -Wpointer-arith -O0"
+    apr_addto_bugger="-O0"
     for i in $apr_addto_bugger; do
       apr_addto_duplicate="0"
-      for j in $CFLAGS; do
+      for j in $NOTEST_CFLAGS; do
         if test "x$i" = "x$j"; then
           apr_addto_duplicate="1"
           break
         fi
       done
       if test $apr_addto_duplicate = "0"; then
-        test "x$silent" != "xyes" && echo "  adding \"$i\" to CFLAGS"
-        CFLAGS="$CFLAGS $i"
+        test "x$silent" != "xyes" && echo "  adding \"$i\" to NOTEST_CFLAGS"
+        NOTEST_CFLAGS="$NOTEST_CFLAGS $i"
+      fi
+    done
+  fi
+
+    fi
+  fi
+
+
+
+
+  if test "$GCC" = "yes"; then
+    { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gcc accepts -Wall" >&5
+$as_echo_n "checking whether gcc accepts -Wall... " >&6; }
+if ${ac_cv_gcc__Wall+:} false; then :
+  $as_echo_n "(cached) " >&6
+else
+
+      save_CFLAGS="$CFLAGS"
+      CFLAGS="$CFLAGS -Wall -Wno-strict-prototypes"
+      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h.  */
+
+int
+main ()
+{
+
+  ;
+  return 0;
+}
+_ACEOF
+if ac_fn_c_try_compile "$LINENO"; then :
+  ac_cv_gcc__Wall=yes
+else
+  ac_cv_gcc__Wall=no
+fi
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+      CFLAGS="$save_CFLAGS"
+
+fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_gcc__Wall" >&5
+$as_echo "$ac_cv_gcc__Wall" >&6; }
+    if test "$ac_cv_gcc__Wall" = "yes" ; then
+
+  if test "x$NOTEST_CFLAGS" = "x"; then
+    test "x$silent" != "xyes" && echo "  setting NOTEST_CFLAGS to \"-Wall\""
+    NOTEST_CFLAGS="-Wall"
+  else
+    apr_addto_bugger="-Wall"
+    for i in $apr_addto_bugger; do
+      apr_addto_duplicate="0"
+      for j in $NOTEST_CFLAGS; do
+        if test "x$i" = "x$j"; then
+          apr_addto_duplicate="1"
+          break
+        fi
+      done
+      if test $apr_addto_duplicate = "0"; then
+        test "x$silent" != "xyes" && echo "  adding \"$i\" to NOTEST_CFLAGS"
+        NOTEST_CFLAGS="$NOTEST_CFLAGS $i"
       fi
     done
   fi
 
+    fi
+  fi
+
+
+
+
+  if test "$GCC" = "yes"; then
+    { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gcc accepts -Wstrict-prototypes" >&5
+$as_echo_n "checking whether gcc accepts -Wstrict-prototypes... " >&6; }
+if ${ac_cv_gcc__Wstrict_prototypes+:} false; then :
+  $as_echo_n "(cached) " >&6
+else
+
+      save_CFLAGS="$CFLAGS"
+      CFLAGS="$CFLAGS -Wstrict-prototypes -Wno-strict-prototypes"
+      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h.  */
+
+int
+main ()
+{
+
+  ;
+  return 0;
+}
+_ACEOF
+if ac_fn_c_try_compile "$LINENO"; then :
+  ac_cv_gcc__Wstrict_prototypes=yes
+else
+  ac_cv_gcc__Wstrict_prototypes=no
+fi
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+      CFLAGS="$save_CFLAGS"
+
+fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_gcc__Wstrict_prototypes" >&5
+$as_echo "$ac_cv_gcc__Wstrict_prototypes" >&6; }
+    if test "$ac_cv_gcc__Wstrict_prototypes" = "yes" ; then
+
+  if test "x$NOTEST_CFLAGS" = "x"; then
+    test "x$silent" != "xyes" && echo "  setting NOTEST_CFLAGS to \"-Wstrict-prototypes\""
+    NOTEST_CFLAGS="-Wstrict-prototypes"
+  else
+    apr_addto_bugger="-Wstrict-prototypes"
+    for i in $apr_addto_bugger; do
+      apr_addto_duplicate="0"
+      for j in $NOTEST_CFLAGS; do
+        if test "x$i" = "x$j"; then
+          apr_addto_duplicate="1"
+          break
+        fi
+      done
+      if test $apr_addto_duplicate = "0"; then
+        test "x$silent" != "xyes" && echo "  adding \"$i\" to NOTEST_CFLAGS"
+        NOTEST_CFLAGS="$NOTEST_CFLAGS $i"
+      fi
+    done
+  fi
+
+    fi
+  fi
+
+
+
+
+  if test "$GCC" = "yes"; then
+    { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gcc accepts -Wmissing-prototypes" >&5
+$as_echo_n "checking whether gcc accepts -Wmissing-prototypes... " >&6; }
+if ${ac_cv_gcc__Wmissing_prototypes+:} false; then :
+  $as_echo_n "(cached) " >&6
+else
+
+      save_CFLAGS="$CFLAGS"
+      CFLAGS="$CFLAGS -Wmissing-prototypes -Wno-strict-prototypes"
+      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h.  */
+
+int
+main ()
+{
+
+  ;
+  return 0;
+}
+_ACEOF
+if ac_fn_c_try_compile "$LINENO"; then :
+  ac_cv_gcc__Wmissing_prototypes=yes
+else
+  ac_cv_gcc__Wmissing_prototypes=no
+fi
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+      CFLAGS="$save_CFLAGS"
+
+fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_gcc__Wmissing_prototypes" >&5
+$as_echo "$ac_cv_gcc__Wmissing_prototypes" >&6; }
+    if test "$ac_cv_gcc__Wmissing_prototypes" = "yes" ; then
+
+  if test "x$NOTEST_CFLAGS" = "x"; then
+    test "x$silent" != "xyes" && echo "  setting NOTEST_CFLAGS to \"-Wmissing-prototypes\""
+    NOTEST_CFLAGS="-Wmissing-prototypes"
+  else
+    apr_addto_bugger="-Wmissing-prototypes"
+    for i in $apr_addto_bugger; do
+      apr_addto_duplicate="0"
+      for j in $NOTEST_CFLAGS; do
+        if test "x$i" = "x$j"; then
+          apr_addto_duplicate="1"
+          break
+        fi
+      done
+      if test $apr_addto_duplicate = "0"; then
+        test "x$silent" != "xyes" && echo "  adding \"$i\" to NOTEST_CFLAGS"
+        NOTEST_CFLAGS="$NOTEST_CFLAGS $i"
+      fi
+    done
+  fi
+
+    fi
+  fi
+
+
+
+
+  if test "$GCC" = "yes"; then
+    { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gcc accepts -Wmissing-declarations" >&5
+$as_echo_n "checking whether gcc accepts -Wmissing-declarations... " >&6; }
+if ${ac_cv_gcc__Wmissing_declarations+:} false; then :
+  $as_echo_n "(cached) " >&6
+else
+
+      save_CFLAGS="$CFLAGS"
+      CFLAGS="$CFLAGS -Wmissing-declarations -Wno-strict-prototypes"
+      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h.  */
+
+int
+main ()
+{
+
+  ;
+  return 0;
+}
+_ACEOF
+if ac_fn_c_try_compile "$LINENO"; then :
+  ac_cv_gcc__Wmissing_declarations=yes
+else
+  ac_cv_gcc__Wmissing_declarations=no
+fi
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+      CFLAGS="$save_CFLAGS"
+
+fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_gcc__Wmissing_declarations" >&5
+$as_echo "$ac_cv_gcc__Wmissing_declarations" >&6; }
+    if test "$ac_cv_gcc__Wmissing_declarations" = "yes" ; then
+
+  if test "x$NOTEST_CFLAGS" = "x"; then
+    test "x$silent" != "xyes" && echo "  setting NOTEST_CFLAGS to \"-Wmissing-declarations\""
+    NOTEST_CFLAGS="-Wmissing-declarations"
+  else
+    apr_addto_bugger="-Wmissing-declarations"
+    for i in $apr_addto_bugger; do
+      apr_addto_duplicate="0"
+      for j in $NOTEST_CFLAGS; do
+        if test "x$i" = "x$j"; then
+          apr_addto_duplicate="1"
+          break
+        fi
+      done
+      if test $apr_addto_duplicate = "0"; then
+        test "x$silent" != "xyes" && echo "  adding \"$i\" to NOTEST_CFLAGS"
+        NOTEST_CFLAGS="$NOTEST_CFLAGS $i"
+      fi
+    done
+  fi
+
+    fi
+  fi
+
+
 
 
   if test "$GCC" = "yes"; then
@@ -8439,7 +8989,7 @@ if ${ac_cv_gcc__Wdeclaration_after_statement+:} false; then :
 else
 
       save_CFLAGS="$CFLAGS"
-      CFLAGS="$CFLAGS -Wdeclaration-after-statement"
+      CFLAGS="$CFLAGS -Wdeclaration-after-statement -Wno-strict-prototypes"
       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
 /* end confdefs.h.  */
 
@@ -8464,22 +9014,22 @@ fi
 $as_echo "$ac_cv_gcc__Wdeclaration_after_statement" >&6; }
     if test "$ac_cv_gcc__Wdeclaration_after_statement" = "yes" ; then
 
-  if test "x$CFLAGS" = "x"; then
-    test "x$silent" != "xyes" && echo "  setting CFLAGS to \"-Wdeclaration-after-statement\""
-    CFLAGS="-Wdeclaration-after-statement"
+  if test "x$NOTEST_CFLAGS" = "x"; then
+    test "x$silent" != "xyes" && echo "  setting NOTEST_CFLAGS to \"-Wdeclaration-after-statement\""
+    NOTEST_CFLAGS="-Wdeclaration-after-statement"
   else
     apr_addto_bugger="-Wdeclaration-after-statement"
     for i in $apr_addto_bugger; do
       apr_addto_duplicate="0"
-      for j in $CFLAGS; do
+      for j in $NOTEST_CFLAGS; do
         if test "x$i" = "x$j"; then
           apr_addto_duplicate="1"
           break
         fi
       done
       if test $apr_addto_duplicate = "0"; then
-        test "x$silent" != "xyes" && echo "  adding \"$i\" to CFLAGS"
-        CFLAGS="$CFLAGS $i"
+        test "x$silent" != "xyes" && echo "  adding \"$i\" to NOTEST_CFLAGS"
+        NOTEST_CFLAGS="$NOTEST_CFLAGS $i"
       fi
     done
   fi
@@ -8498,7 +9048,7 @@ if ${ac_cv_gcc__Werror_declaration_after_statement+:} false; then :
 else
 
       save_CFLAGS="$CFLAGS"
-      CFLAGS="$CFLAGS -Werror=declaration-after-statement"
+      CFLAGS="$CFLAGS -Werror=declaration-after-statement -Wno-strict-prototypes"
       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
 /* end confdefs.h.  */
 
@@ -8523,22 +9073,81 @@ fi
 $as_echo "$ac_cv_gcc__Werror_declaration_after_statement" >&6; }
     if test "$ac_cv_gcc__Werror_declaration_after_statement" = "yes" ; then
 
-  if test "x$CFLAGS" = "x"; then
-    test "x$silent" != "xyes" && echo "  setting CFLAGS to \"-Werror=declaration-after-statement\""
-    CFLAGS="-Werror=declaration-after-statement"
+  if test "x$NOTEST_CFLAGS" = "x"; then
+    test "x$silent" != "xyes" && echo "  setting NOTEST_CFLAGS to \"-Werror=declaration-after-statement\""
+    NOTEST_CFLAGS="-Werror=declaration-after-statement"
   else
     apr_addto_bugger="-Werror=declaration-after-statement"
     for i in $apr_addto_bugger; do
       apr_addto_duplicate="0"
-      for j in $CFLAGS; do
+      for j in $NOTEST_CFLAGS; do
         if test "x$i" = "x$j"; then
           apr_addto_duplicate="1"
           break
         fi
       done
       if test $apr_addto_duplicate = "0"; then
-        test "x$silent" != "xyes" && echo "  adding \"$i\" to CFLAGS"
-        CFLAGS="$CFLAGS $i"
+        test "x$silent" != "xyes" && echo "  adding \"$i\" to NOTEST_CFLAGS"
+        NOTEST_CFLAGS="$NOTEST_CFLAGS $i"
+      fi
+    done
+  fi
+
+    fi
+  fi
+
+
+
+
+  if test "$GCC" = "yes"; then
+    { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gcc accepts -Wpointer-arith" >&5
+$as_echo_n "checking whether gcc accepts -Wpointer-arith... " >&6; }
+if ${ac_cv_gcc__Wpointer_arith+:} false; then :
+  $as_echo_n "(cached) " >&6
+else
+
+      save_CFLAGS="$CFLAGS"
+      CFLAGS="$CFLAGS -Wpointer-arith -Wno-strict-prototypes"
+      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h.  */
+
+int
+main ()
+{
+
+  ;
+  return 0;
+}
+_ACEOF
+if ac_fn_c_try_compile "$LINENO"; then :
+  ac_cv_gcc__Wpointer_arith=yes
+else
+  ac_cv_gcc__Wpointer_arith=no
+fi
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+      CFLAGS="$save_CFLAGS"
+
+fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_gcc__Wpointer_arith" >&5
+$as_echo "$ac_cv_gcc__Wpointer_arith" >&6; }
+    if test "$ac_cv_gcc__Wpointer_arith" = "yes" ; then
+
+  if test "x$NOTEST_CFLAGS" = "x"; then
+    test "x$silent" != "xyes" && echo "  setting NOTEST_CFLAGS to \"-Wpointer-arith\""
+    NOTEST_CFLAGS="-Wpointer-arith"
+  else
+    apr_addto_bugger="-Wpointer-arith"
+    for i in $apr_addto_bugger; do
+      apr_addto_duplicate="0"
+      for j in $NOTEST_CFLAGS; do
+        if test "x$i" = "x$j"; then
+          apr_addto_duplicate="1"
+          break
+        fi
+      done
+      if test $apr_addto_duplicate = "0"; then
+        test "x$silent" != "xyes" && echo "  adding \"$i\" to NOTEST_CFLAGS"
+        NOTEST_CFLAGS="$NOTEST_CFLAGS $i"
       fi
     done
   fi
@@ -8557,7 +9166,7 @@ if ${ac_cv_gcc__Wformat+:} false; then :
 else
 
       save_CFLAGS="$CFLAGS"
-      CFLAGS="$CFLAGS -Wformat"
+      CFLAGS="$CFLAGS -Wformat -Wno-strict-prototypes"
       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
 /* end confdefs.h.  */
 
@@ -8582,22 +9191,22 @@ fi
 $as_echo "$ac_cv_gcc__Wformat" >&6; }
     if test "$ac_cv_gcc__Wformat" = "yes" ; then
 
-  if test "x$CFLAGS" = "x"; then
-    test "x$silent" != "xyes" && echo "  setting CFLAGS to \"-Wformat\""
-    CFLAGS="-Wformat"
+  if test "x$NOTEST_CFLAGS" = "x"; then
+    test "x$silent" != "xyes" && echo "  setting NOTEST_CFLAGS to \"-Wformat\""
+    NOTEST_CFLAGS="-Wformat"
   else
     apr_addto_bugger="-Wformat"
     for i in $apr_addto_bugger; do
       apr_addto_duplicate="0"
-      for j in $CFLAGS; do
+      for j in $NOTEST_CFLAGS; do
         if test "x$i" = "x$j"; then
           apr_addto_duplicate="1"
           break
         fi
       done
       if test $apr_addto_duplicate = "0"; then
-        test "x$silent" != "xyes" && echo "  adding \"$i\" to CFLAGS"
-        CFLAGS="$CFLAGS $i"
+        test "x$silent" != "xyes" && echo "  adding \"$i\" to NOTEST_CFLAGS"
+        NOTEST_CFLAGS="$NOTEST_CFLAGS $i"
       fi
     done
   fi
@@ -8616,7 +9225,7 @@ if ${ac_cv_gcc__Wformat_security+:} false; then :
 else
 
       save_CFLAGS="$CFLAGS"
-      CFLAGS="$CFLAGS -Wformat-security"
+      CFLAGS="$CFLAGS -Wformat-security -Wno-strict-prototypes"
       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
 /* end confdefs.h.  */
 
@@ -8641,22 +9250,22 @@ fi
 $as_echo "$ac_cv_gcc__Wformat_security" >&6; }
     if test "$ac_cv_gcc__Wformat_security" = "yes" ; then
 
-  if test "x$CFLAGS" = "x"; then
-    test "x$silent" != "xyes" && echo "  setting CFLAGS to \"-Wformat-security\""
-    CFLAGS="-Wformat-security"
+  if test "x$NOTEST_CFLAGS" = "x"; then
+    test "x$silent" != "xyes" && echo "  setting NOTEST_CFLAGS to \"-Wformat-security\""
+    NOTEST_CFLAGS="-Wformat-security"
   else
     apr_addto_bugger="-Wformat-security"
     for i in $apr_addto_bugger; do
       apr_addto_duplicate="0"
-      for j in $CFLAGS; do
+      for j in $NOTEST_CFLAGS; do
         if test "x$i" = "x$j"; then
           apr_addto_duplicate="1"
           break
         fi
       done
       if test $apr_addto_duplicate = "0"; then
-        test "x$silent" != "xyes" && echo "  adding \"$i\" to CFLAGS"
-        CFLAGS="$CFLAGS $i"
+        test "x$silent" != "xyes" && echo "  adding \"$i\" to NOTEST_CFLAGS"
+        NOTEST_CFLAGS="$NOTEST_CFLAGS $i"
       fi
     done
   fi
@@ -8675,7 +9284,7 @@ if ${ac_cv_gcc__Werror_format_security+:} false; then :
 else
 
       save_CFLAGS="$CFLAGS"
-      CFLAGS="$CFLAGS -Werror=format-security"
+      CFLAGS="$CFLAGS -Werror=format-security -Wno-strict-prototypes"
       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
 /* end confdefs.h.  */
 
@@ -8700,22 +9309,22 @@ fi
 $as_echo "$ac_cv_gcc__Werror_format_security" >&6; }
     if test "$ac_cv_gcc__Werror_format_security" = "yes" ; then
 
-  if test "x$CFLAGS" = "x"; then
-    test "x$silent" != "xyes" && echo "  setting CFLAGS to \"-Werror=format-security\""
-    CFLAGS="-Werror=format-security"
+  if test "x$NOTEST_CFLAGS" = "x"; then
+    test "x$silent" != "xyes" && echo "  setting NOTEST_CFLAGS to \"-Werror=format-security\""
+    NOTEST_CFLAGS="-Werror=format-security"
   else
     apr_addto_bugger="-Werror=format-security"
     for i in $apr_addto_bugger; do
       apr_addto_duplicate="0"
-      for j in $CFLAGS; do
+      for j in $NOTEST_CFLAGS; do
         if test "x$i" = "x$j"; then
           apr_addto_duplicate="1"
           break
         fi
       done
       if test $apr_addto_duplicate = "0"; then
-        test "x$silent" != "xyes" && echo "  adding \"$i\" to CFLAGS"
-        CFLAGS="$CFLAGS $i"
+        test "x$silent" != "xyes" && echo "  adding \"$i\" to NOTEST_CFLAGS"
+        NOTEST_CFLAGS="$NOTEST_CFLAGS $i"
       fi
     done
   fi
@@ -8726,22 +9335,22 @@ $as_echo "$ac_cv_gcc__Werror_format_security" >&6; }
 
     elif test "$AIX_XLC" = "yes"; then
 
-  if test "x$CFLAGS" = "x"; then
-    test "x$silent" != "xyes" && echo "  setting CFLAGS to \"-qfullpath -qinitauto=FE -qcheck=all -qinfo=pro\""
-    CFLAGS="-qfullpath -qinitauto=FE -qcheck=all -qinfo=pro"
+  if test "x$NOTEST_CFLAGS" = "x"; then
+    test "x$silent" != "xyes" && echo "  setting NOTEST_CFLAGS to \"-qfullpath -qinitauto=FE -qcheck=all -qinfo=pro\""
+    NOTEST_CFLAGS="-qfullpath -qinitauto=FE -qcheck=all -qinfo=pro"
   else
     apr_addto_bugger="-qfullpath -qinitauto=FE -qcheck=all -qinfo=pro"
     for i in $apr_addto_bugger; do
       apr_addto_duplicate="0"
-      for j in $CFLAGS; do
+      for j in $NOTEST_CFLAGS; do
         if test "x$i" = "x$j"; then
           apr_addto_duplicate="1"
           break
         fi
       done
       if test $apr_addto_duplicate = "0"; then
-        test "x$silent" != "xyes" && echo "  adding \"$i\" to CFLAGS"
-        CFLAGS="$CFLAGS $i"
+        test "x$silent" != "xyes" && echo "  adding \"$i\" to NOTEST_CFLAGS"
+        NOTEST_CFLAGS="$NOTEST_CFLAGS $i"
       fi
     done
   fi
@@ -29475,10 +30084,14 @@ $as_echo "$ap_nghttp2_base" >&6; }
       saved_PKG_CONFIG_PATH="$PKG_CONFIG_PATH"
       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pkg-config along $PKG_CONFIG_PATH" >&5
 $as_echo_n "checking for pkg-config along $PKG_CONFIG_PATH... " >&6; }
-      if test "x$ap_nghttp2_base" != "x" -a \
-              -f "${ap_nghttp2_base}/lib/pkgconfig/libnghttp2.pc"; then
-                        PKG_CONFIG_PATH="${ap_nghttp2_base}/lib/pkgconfig${PKG_CONFIG_PATH+:}${PKG_CONFIG_PATH}"
-        export PKG_CONFIG_PATH
+      if test "x$ap_nghttp2_base" != "x" ; then
+        if test -f "${ap_nghttp2_base}/lib/pkgconfig/libnghttp2.pc"; then
+                              PKG_CONFIG_PATH="${ap_nghttp2_base}/lib/pkgconfig${PKG_CONFIG_PATH+:}${PKG_CONFIG_PATH}"
+          export PKG_CONFIG_PATH
+        elif test -f "${ap_nghttp2_base}/lib64/pkgconfig/libnghttp2.pc"; then
+                              PKG_CONFIG_PATH="${ap_nghttp2_base}/lib64/pkgconfig${PKG_CONFIG_PATH+:}${PKG_CONFIG_PATH}"
+          export PKG_CONFIG_PATH
+        fi
       fi
       # Check whether --enable-nghttp2-staticlib-deps was given.
 if test "${enable_nghttp2_staticlib_deps+set}" = set; then :
@@ -30229,10 +30842,14 @@ $as_echo "$ap_nghttp2_base" >&6; }
       saved_PKG_CONFIG_PATH="$PKG_CONFIG_PATH"
       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pkg-config along $PKG_CONFIG_PATH" >&5
 $as_echo_n "checking for pkg-config along $PKG_CONFIG_PATH... " >&6; }
-      if test "x$ap_nghttp2_base" != "x" -a \
-              -f "${ap_nghttp2_base}/lib/pkgconfig/libnghttp2.pc"; then
-                        PKG_CONFIG_PATH="${ap_nghttp2_base}/lib/pkgconfig${PKG_CONFIG_PATH+:}${PKG_CONFIG_PATH}"
-        export PKG_CONFIG_PATH
+      if test "x$ap_nghttp2_base" != "x" ; then
+        if test -f "${ap_nghttp2_base}/lib/pkgconfig/libnghttp2.pc"; then
+                              PKG_CONFIG_PATH="${ap_nghttp2_base}/lib/pkgconfig${PKG_CONFIG_PATH+:}${PKG_CONFIG_PATH}"
+          export PKG_CONFIG_PATH
+        elif test -f "${ap_nghttp2_base}/lib64/pkgconfig/libnghttp2.pc"; then
+                              PKG_CONFIG_PATH="${ap_nghttp2_base}/lib64/pkgconfig${PKG_CONFIG_PATH+:}${PKG_CONFIG_PATH}"
+          export PKG_CONFIG_PATH
+        fi
       fi
       # Check whether --enable-nghttp2-staticlib-deps was given.
 if test "${enable_nghttp2_staticlib_deps+set}" = set; then :
@@ -31760,10 +32377,10 @@ DISTCLEAN_TARGETS = modules.mk
 static =
 shared = $libname
 EOF
-            DSO_MODULES="$DSO_MODULES mpm_event"
+            MPM_MODULES="$MPM_MODULES mpm_event"
             # add default MPM to LoadModule list
             if test event = $default_mpm; then
-                ENABLED_DSO_MODULES="${ENABLED_DSO_MODULES},mpm_event"
+                ENABLED_MPM_MODULE="mpm_event"
             fi
         fi
 
@@ -31843,10 +32460,10 @@ DISTCLEAN_TARGETS = modules.mk
 static =
 shared = $libname
 EOF
-            DSO_MODULES="$DSO_MODULES mpm_prefork"
+            MPM_MODULES="$MPM_MODULES mpm_prefork"
             # add default MPM to LoadModule list
             if test prefork = $default_mpm; then
-                ENABLED_DSO_MODULES="${ENABLED_DSO_MODULES},mpm_prefork"
+                ENABLED_MPM_MODULE="mpm_prefork"
             fi
         fi
 
@@ -31915,10 +32532,10 @@ DISTCLEAN_TARGETS = modules.mk
 static =
 shared = $libname
 EOF
-            DSO_MODULES="$DSO_MODULES mpm_winnt"
+            MPM_MODULES="$MPM_MODULES mpm_winnt"
             # add default MPM to LoadModule list
             if test winnt = $default_mpm; then
-                ENABLED_DSO_MODULES="${ENABLED_DSO_MODULES},mpm_winnt"
+                ENABLED_MPM_MODULE="mpm_winnt"
             fi
         fi
 
@@ -31987,10 +32604,10 @@ DISTCLEAN_TARGETS = modules.mk
 static =
 shared = $libname
 EOF
-            DSO_MODULES="$DSO_MODULES mpm_worker"
+            MPM_MODULES="$MPM_MODULES mpm_worker"
             # add default MPM to LoadModule list
             if test worker = $default_mpm; then
-                ENABLED_DSO_MODULES="${ENABLED_DSO_MODULES},mpm_worker"
+                ENABLED_MPM_MODULE="mpm_worker"
             fi
         fi
 
@@ -34410,10 +35027,10 @@ DISTCLEAN_TARGETS = modules.mk
 static =
 shared = $libname
 EOF
-            DSO_MODULES="$DSO_MODULES mpm_mpmt_os2"
+            MPM_MODULES="$MPM_MODULES mpm_mpmt_os2"
             # add default MPM to LoadModule list
             if test mpmt_os2 = $default_mpm; then
-                ENABLED_DSO_MODULES="${ENABLED_DSO_MODULES},mpm_mpmt_os2"
+                ENABLED_MPM_MODULE="mpm_mpmt_os2"
             fi
         fi
 
@@ -36647,10 +37264,10 @@ $as_echo "$as_me: Restore user-defined environment settings..." >&6;}
 $as_echo "$as_me: " >&6;}
 
 APACHE_CONF_SEL_CC=${CC}
-APACHE_CONF_SEL_CFLAGS=${CFLAGS}
-APACHE_CONF_SEL_LDFLAGS=${LDFLAGS}
-APACHE_CONF_SEL_LIBS=${LIBS}
-APACHE_CONF_SEL_CPPFLAGS=${CPPFLAGS}
+APACHE_CONF_SEL_CFLAGS="${CFLAGS} ${EXTRA_CFLAGS} ${NOTEST_CFLAGS}"
+APACHE_CONF_SEL_CPPFLAGS="${CPPFLAGS} ${EXTRA_CPPFLAGS} ${NOTEST_CPPFLAGS}"
+APACHE_CONF_SEL_LDFLAGS="${LDFLAGS} ${EXTRA_LDFLAGS} ${NOTEST_LDFLAGS}"
+APACHE_CONF_SEL_LIBS="${LIBS} ${EXTRA_LIBS} ${NOTEST_LIBS}"
 APACHE_CONF_SEL_CPP=${CPP}
 
 
@@ -37045,6 +37662,14 @@ $as_echo "$as_me: " >&6;}
 
 
 
+  APACHE_VAR_SUBST="$APACHE_VAR_SUBST MPM_MODULES"
+
+
+
+  APACHE_VAR_SUBST="$APACHE_VAR_SUBST ENABLED_MPM_MODULE"
+
+
+
   APACHE_VAR_SUBST="$APACHE_VAR_SUBST DSO_MODULES"
 
 
@@ -38483,9 +39108,9 @@ fi
     Install prefix: ${prefix}
     C compiler:     ${APACHE_CONF_SEL_CC}
     CFLAGS:         ${APACHE_CONF_SEL_CFLAGS}
+    CPPFLAGS:       ${APACHE_CONF_SEL_CPPFLAGS}
     LDFLAGS:        ${APACHE_CONF_SEL_LDFLAGS}
     LIBS:           ${APACHE_CONF_SEL_LIBS}
-    CPPFLAGS:       ${APACHE_CONF_SEL_CPPFLAGS}
     C preprocessor: ${APACHE_CONF_SEL_CPP}
 " >&5
 $as_echo "$as_me: summary of build options:
@@ -38494,8 +39119,8 @@ $as_echo "$as_me: summary of build options:
     Install prefix: ${prefix}
     C compiler:     ${APACHE_CONF_SEL_CC}
     CFLAGS:         ${APACHE_CONF_SEL_CFLAGS}
+    CPPFLAGS:       ${APACHE_CONF_SEL_CPPFLAGS}
     LDFLAGS:        ${APACHE_CONF_SEL_LDFLAGS}
     LIBS:           ${APACHE_CONF_SEL_LIBS}
-    CPPFLAGS:       ${APACHE_CONF_SEL_CPPFLAGS}
     C preprocessor: ${APACHE_CONF_SEL_CPP}
 " >&6;}
diff --git a/configure.in b/configure.in
index 7ae20b8..761e836 100644
--- a/configure.in
+++ b/configure.in
@@ -593,17 +593,21 @@ AC_ARG_ENABLE(load-all-modules,APACHE_HELP_STRING(--enable-load-all-modules,Load
 AC_ARG_ENABLE(maintainer-mode,APACHE_HELP_STRING(--enable-maintainer-mode,Turn on debugging and compile time warnings and load all compiled modules),
 [
   if test "$enableval" = "yes"; then
-    APR_ADDTO(CPPFLAGS, -DAP_DEBUG)
+    APR_ADDTO(NOTEST_CPPFLAGS, -DAP_DEBUG)
     if test "$GCC" = "yes"; then
-      APR_ADDTO(CFLAGS,[-Wall -Wmissing-prototypes -Wstrict-prototypes -Wmissing-declarations -Wpointer-arith])
       APACHE_ADD_GCC_CFLAG([-std=c89])
       APACHE_ADD_GCC_CFLAG([-Werror])
+      APACHE_ADD_GCC_CFLAG([-Wall])
+      APACHE_ADD_GCC_CFLAG([-Wstrict-prototypes])
+      APACHE_ADD_GCC_CFLAG([-Wmissing-prototypes])
+      APACHE_ADD_GCC_CFLAG([-Wmissing-declarations])
       APACHE_ADD_GCC_CFLAG([-Wdeclaration-after-statement])
+      APACHE_ADD_GCC_CFLAG([-Wpointer-arith])
       APACHE_ADD_GCC_CFLAG([-Wformat])
       APACHE_ADD_GCC_CFLAG([-Wformat-security])
       APACHE_ADD_GCC_CFLAG([-Wunused])
     elif test "$AIX_XLC" = "yes"; then
-      APR_ADDTO(CFLAGS,-qfullpath -qinitauto=FE -qcheck=all -qinfo=pro)
+      APR_ADDTO(NOTEST_CFLAGS,-qfullpath -qinitauto=FE -qcheck=all -qinfo=pro)
     fi
     if test "x$enable_load_all_modules" = "x"; then
       LOAD_ALL_MODULES=yes
@@ -619,16 +623,21 @@ AC_ARG_ENABLE(maintainer-mode,APACHE_HELP_STRING(--enable-maintainer-mode,Turn o
 AC_ARG_ENABLE(debugger-mode,APACHE_HELP_STRING(--enable-debugger-mode,Turn on debugging and compile time warnings and turn off optimization),
 [
   if test "$enableval" = "yes"; then
-    APR_ADDTO(CPPFLAGS, -DAP_DEBUG)
+    APR_ADDTO(NOTEST_CPPFLAGS, -DAP_DEBUG)
     if test "$GCC" = "yes"; then
-      APR_ADDTO(CFLAGS,[-Wall -Wmissing-prototypes -Wstrict-prototypes -Wmissing-declarations -Wpointer-arith -O0])
+      APACHE_ADD_GCC_CFLAG([-O0])
+      APACHE_ADD_GCC_CFLAG([-Wall])
+      APACHE_ADD_GCC_CFLAG([-Wstrict-prototypes])
+      APACHE_ADD_GCC_CFLAG([-Wmissing-prototypes])
+      APACHE_ADD_GCC_CFLAG([-Wmissing-declarations])
       APACHE_ADD_GCC_CFLAG([-Wdeclaration-after-statement])
       APACHE_ADD_GCC_CFLAG([-Werror=declaration-after-statement])
+      APACHE_ADD_GCC_CFLAG([-Wpointer-arith])
       APACHE_ADD_GCC_CFLAG([-Wformat])
       APACHE_ADD_GCC_CFLAG([-Wformat-security])
       APACHE_ADD_GCC_CFLAG([-Werror=format-security])
     elif test "$AIX_XLC" = "yes"; then
-      APR_ADDTO(CFLAGS,-qfullpath -qinitauto=FE -qcheck=all -qinfo=pro)
+      APR_ADDTO(NOTEST_CFLAGS,-qfullpath -qinitauto=FE -qcheck=all -qinfo=pro)
     fi
   fi
 ])dnl
@@ -810,10 +819,10 @@ AC_MSG_NOTICE([Restore user-defined environment settings...])
 AC_MSG_NOTICE([])
 
 APACHE_CONF_SEL_CC=${CC}
-APACHE_CONF_SEL_CFLAGS=${CFLAGS}
-APACHE_CONF_SEL_LDFLAGS=${LDFLAGS}
-APACHE_CONF_SEL_LIBS=${LIBS}
-APACHE_CONF_SEL_CPPFLAGS=${CPPFLAGS}
+APACHE_CONF_SEL_CFLAGS="${CFLAGS} ${EXTRA_CFLAGS} ${NOTEST_CFLAGS}"
+APACHE_CONF_SEL_CPPFLAGS="${CPPFLAGS} ${EXTRA_CPPFLAGS} ${NOTEST_CPPFLAGS}"
+APACHE_CONF_SEL_LDFLAGS="${LDFLAGS} ${EXTRA_LDFLAGS} ${NOTEST_LDFLAGS}"
+APACHE_CONF_SEL_LIBS="${LIBS} ${EXTRA_LIBS} ${NOTEST_LIBS}"
 APACHE_CONF_SEL_CPP=${CPP}
 
 APR_RESTORE_THE_ENVIRONMENT(CPPFLAGS, EXTRA_)
@@ -879,8 +888,8 @@ AC_MSG_NOTICE([summary of build options:
     Install prefix: ${prefix}
     C compiler:     ${APACHE_CONF_SEL_CC}
     CFLAGS:         ${APACHE_CONF_SEL_CFLAGS}
+    CPPFLAGS:       ${APACHE_CONF_SEL_CPPFLAGS}
     LDFLAGS:        ${APACHE_CONF_SEL_LDFLAGS}
     LIBS:           ${APACHE_CONF_SEL_LIBS}
-    CPPFLAGS:       ${APACHE_CONF_SEL_CPPFLAGS}
     C preprocessor: ${APACHE_CONF_SEL_CPP}
 ])
diff --git a/docs/conf/mime.types b/docs/conf/mime.types
index 4980200..7508c26 100644
--- a/docs/conf/mime.types
+++ b/docs/conf/mime.types
@@ -112,9 +112,7 @@ application/exi					exi
 # application/fastsoap
 # application/fdt+xml
 # application/fits
-# application/font-sfnt
 application/font-tdpfr				pfr
-application/font-woff				woff
 # application/framework-attributes+xml
 # application/geo+json
 application/gml+xml				gml
@@ -1261,12 +1259,10 @@ application/x-font-bdf				bdf
 application/x-font-ghostscript			gsf
 # application/x-font-libgrx
 application/x-font-linux-psf			psf
-application/x-font-otf				otf
 application/x-font-pcf				pcf
 application/x-font-snf				snf
 # application/x-font-speedo
 # application/x-font-sunos-news
-application/x-font-ttf				ttf ttc
 application/x-font-type1			pfa pfb pfm afm
 # application/x-font-vfont
 application/x-freearc				arc
@@ -1534,6 +1530,12 @@ chemical/x-cml					cml
 chemical/x-csml					csml
 # chemical/x-pdb
 chemical/x-xyz					xyz
+font/collection					ttc
+font/otf					otf
+# font/sfnt
+font/ttf					ttf
+font/woff					woff
+font/woff2					woff2
 image/bmp					bmp
 image/cgm					cgm
 # image/dicom-rle
diff --git a/docs/manual/caching.html.fr b/docs/manual/caching.html.fr
index f406983..f1ec1da 100644
--- a/docs/manual/caching.html.fr
+++ b/docs/manual/caching.html.fr
@@ -470,7 +470,7 @@ Vary: negotiate,accept-language,accept-charset
       
 
       <p>Le module <code class="module"><a href="./mod/mod_cache.html">mod_cache</a></code> s'appuie sur des
-      impl�mentations de stockage en arri�re-plan sp�cifiques pour g�rer
+      impl�mentations de stockage sous-jacentes sp�cifiques pour g�rer
       le cache ; � ce titre, <code class="module"><a href="./mod/mod_cache_disk.html">mod_cache_disk</a></code> fournit le
       support de la mise en cache sur disque.</p>
 
@@ -663,7 +663,7 @@ CacheSocache dbm:/path/to/datafile</pre>
 
       <p>Le module <code class="module"><a href="./mod/mod_authn_socache.html">mod_authn_socache</a></code> permet la mise en
       cache des donn�es issues d'une authentification, diminuant ainsi
-      la charge des serveurs d'authentification en arri�re-plan.</p>
+      la charge des serveurs d'authentification d'arri�re-plan.</p>
 
     
 
diff --git a/docs/manual/howto/access.html.en b/docs/manual/howto/access.html.en
index cf1193a..ec548ed 100644
--- a/docs/manual/howto/access.html.en
+++ b/docs/manual/howto/access.html.en
@@ -164,7 +164,7 @@ Require not host gov</pre>
     on arbitrary criteria.</p>
 
     <p>For example, if you wish to block access to a resource between 8pm
-    and 6am, you can do this using <code class="module"><a href="../mod/mod_rewrite.html">mod_rewrite</a></code>.</p>
+    and 7am, you can do this using <code class="module"><a href="../mod/mod_rewrite.html">mod_rewrite</a></code>.</p>
 
     <pre class="prettyprint lang-config">RewriteEngine On
 RewriteCond "%{TIME_HOUR}" ">=20" [OR]
diff --git a/docs/manual/howto/access.html.es b/docs/manual/howto/access.html.es
index 7170bb8..99f54d9 100644
--- a/docs/manual/howto/access.html.es
+++ b/docs/manual/howto/access.html.es
@@ -27,6 +27,10 @@
 <a href="../es/howto/access.html" title="Espa�ol"> es </a> |
 <a href="../fr/howto/access.html" hreflang="fr" rel="alternate" title="Fran�ais"> fr </a></p>
 </div>
+<div class="outofdate">Esta traducci�n podr�a estar
+            obsoleta. Consulte la versi�n en ingl�s de la
+            documentaci�n para comprobar si se han producido cambios
+            recientemente.</div>
 
     <p>El control de acceso, hace referencia a todos los medios que proporcionan
     	una forma de controlar el acceso a cualquier recurso. Esta parte est�
diff --git a/docs/manual/howto/access.html.fr b/docs/manual/howto/access.html.fr
index 6216fed..2e07089 100644
--- a/docs/manual/howto/access.html.fr
+++ b/docs/manual/howto/access.html.fr
@@ -175,7 +175,7 @@ d'acc
     l'acc�s � une ressource en fonction d'un crit�re arbitraire.</p>
 
     <p>Par exemple, pour bloquer l'acc�s � une ressources entre 20h et
-    6h du matin, vous pouvez utiliser <code class="module"><a href="../mod/mod_rewrite.html">mod_rewrite</a></code> :</p>
+    7h du matin, vous pouvez utiliser <code class="module"><a href="../mod/mod_rewrite.html">mod_rewrite</a></code> :</p>
 
     <pre class="prettyprint lang-config">RewriteEngine On
 RewriteCond "%{TIME_HOUR}" ">=20" [OR]
diff --git a/docs/manual/images/feather.png b/docs/manual/images/feather.png
index 59d6091..1d45037 100644
Binary files a/docs/manual/images/feather.png and b/docs/manual/images/feather.png differ
diff --git a/docs/manual/index.html.en b/docs/manual/index.html.en
index 693108a..e42821d 100644
--- a/docs/manual/index.html.en
+++ b/docs/manual/index.html.en
@@ -56,6 +56,7 @@ Documentation</h1>
 <li><a href="filter.html">Filters</a></li>
 <li><a href="handler.html">Handlers</a></li>
 <li><a href="expr.html">Expression parser</a></li>
+<li><a href="mod/overrides.html">Override Class Index for .htaccess</a></li>
 <li><a href="programs/">Server and Supporting Programs</a></li>
 <li><a href="glossary.html">Glossary</a></li>
 </ul>
diff --git a/docs/manual/index.html.es b/docs/manual/index.html.es
index 1c5106c..679b5d2 100644
--- a/docs/manual/index.html.es
+++ b/docs/manual/index.html.es
@@ -36,6 +36,10 @@
 <a href="./tr/" hreflang="tr" rel="alternate" title="T�rk�e"> tr </a> |
 <a href="./zh-cn/" hreflang="zh-cn" rel="alternate" title="Simplified Chinese"> zh-cn </a></p>
 </div>
+<div class="outofdate">Esta traducci�n podr�a estar
+            obsoleta. Consulte la versi�n en ingl�s de la
+            documentaci�n para comprobar si se han producido cambios
+            recientemente.</div>
 <form method="get" action="http://www.google.com/search"><p><input name="as_q" value="" type="text" /> <input value="Buscar en Google" type="submit" /><input value="10" name="num" type="hidden" /><input value="es" name="hl" type="hidden" /><input value="ISO-8859-1" name="ie" type="hidden" /><input value="Google Search" name="btnG" type="hidden" /><input name="as_epq" value="Versi�n 2.4" type="hidden" /><input name="as_oq" value="" type="hidden" /><input name="as_eq" value=""List-Pos [...]
 <table id="indextable"><tr><td class="col1"><div class="category"><h2><a name="release" id="release">Notas de la Versi�n</a></h2>
 <ul><li><a href="new_features_2_4.html">Nuevas funcionalidades en Apache 2.3/2.4</a></li>
diff --git a/docs/manual/index.html.fr b/docs/manual/index.html.fr
index bcd3886..0907780 100644
--- a/docs/manual/index.html.fr
+++ b/docs/manual/index.html.fr
@@ -56,6 +56,8 @@
 <li><a href="filter.html">Filtres</a></li>
 <li><a href="handler.html">Gestionnaires</a></li>
 <li><a href="expr.html">Interpr�teur d'expressions</a></li>
+<li><a href="mod/overrides.html">Index des directives disponibles dans les
+    fichiers .htaccess</a></li>
 <li><a href="programs/">Le serveur et ses utilitaires</a></li>
 <li><a href="glossary.html">Glossaire</a></li>
 </ul>
diff --git a/docs/manual/index.html.tr.utf8 b/docs/manual/index.html.tr.utf8
index 7b17e67..cdfdf15 100644
--- a/docs/manual/index.html.tr.utf8
+++ b/docs/manual/index.html.tr.utf8
@@ -38,6 +38,7 @@ Belgeleri</h1>
 <a href="./tr/" title="Türkçe"> tr </a> |
 <a href="./zh-cn/" hreflang="zh-cn" rel="alternate" title="Simplified Chinese"> zh-cn </a></p>
 </div>
+<div class="outofdate">Bu çeviri güncel olmayabilir. Son değişiklikler için İngilizce sürüm geçerlidir.</div>
 <form method="get" action="http://www.google.com/search"><p><input name="as_q" value="" type="text" /> <input value="Google’de Ara" type="submit" /><input value="10" name="num" type="hidden" /><input value="tr" name="hl" type="hidden" /><input value="UTF-8" name="ie" type="hidden" /><input value="Google Search" name="btnG" type="hidden" /><input name="as_epq" value="Sürüm 2.4" type="hidden" /><input name="as_oq" value="" type="hidden" /><input name="as_eq" value=""List-Post"" t [...]
 <table id="indextable"><tr><td class="col1"><div class="category"><h2><a name="release" id="release">Sürümlerin Dağıtım Bilgileri</a></h2>
 <ul><li><a href="new_features_2_4.html">2.3/2.4’deki yeni özellikler</a></li>
diff --git a/docs/manual/mod/core.html.en b/docs/manual/mod/core.html.en
index 440ebfb..90c2b40 100644
--- a/docs/manual/mod/core.html.en
+++ b/docs/manual/mod/core.html.en
@@ -445,10 +445,12 @@ NoDecode option available in 2.3.12 and later.</td></tr>
     <code>.htaccess</code> files.</p>
 
     <p>The <var>directive-type</var> can be one of the following
-    groupings of directives.</p>
+    groupings of directives. (See the <a href="overrides.html">override class
+    index</a> for an up-to-date listing of which directives are enabled by each
+    <var>directive-type</var>.)</p>
 
     <dl>
-      <dt>AuthConfig</dt>
+      <dt><a href="overrides.html#override-authconfig">AuthConfig</a></dt>
 
       <dd>
 
@@ -458,7 +460,7 @@ NoDecode option available in 2.3.12 and later.</td></tr>
       <code class="directive"><a href="../mod/mod_authn_core.html#authname">AuthName</a></code>,
       <code class="directive"><a href="../mod/mod_authn_core.html#authtype">AuthType</a></code>, <code class="directive"><a href="../mod/mod_authn_file.html#authuserfile">AuthUserFile</a></code>, <code class="directive"><a href="../mod/mod_authz_core.html#require">Require</a></code>, <em>etc.</em>).</dd>
 
-      <dt>FileInfo</dt>
+      <dt><a href="overrides.html#override-fileinfo">FileInfo</a></dt>
 
       <dd>
       Allow use of the directives controlling document types
@@ -476,7 +478,7 @@ NoDecode option available in 2.3.12 and later.</td></tr>
       <code class="module"><a href="../mod/mod_actions.html">mod_actions</a></code>.
       </dd>
 
-      <dt>Indexes</dt>
+      <dt><a href="overrides.html#override-indexes">Indexes</a></dt>
 
       <dd>
       Allow use of the directives controlling directory indexing
@@ -486,7 +488,7 @@ NoDecode option available in 2.3.12 and later.</td></tr>
       <code class="directive"><a href="../mod/mod_autoindex.html#defaulticon">DefaultIcon</a></code>, <code class="directive"><a href="../mod/mod_dir.html#directoryindex">DirectoryIndex</a></code>, <a href="mod_autoindex.html#indexoptions.fancyindexing"><code>FancyIndexing</code></a>, <code class="directive"><a href="../mod/mod_autoindex.html#headername">HeaderName</a></code>, <code class="directive"><a href="../mod/mod_autoindex.html#indexignore">IndexIgnore</a></code>, <code class="dir [...]
       <em>etc.</em>).</dd>
 
-      <dt>Limit</dt>
+      <dt><a href="overrides.html#override-limit">Limit</a></dt>
 
       <dd>
       Allow use of the directives controlling host access (<code class="directive"><a href="../mod/mod_access_compat.html#allow">Allow</a></code>, <code class="directive"><a href="../mod/mod_access_compat.html#deny">Deny</a></code> and <code class="directive"><a href="../mod/mod_access_compat.html#order">Order</a></code>).</dd>
@@ -515,7 +517,7 @@ NoDecode option available in 2.3.12 and later.</td></tr>
       </div>
       </dd>
 
-      <dt>Options[=<var>Option</var>,...]</dt>
+      <dt><a href="overrides.html#override-options">Options</a>[=<var>Option</var>,...]</dt>
 
       <dd>
       Allow use of the directives controlling specific directory
@@ -561,6 +563,7 @@ NoDecode option available in 2.3.12 and later.</td></tr>
 <li><code class="directive"><a href="#allowoverridelist">AllowOverrideList</a></code></li>
 <li><a href="../configuring.html">Configuration Files</a></li>
 <li><a href="../howto/htaccess.html">.htaccess Files</a></li>
+<li><a href="overrides.html">Override Class Index for .htaccess</a></li>
 </ul>
 </div>
 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
@@ -1437,7 +1440,7 @@ ErrorDocument 403 /errors/forbidden.py?referrer=%{escape:%{HTTP_REFERER}}</pre>
 <div class="directive-section"><h2><a name="ErrorLog" id="ErrorLog">ErrorLog</a> <a name="errorlog" id="errorlog">Directive</a></h2>
 <table class="directive">
 <tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Location where the server will log errors</td></tr>
-<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code> ErrorLog <var>file-path</var>|syslog[:<var>facility</var>]</code></td></tr>
+<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code> ErrorLog <var>file-path</var>|syslog[:[<var>facility</var>][:<var>tag</var>]]</code></td></tr>
 <tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>ErrorLog logs/error_log (Unix) ErrorLog logs/error.log (Windows and OS/2)</code></td></tr>
 <tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config, virtual host</td></tr>
 <tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Core</td></tr>
@@ -1468,9 +1471,14 @@ ErrorDocument 403 /errors/forbidden.py?referrer=%{escape:%{HTTP_REFERER}}</pre>
     <var>facility</var> can be one of the names usually documented in
     syslog(1).  The facility is effectively global, and if it is changed
     in individual virtual hosts, the final facility specified affects the
-    entire server.</p>
-
-    <pre class="prettyprint lang-config">ErrorLog syslog:user</pre>
+    entire server. Same rules apply for the syslog tag, which by default
+    uses the Apache binary name, <code>httpd</code> in most cases. You can
+    also override this by using the <code>syslog::<var>tag</var></code>
+    syntax.</p>
+
+    <pre class="prettyprint lang-config">ErrorLog syslog:user
+ErrorLog syslog:user:httpd.srv1
+ErrorLog syslog::httpd.srv2</pre>
 
 
     <p>Additional modules can provide their own ErrorLog providers. The syntax
diff --git a/docs/manual/mod/core.html.fr b/docs/manual/mod/core.html.fr
index f9cc8fd..faba8dd 100644
--- a/docs/manual/mod/core.html.fr
+++ b/docs/manual/mod/core.html.fr
@@ -465,10 +465,12 @@ All pour les versions ant
     autoris�e dans les fichiers <code>.htaccess</code>.</p>
 
     <p>L'argument <var>type directive</var> peut contenir les
-    groupements de directives suivants :</p>
+    groupements de directives suivants (voir <a href="overrides.html">ce
+    document</a> pour obtenir la liste � jour des directives activ�es pour
+    chaque type de directive) :</p>
 
     <dl>
-      <dt>AuthConfig</dt>
+      <dt><a href="overrides.html#override-authconfig">AuthConfig</a></dt>
 
       <dd>
 
@@ -478,7 +480,7 @@ All pour les versions ant
       <code class="directive"><a href="../mod/mod_authn_core.html#authname">AuthName</a></code>,
       <code class="directive"><a href="../mod/mod_authn_core.html#authtype">AuthType</a></code>, <code class="directive"><a href="../mod/mod_authn_file.html#authuserfile">AuthUserFile</a></code>, <code class="directive"><a href="../mod/mod_authz_core.html#require">Require</a></code>, <em>etc...</em>).</dd>
 
-      <dt>FileInfo</dt>
+      <dt><a href="overrides.html#override-fileinfo">FileInfo</a></dt>
 
       <dd>
       Permet l'utilisation des directives qui contr�lent les types de
@@ -492,7 +494,7 @@ All pour les versions ant
       <code class="module"><a href="../mod/mod_actions.html">mod_actions</a></code>.
       </dd>
 
-      <dt>Indexes</dt>
+      <dt><a href="overrides.html#override-indexes">Indexes</a></dt>
 
       <dd>
       Permet l'utilisation des directives qui contr�lent l'indexation
@@ -503,7 +505,7 @@ All pour les versions ant
       <code class="directive"><a href="../mod/mod_autoindex.html#headername">HeaderName</a></code>, <code class="directive"><a href="../mod/mod_autoindex.html#indexignore">IndexIgnore</a></code>, <code class="directive"><a href="../mod/mod_autoindex.html#indexoptions">IndexOptions</a></code>, <code class="directive"><a href="../mod/mod_autoindex.html#readmename">ReadmeName</a></code>,
       <em>etc...</em>).</dd>
 
-      <dt>Limit</dt>
+      <dt><a href="overrides.html#override-limit">Limit</a></dt>
 
       <dd>
       Permet l'utilisation des directives contr�lant l'acc�s au serveur
@@ -537,7 +539,7 @@ All pour les versions ant
       </div>
       </dd>
 
-      <dt>Options[=<var>Option</var>,...]</dt>
+      <dt><a href="overrides.html#override-options">Options</a>[=<var>Option</var>,...]</dt>
 
       <dd>
       Permet l'utilisation des directives contr�lant les fonctionnalit�s
@@ -588,6 +590,7 @@ All pour les versions ant
 <li><code class="directive"><a href="#allowoverridelist">AllowOverrideList</a></code></li>
 <li><a href="../configuring.html">Fichiers de configuration</a></li>
 <li><a href="../howto/htaccess.html">Fichiers .htaccess</a></li>
+<li><a href="overrides.html">Override Class Index for .htaccess</a></li>
 </ul>
 </div>
 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
@@ -1520,7 +1523,7 @@ personnalisation des r
 <div class="directive-section"><h2><a name="errorlog" id="errorlog">Directive</a> <a name="ErrorLog" id="ErrorLog">ErrorLog</a></h2>
 <table class="directive">
 <tr><th><a href="directive-dict.html#Description">Description:</a></th><td>D�finition du chemin du journal des erreurs</td></tr>
-<tr><th><a href="directive-dict.html#Syntax">Syntaxe:</a></th><td><code> ErrorLog <var>chemin fichier</var>|syslog[:<var>facility</var>]</code></td></tr>
+<tr><th><a href="directive-dict.html#Syntax">Syntaxe:</a></th><td><code> ErrorLog <var>file-path</var>|syslog[:[<var>facility</var>][:<var>tag</var>]]</code></td></tr>
 <tr><th><a href="directive-dict.html#Default">D�faut:</a></th><td><code>ErrorLog logs/error_log (Unix) ErrorLog logs/error.log (Windows and OS/2)</code></td></tr>
 <tr><th><a href="directive-dict.html#Context">Contexte:</a></th><td>configuration du serveur, serveur virtuel</td></tr>
 <tr><th><a href="directive-dict.html#Status">Statut:</a></th><td>Core</td></tr>
@@ -1528,14 +1531,14 @@ personnalisation des r
 </table>
     <p>La directive <code class="directive">ErrorLog</code> permet de d�finir le
     nom du fichier dans lequel le serveur va journaliser toutes les
-    erreurs qu'il rencontre. Si le <var>chemin fichier</var> n'est pas
+    erreurs qu'il rencontre. Si le <var>file-path</var> n'est pas
     absolu, il est consid�r� comme relatif au chemin d�fini par la
     directive <code class="directive"><a href="#serverroot">ServerRoot</a></code>.</p>
 
     <pre class="prettyprint lang-config">ErrorLog "/var/log/httpd/error_log"</pre>
 
 
-    <p>Si le <var>chemin fichier</var> commence par une barre verticale
+    <p>Si le <var>file-path</var> commence par une barre verticale
     "<code>(|)</code>", il est consid�r� comme une commande � lancer pour traiter la
     journalisation de l'erreur.</p>
 
@@ -1553,9 +1556,14 @@ personnalisation des r
     �tre remplac� par un des noms habituellement document�s dans la page
     de man syslog(1). Le dispositif syslog <code>local7</code> est
     global, et si il est modifi� dans un serveur virtuel, le dispositif
-    final sp�cifi� affecte l'ensemble du serveur</p>
-
-    <pre class="prettyprint lang-config">ErrorLog syslog:user</pre>
+    final sp�cifi� affecte l'ensemble du serveur. La m�me r�gle s'applique au
+    tag syslog qui utilise par d�faut le nom du binaire du serveur HTTP Apache
+    <code>httpd</code> dans la plupart des cas. Vous pouvez aussi modifier cette
+    valeur en utilisant la syntaxe <code>syslog::<var>tag</var></code>.</p>
+
+    <pre class="prettyprint lang-config">ErrorLog syslog:user
+ErrorLog syslog:user:httpd.srv1
+ErrorLog syslog::httpd.srv2</pre>
 
 
     <p>Des modules suppl�mentaires peuvent fournir leurs propres
diff --git a/docs/manual/mod/core.html.tr.utf8 b/docs/manual/mod/core.html.tr.utf8
index 942c094..a0c621a 100644
--- a/docs/manual/mod/core.html.tr.utf8
+++ b/docs/manual/mod/core.html.tr.utf8
@@ -877,13 +877,11 @@ DocumentRoot "/var/www/${servername}/htdocs"</pre>
     <p><code class="directive"><a href="../mod/mod_rewrite.html#rewritemap">RewriteMap</a></code> sözdizimi ile
       karışmalardan kaçınmak için değişken isimleri ikinokta ":" karakterleri
       içeremez.</p>
-    
-    <p>Bu yönerge sanal konakta ve dizin içeriğinde desteklenirken yapılan 
+    <div class="note"><h3>Sanal konak bağlamı ve tuzaklar</h3>
+      <p>Bu yönerge sanal konakta ve dizin içeriğinde desteklendiğinden yapılan 
       değişiklikler (eşleşsin eşleşmesin) yönergeyi sarmalayan yapılandırma 
-      bölümünün ötesinde, sonraki yapılandırma yönergelerine de görünür olur. Diğer 
-      yapılandırma bölümleri için sağlanan bu desteğe bu yönergenin ilk 
-      gerçekleniminde hatalı olarak izin verilmişti. Geriye uyumluluk amacıyla 
-      (önceden sezilmeyen sonuçlarıyla) bu durum muhafaza edilmiştir.</p>
+      bölümünden başka, sonraki yapılandırma yönergelerine de görünür olur.</p>
+    </div>
 
 <h3>Ayrıca bakınız:</h3>
 <ul>
@@ -1120,6 +1118,7 @@ DocumentRoot "/var/www/${servername}/htdocs"</pre>
 <tr><th><a href="directive-dict.html#Override">Geçersizleştirme:</a></th><td>All</td></tr>
 <tr><th><a href="directive-dict.html#Status">Durum:</a></th><td>Çekirdek</td></tr>
 <tr><th><a href="directive-dict.html#Module">Modül:</a></th><td>core</td></tr>
+<tr><th><a href="directive-dict.html#Compatibility">Uyumluluk:</a></th><td>İç içe geçmiş koşullar 2.4.26 ve sonrasında değerlendirilmeye alınır</td></tr>
 </table>
     <p><code class="directive"><Else></code> sadece ve sadece aynı etki
       alanındaki en son <code class="directive"><If></code> veya
@@ -1162,6 +1161,7 @@ DocumentRoot "/var/www/${servername}/htdocs"</pre>
 <tr><th><a href="directive-dict.html#Override">Geçersizleştirme:</a></th><td>All</td></tr>
 <tr><th><a href="directive-dict.html#Status">Durum:</a></th><td>Çekirdek</td></tr>
 <tr><th><a href="directive-dict.html#Module">Modül:</a></th><td>core</td></tr>
+<tr><th><a href="directive-dict.html#Compatibility">Uyumluluk:</a></th><td>İç içe geçmiş koşullar 2.4.26 ve sonrasında değerlendirilmeye alınır</td></tr>
 </table>
     <p><code class="directive"><ElseIf></code> kapsadığı yönergeleri
       sadece ve sadece belirtilen koşulun doğrulandığı ancak aynı etki
@@ -2165,6 +2165,7 @@ takdirde uygulanacak yönergeleri barındırır.</td></tr>
 <tr><th><a href="directive-dict.html#Override">Geçersizleştirme:</a></th><td>All</td></tr>
 <tr><th><a href="directive-dict.html#Status">Durum:</a></th><td>Çekirdek</td></tr>
 <tr><th><a href="directive-dict.html#Module">Modül:</a></th><td>core</td></tr>
+<tr><th><a href="directive-dict.html#Compatibility">Uyumluluk:</a></th><td>İç içe geçmiş koşullar 2.4.26 ve sonrasında değerlendirilmeye alınır</td></tr>
 </table>
     <p><code class="directive"><If></code> yönergesi bir ifadeyi çalışma
       anında değerlendirir ve ifadenin sonucu doğru olduğu takdirde içerdiği
@@ -2199,12 +2200,6 @@ takdirde uygulanacak yönergeleri barındırır.</td></tr>
     yönerge için kullanılabilir olmayacaktır.
     </div>
 
-    <div class="note"><h3>Betik dillerindeki gibi değil</h3>
-    Bu yönergenin ismi yöneticiler ve yazılımcılara çok tanıdıktır fakat betik 
-    dillerinde rastladığınız benzeri ile karıştırılmamalıdır. Örneğin, mevcut 
-    gerçeklenimde iç içe <code class="directive"><If></code> yönergeleri 
-    desteklenmemektedir.
-    </div>
 
 <h3>Ayrıca bakınız:</h3>
 <ul>
diff --git a/docs/manual/mod/mod_autoindex.html.tr.utf8 b/docs/manual/mod/mod_autoindex.html.tr.utf8
index 5c17426..cbca2d1 100644
--- a/docs/manual/mod/mod_autoindex.html.tr.utf8
+++ b/docs/manual/mod/mod_autoindex.html.tr.utf8
@@ -32,7 +32,6 @@
 <a href="../ko/mod/mod_autoindex.html" hreflang="ko" rel="alternate" title="Korean"> ko </a> |
 <a href="../tr/mod/mod_autoindex.html" title="Türkçe"> tr </a></p>
 </div>
-<div class="outofdate">Bu çeviri güncel olmayabilir. Son değişiklikler için İngilizce sürüm geçerlidir.</div>
 <table class="module"><tr><th><a href="module-dict.html#Description">Açıklama:</a></th><td>Unix <code>ls</code> veya Win32 <code>dir</code> kabuk komutunun
 yaptığı gibi dizin içeriğini listeler.</td></tr>
 <tr><th><a href="module-dict.html#Status">Durum:</a></th><td>Temel</td></tr>
@@ -831,6 +830,16 @@ belirler.</td></tr>
       <pre class="prettyprint lang-config">IndexOptions Type=text/plain</pre>
 
       </dd>
+      
+      <dt><a name="indexoptions.useolddateformat" id="indexoptions.useolddateformat">UseOldDateFormat</a>
+      (<em>Apache HTTP Sunucusu 2.4.26 ve sonrasında</em>)</dt>
+
+      <dd><code>Last Modified</code> alanı tarafından kullanılan tarih biçemi 
+        <code>"%Y-%m-%d %H:%M"</code> dikkatsizlik sonucu 2.4.0 sürümünde 
+        <code>"%d-%b-%Y %H:%M"</code> olarak değişmiştir. Bu seçenekle tarih 
+        biçemini 2.2 ve öncesindeki biçemiyle kullanabilirsiniz.</dd>
+
+      
       <dt><a name="indexoptions.versionsort" id="indexoptions.versionsort"><code>VersionSort</code></a>
       </dt>
 
diff --git a/docs/manual/mod/mod_proxy.html.en b/docs/manual/mod/mod_proxy.html.en
index e9fe8ee..11d6d1e 100644
--- a/docs/manual/mod/mod_proxy.html.en
+++ b/docs/manual/mod/mod_proxy.html.en
@@ -244,7 +244,7 @@ ProxyVia On
 
       <p>The two default workers have a fixed configuration
       and will be used if no other worker matches the request.
-      They do not use HTTP Keep-Alive or connection pooling.
+      They do not use HTTP Keep-Alive or connection reuse.
       The TCP connections to the origin server will instead be
       opened and closed for each request.</p>
 
@@ -344,8 +344,8 @@ ProxyPass "/examples" "http://backend.example.com/examples" timeout=10</pre>
       <div class="note"><h3>DNS resolution for origin domains</h3>
       <p>DNS resolution happens when the socket to
         the origin domain is created for the first time.
-        When connection pooling is used, each backend domain is resolved 
-        only once per child process, and reused for all further connections 
+        When connection reuse is enabled, each backend domain is resolved 
+        only once per child process, and cached for all further connections 
         until the child is recycled. This information should to be considered 
         while planning DNS maintenance tasks involving backend domains. 
         Please also check <code class="directive"><a href="#proxypass">ProxyPass</a></code>
@@ -550,8 +550,8 @@ ProxyPass "/examples" "http://backend.example.com/examples" timeout=10</pre>
             directive and can take any of the key value pair parameters available to
             <code class="directive"><a href="#proxypass">ProxyPass</a></code> directives.</p>
         <p>One additional parameter is available only to <code class="directive">BalancerMember</code> directives:
-            <var>loadfactor</var>. This is the member load factor - a number between 1
-            (default) and 100, which defines the weighted load to be applied to the
+            <var>loadfactor</var>. This is the member load factor - a decimal number between 1.0
+            (default) and 100.0, which defines the weighted load to be applied to the
             member in question.</p>
         <p>The <var>balancerurl</var> is only needed when not within a
             <code><Proxy <var>balancer://</var>...></code>
@@ -990,7 +990,11 @@ through</td></tr>
     a local virtual path; <var>url</var> is a partial URL for the
     remote server and cannot include a query string.</p>
 
-    <div class="note"><strong>Note: </strong>This directive is not supported within
+    <div class="note">It is strongly suggested to review the concept of a
+    <a href="#workers">Worker</a> before proceeding any further
+    with this section.</div>
+
+    <div class="note">This directive is not supported within
     <code class="directive"><a href="../mod/core.html#directory"><Directory></a></code> and
     <code class="directive"><a href="../mod/core.html#files"><Files></a></code> containers.</div>
 
@@ -1097,24 +1101,26 @@ ProxyPass "/mirror/foo" "http://backend.example.com"</pre>
     using  <code>key=value</code> parameters, described in the tables
     below.</p>
 
+    <div class="warning"><h3>Maximum connections to the backend</h3>
     <p>By default, mod_proxy will allow and retain the maximum number of
     connections that could be used simultaneously by that web server child
     process.  Use the <code>max</code> parameter to reduce the number from
-    the default.  Use the <code>ttl</code> parameter to set an optional
+    the default. The pool of connections is maintained per web server child
+    process, and <code>max</code> and other settings are not coordinated
+    among all child processes, except when only one child process is allowed
+    by configuration or MPM design.</p>
+    </div>
+
+    <p>Use the <code>ttl</code> parameter to set an optional
     time to live; connections which have been unused for at least
     <code>ttl</code> seconds will be closed.  <code>ttl</code> can be used
     to avoid using a connection which is subject to closing because of the
     backend server's keep-alive timeout.</p>
 
-    <p>The pool of connections is maintained per web server child
-    process, and <code>max</code> and other settings are not coordinated
-    among all child processes, except when only one child process is allowed
-    by configuration or MPM design.</p>
-
     <div class="example"><h3>Example</h3><pre class="prettyprint lang-config">ProxyPass "/example" "http://backend.example.com" max=20 ttl=120 retry=300</pre>
 </div>
 
-    <table class="bordered"><tr><th>BalancerMember parameters</th></tr></table>
+    <table class="bordered"><tr><th>Worker|BalancerMember parameters</th></tr></table>
     <table>
     <tr><th>Parameter</th>
         <th>Default</th>
@@ -1165,7 +1171,10 @@ ProxyPass "/mirror/foo" "http://backend.example.com"</pre>
     httpd and
     the backend server (regardless of protocol) tends to silently
     drop connections or when backends themselves may be under round-
-    robin DNS. To disable connection pooling reuse,
+    robin DNS.
+    When connection reuse is enabled each backend domain is resolved
+    (with a DNS query) only once per child process and cached for all further
+    connections until the child is recycled. To disable connection reuse,
     set this property value to <code>On</code>.
     </td></tr>
     <tr><td>enablereuse</td>
@@ -1429,7 +1438,7 @@ ProxyPass "/" "balancer://mycluster/" stickysession=JSESSIONID|jsessionid nofail
     <pre class="prettyprint lang-config">ProxyPass "/" "balancer://hotcluster/"
 <Proxy "balancer://hotcluster">
     BalancerMember "ajp://1.2.3.4:8009" loadfactor=1
-    BalancerMember "ajp://1.2.3.5:8009" loadfactor=2
+    BalancerMember "ajp://1.2.3.5:8009" loadfactor=2.25
     # The server below is on hot standby
     BalancerMember "ajp://1.2.3.6:8009" status=+H
     ProxySet lbmethod=bytraffic
diff --git a/docs/manual/mod/mod_proxy.html.fr b/docs/manual/mod/mod_proxy.html.fr
index 56ca1ab..53f1bda 100644
--- a/docs/manual/mod/mod_proxy.html.fr
+++ b/docs/manual/mod/mod_proxy.html.fr
@@ -266,8 +266,7 @@ ProxyVia On
 
       <p>Les deux workers par d�faut poss�dent une configuration fig�e
       et seront utilis�s si aucun autre worker ne correspond � la
-      requ�te. Ils n'utilisent ni les jeux de connexions (connection
-      pooling), ni les
+      requ�te. Ils ne r�utilisent pas les connexions et n'utilisent pas les
       connexions HTTP persistantes (Keep-Alive). En effet, les
       connexions TCP vers le serveur original sont ferm�es et ouvertes
       pour chaque requ�te.</p>
@@ -376,16 +375,15 @@ ProxyPass "/examples" "http://backend.example.com/examples" timeout=10</pre>
 
       <div class="note"><h3>R�solution DNS pour les domaines originaux</h3>
       <p>La r�solution DNS s'effectue lorsque le socket vers le
-      domaine original est cr�� pour la premi�re fois. Lorsque le pooling de
-      connexions est utilis�, chaque domaine d'arri�re-plan n'est r�solu qu'une
-      seule fois pour chaque processus enfant, et cette r�solution est r�utilis�e
-      pour toutes les connexions ult�rieures jusqu'� ce que le processus enfant
+      domaine original est cr�� pour la premi�re fois. Lorsque la r�utilisation
+      des connexions est activ�e, chaque domaine d'arri�re-plan n'est r�solu qu'une
+      seule fois pour chaque processus enfant, et cette r�solution est mise en
+      cache pour toutes les connexions ult�rieures jusqu'� ce que le processus enfant
       soit recycl�. Ce comportement doit �tre pris en consid�ration lorsqu'on
       planifie des t�ches de maintenance du DNS impactant les domaines
       d'arri�re-plan. Veuillez aussi vous reporter aux param�tres de la
       directive <code class="directive"><a href="#proxypass">ProxyPass</a></code> pour plus de
-      d�tails � propos de la r�utilisation des connexions.
-        </p>
+      d�tails � propos de la r�utilisation des connexions.</p>
       </div>
 
     </div><div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
@@ -616,7 +614,7 @@ charge</td></tr>
     <code class="directive"><a href="#proxypass">ProxyPass</a></code>.</p>
     <p>La directive <code class="directive">BalancerMember</code> accepte un param�tre
     suppl�mentaire : <var>loadfactor</var>. Il s'agit du facteur de
-    charge du membre - un nombre entre 1 (valeur par d�faut) et 100, qui
+    charge du membre - un nombre d�cimal entre 1.0 (valeur par d�faut) et 100.0, qui
     d�finit la charge � appliquer au membre en question.</p>
     <p>L'argument <var>balancerurl</var> n'est requis que s'il ne se trouve pas
     d�j� dans la directive de conteneur <code><Proxy
@@ -1112,7 +1110,9 @@ sont support
     chemin virtuel local ; <var>url</var> est une URL partielle pour le
     serveur distant et ne doit pas contenir de cha�ne d'arguments.</p>
 
-    <div class="note"><strong>Note : </strong>Cette directive n'est pas support�e au sein
+    <div class="note">Il est fortement recommand� de revoir le concept de <a href="#workers">Worker</a> avant d'aller plus loin.</div>
+
+    <div class="note">Cette directive n'est pas support�e au sein
     des sections <code class="directive"><a href="../mod/core.html#directory"><Directory></a></code>
     et <code class="directive"><a href="../mod/core.html#files"><Files></a></code>.</div>
 
@@ -1228,10 +1228,18 @@ ProxyPass "/mirror/foo" "http://backend.example.com"</pre>
     <code>cl�=valeur</code> dont la description fait l'objet des
     tableaux ci-dessous.</p>
 
-    <p>Par d�faut, mod_proxy permet et met en r�serve le nombre maximum
-    de connexions pouvant �tre utilis�es simultan�ment par le processus
-    enfant concern� du serveur web. Le param�tre <code>max</code> permet
-    de r�duire cette valeur par d�faut. Le param�tre <code>ttl</code>,
+    <div class="warning"><h3>Nombre maximum de connexions vers
+    l'arri�re-plan</h3>
+     <p>Par d�faut, mod_proxy permet et met en r�serve le
+    nombre maximum de connexions pouvant �tre utilis�es simultan�ment par le
+    processus enfant concern� du serveur web. Le param�tre <code>max</code>
+    permet de r�duire cette valeur par d�faut. Le jeu de connexions est maintenu
+    au niveau de chaque processus enfant du serveur web, <code>max</code> et les
+    autres r�glages n'�tant pas coordonn�s entre ces diff�rents processus, sauf
+    bien entendu lorsqu'un seul processus enfant n'est autoris� par la
+    configuration ou le MPM utilis�.</p> </div>
+    
+    <p>Le param�tre <code>ttl</code>,
     quant � lui, permet de d�finir une dur�e de vie optionnelle ; les
     connexions qui n'ont pas �t� utilis�es pendant au moins
     <code>ttl</code> secondes seront ferm�es. <code>ttl</code> permet
@@ -1239,17 +1247,10 @@ ProxyPass "/mirror/foo" "http://backend.example.com"</pre>
     ferm�e suite � une fin de vie de connexion persistante sur le
     serveur d'arri�re-plan.</p>
 
-    <p>Le groupement de connexions est maintenu au niveau de chaque
-    processus enfant du serveur web, et <code>max</code>, ainsi que les
-    autres param�tres, ne font
-    l'objet d'aucune coordination entre les diff�rents processus
-    enfants, sauf si un seul processus enfant est autoris� par la
-    configuration ou la conception du module multi-processus (MPM).</p>
-
     <div class="example"><h3>Exemple</h3><pre class="prettyprint lang-config">ProxyPass "/example" "http://backend.example.com" max=20 ttl=120 retry=300</pre>
 </div>
 
-    <table class="bordered"><tr><th>Param�tres de BalancerMember</th></tr></table>
+    <table class="bordered"><tr><th>Param�tres de worker (directive BalancerMember)</th></tr></table>
     <table>
     <tr><th>Param�tre</th>
         <th>D�faut</th>
@@ -1305,7 +1306,11 @@ ProxyPass "/mirror/foo" "http://backend.example.com"</pre>
 	serveur d'arri�re-plan (quelque soit le protocole) interrompt
 	des connexions de mani�re silencieuse, ou lorsque le serveur
 	d'arri�re-plan lui-m�me est accessible par rotation de DNS
-	(round-robin DNS). Pour d�sactiver la r�utilisation du jeu de
+	(round-robin DNS). Lorsque la r�utilisation des connexions est activ�e,
+	chaque domaine d'arri�re-plan n'est r�solu (via une requ�te DNS) qu'une
+	seule fois par chaque processus enfant et mis en cache pour toutes les
+	connexions ult�rieures jusqu'au recyclage du processus concern�.	
+	Pour d�sactiver la r�utilisation du jeu de
 	connexions, d�finissez cette cl� � <code>On</code>.
     </td></tr>
     <tr><td>enablereuse</td>
@@ -1618,7 +1623,7 @@ ProxyPass "/" "balancer://mycluster/" stickysession=JSESSIONID|jsessionid nofail
     <pre class="prettyprint lang-config">ProxyPass "/" "balancer://hotcluster/"
 <Proxy "balancer://hotcluster">
     BalancerMember "ajp://1.2.3.4:8009" loadfactor=1
-    BalancerMember "ajp://1.2.3.5:8009" loadfactor=2
+    BalancerMember "ajp://1.2.3.5:8009" loadfactor=2.25
     # The server below is on hot standby
     BalancerMember "ajp://1.2.3.6:8009" status=+H
     ProxySet lbmethod=bytraffic
diff --git a/docs/manual/mod/mod_proxy_balancer.html.en b/docs/manual/mod/mod_proxy_balancer.html.en
index 48b9b33..54a0307 100644
--- a/docs/manual/mod/mod_proxy_balancer.html.en
+++ b/docs/manual/mod/mod_proxy_balancer.html.en
@@ -81,6 +81,10 @@
 <h3>Bugfix checklist</h3><ul class="seealso"><li><a href="https://www.apache.org/dist/httpd/CHANGES_2.4">httpd changelog</a></li><li><a href="https://bz.apache.org/bugzilla/buglist.cgi?bug_status=__open__&list_id=144532&product=Apache%20httpd-2&query_format=specific&order=changeddate%20DESC%2Cpriority%2Cbug_severity&component=mod_proxy_balancer">Known issues</a></li><li><a href="https://bz.apache.org/bugzilla/enter_bug.cgi?product=Apache%20httpd-2&component=mod_pr [...]
 <ul class="seealso">
 <li><code class="module"><a href="../mod/mod_proxy.html">mod_proxy</a></code></li>
+<li><code class="directive"><a href="../mod/mod_proxy.html#balancermember">BalancerMember</a></code></li>
+<li><code class="directive"><a href="../mod/mod_proxy.html#balancergrowth">BalancerGrowth</a></code></li>
+<li><code class="directive"><a href="../mod/mod_proxy.html#balancerpersist">BalancerPersist</a></code></li>
+<li><code class="directive"><a href="../mod/mod_proxy.html#balancerinherit">BalancerInherit</a></code></li>
 <li><a href="#comments_section">Comments</a></li></ul></div>
 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
 <div class="section">
diff --git a/docs/manual/mod/mod_proxy_balancer.html.fr b/docs/manual/mod/mod_proxy_balancer.html.fr
index b6eb8c9..a24e018 100644
--- a/docs/manual/mod/mod_proxy_balancer.html.fr
+++ b/docs/manual/mod/mod_proxy_balancer.html.fr
@@ -88,6 +88,10 @@ la r
 <h3>Traitement des bugs</h3><ul class="seealso"><li><a href="https://www.apache.org/dist/httpd/CHANGES_2.4">Journal des modifications de httpd</a></li><li><a href="https://bz.apache.org/bugzilla/buglist.cgi?bug_status=__open__&list_id=144532&product=Apache%20httpd-2&query_format=specific&order=changeddate%20DESC%2Cpriority%2Cbug_severity&component=mod_proxy_balancer">Probl�mes connus</a></li><li><a href="https://bz.apache.org/bugzilla/enter_bug.cgi?product=Apache%20ht [...]
 <ul class="seealso">
 <li><code class="module"><a href="../mod/mod_proxy.html">mod_proxy</a></code></li>
+<li><code class="directive"><a href="../mod/mod_proxy.html#balancermember">BalancerMember</a></code></li>
+<li><code class="directive"><a href="../mod/mod_proxy.html#balancergrowth">BalancerGrowth</a></code></li>
+<li><code class="directive"><a href="../mod/mod_proxy.html#balancerpersist">BalancerPersist</a></code></li>
+<li><code class="directive"><a href="../mod/mod_proxy.html#balancerinherit">BalancerInherit</a></code></li>
 <li><a href="#comments_section">Commentaires</a></li></ul></div>
 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
 <div class="section">
diff --git a/docs/manual/mod/mod_proxy_express.html.en b/docs/manual/mod/mod_proxy_express.html.en
index cfc1cad..b75d718 100644
--- a/docs/manual/mod/mod_proxy_express.html.en
+++ b/docs/manual/mod/mod_proxy_express.html.en
@@ -88,6 +88,10 @@
 <h3>Bugfix checklist</h3><ul class="seealso"><li><a href="https://www.apache.org/dist/httpd/CHANGES_2.4">httpd changelog</a></li><li><a href="https://bz.apache.org/bugzilla/buglist.cgi?bug_status=__open__&list_id=144532&product=Apache%20httpd-2&query_format=specific&order=changeddate%20DESC%2Cpriority%2Cbug_severity&component=mod_proxy_express">Known issues</a></li><li><a href="https://bz.apache.org/bugzilla/enter_bug.cgi?product=Apache%20httpd-2&component=mod_pro [...]
 <ul class="seealso">
 <li><code class="module"><a href="../mod/mod_proxy.html">mod_proxy</a></code></li>
+<li><code class="directive"><a href="../mod/mod_proxy.html#balancermember">BalancerMember</a></code></li>
+<li><code class="directive"><a href="../mod/mod_proxy.html#balancergrowth">BalancerGrowth</a></code></li>
+<li><code class="directive"><a href="../mod/mod_proxy.html#balancerpersist">BalancerPersist</a></code></li>
+<li><code class="directive"><a href="../mod/mod_proxy.html#balancerinherit">BalancerInherit</a></code></li>
 <li><a href="#comments_section">Comments</a></li></ul></div>
 
 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
diff --git a/docs/manual/mod/mod_proxy_express.html.fr b/docs/manual/mod/mod_proxy_express.html.fr
index 0edea01..af2e512 100644
--- a/docs/manual/mod/mod_proxy_express.html.fr
+++ b/docs/manual/mod/mod_proxy_express.html.fr
@@ -92,6 +92,10 @@ dynamique inverse de masse</td></tr>
 <h3>Traitement des bugs</h3><ul class="seealso"><li><a href="https://www.apache.org/dist/httpd/CHANGES_2.4">Journal des modifications de httpd</a></li><li><a href="https://bz.apache.org/bugzilla/buglist.cgi?bug_status=__open__&list_id=144532&product=Apache%20httpd-2&query_format=specific&order=changeddate%20DESC%2Cpriority%2Cbug_severity&component=mod_proxy_express">Probl�mes connus</a></li><li><a href="https://bz.apache.org/bugzilla/enter_bug.cgi?product=Apache%20htt [...]
 <ul class="seealso">
 <li><code class="module"><a href="../mod/mod_proxy.html">mod_proxy</a></code></li>
+<li><code class="directive"><a href="../mod/mod_proxy.html#balancermember">BalancerMember</a></code></li>
+<li><code class="directive"><a href="../mod/mod_proxy.html#balancergrowth">BalancerGrowth</a></code></li>
+<li><code class="directive"><a href="../mod/mod_proxy.html#balancerpersist">BalancerPersist</a></code></li>
+<li><code class="directive"><a href="../mod/mod_proxy.html#balancerinherit">BalancerInherit</a></code></li>
 <li><a href="#comments_section">Commentaires</a></li></ul></div>
 
 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
diff --git a/docs/manual/mod/mod_proxy_fcgi.html.en b/docs/manual/mod/mod_proxy_fcgi.html.en
index a99265b..2c9ccf5 100644
--- a/docs/manual/mod/mod_proxy_fcgi.html.en
+++ b/docs/manual/mod/mod_proxy_fcgi.html.en
@@ -95,7 +95,7 @@
     <p> The following example passes the request URI as a filesystem
     path for the PHP-FPM daemon to run. The request URL is implicitly added
     to the 2nd parameter. The hostname and port following fcgi:// are where
-    PHP-FPM is listening.  Connection pooling is enabled.</p>
+    PHP-FPM is listening.  Connection pooling/reuse is enabled.</p>
     <div class="example"><h3>PHP-FPM</h3><pre class="prettyprint lang-config">ProxyPassMatch "^/myapp/.*\.php(/.*)?$" "fcgi://localhost:9000/var/www/" enablereuse=on</pre>
 </div>
 
@@ -103,8 +103,7 @@
     path for the PHP-FPM daemon to run. In this case, PHP-FPM is listening on
     a unix domain socket (UDS).  Requires 2.4.9 or later. With this syntax,
     the hostname and optional port following fcgi:// are ignored.</p>
-    <div class="example"><h3>PHP-FPM with UDS</h3><pre class="prettyprint lang-config"># UDS does not currently support connection reuse
-ProxyPassMatch "^/(.*\.php(/.*)?)$" "unix:/var/run/php5-fpm.sock|fcgi://localhost/var/www/"</pre>
+    <div class="example"><h3>PHP-FPM with UDS</h3><pre class="prettyprint lang-config">ProxyPassMatch "^/(.*\.php(/.*)?)$" "unix:/var/run/php5-fpm.sock|fcgi://localhost/var/www/"</pre>
 </div>
 
     <p>The balanced gateway needs <code class="module"><a href="../mod/mod_proxy_balancer.html">mod_proxy_balancer</a></code> and
diff --git a/docs/manual/mod/mod_proxy_fcgi.html.fr b/docs/manual/mod/mod_proxy_fcgi.html.fr
index 075349d..0991c4f 100644
--- a/docs/manual/mod/mod_proxy_fcgi.html.fr
+++ b/docs/manual/mod/mod_proxy_fcgi.html.fr
@@ -98,7 +98,7 @@
     que chemin du syst�me de fichiers pour l'ex�cution du d�mon PHP-FPM.
     L'URL de la requ�te est implicitement ajout�e au second param�tre.
     PHP-FPM est � l'�coute de l'h�te et du port qui
-    suivent fcgi://. La conservation des connexions est activ�e.</p>
+    suivent fcgi://. La conservation/r�utilisation des connexions est activ�e.</p>
     <div class="example"><h3>PHP-FPM</h3><pre class="prettyprint lang-config">ProxyPassMatch "^/myapp/.*\.php(/.*)?$" "fcgi://localhost:9000/var/www/" enablereuse=on</pre>
 </div>
 
@@ -108,8 +108,7 @@
     unix (UDS). Cette fonctionnalit� est disponible � partir de la
     version 2.4.9. Avec cette syntaxe, si un nom d'h�te et un port sont
     ajout�s apr�s fcgi://, ils seront ignor�s.</p>
-    <div class="example"><h3>PHP-FPM with UDS</h3><pre class="prettyprint lang-config">      # A ce jour, UDS ne supporte pas la r�utilisation des connexions
-      ProxyPassMatch "^/(.*\.php(/.*)?)$" "unix:/var/run/php5-fpm.sock|fcgi://localhost/var/www/"</pre>
+    <div class="example"><h3>PHP-FPM with UDS</h3><pre class="prettyprint lang-config">ProxyPassMatch "^/(.*\.php(/.*)?)$" "unix:/var/run/php5-fpm.sock|fcgi://localhost/var/www/"</pre>
 </div>
 
     <p>La passerelle � r�partition de charge n�cessite le chargement du
@@ -170,8 +169,9 @@
     fournisseur du protocole FCGI :</p>
     <dl>
         <dt>proxy-fcgi-pathinfo</dt>
-        <dd>Par d�faut, <code class="module"><a href="../mod/mod_proxy_fcgi.html">mod_proxy_fcgi</a></code> ne cr�era jamais
-	ni n'exportera la variable d'environnement <var>PATH_INFO</var>,
+        <dd>Lorsqu'il est configur� via les directives <code class="directive"><a href="../mod/mod_proxy.html#proxypass">ProxyPass</a></code> ou <code class="directive"><a href="../mod/mod_proxy.html#proxypassmatch">ProxyPassMatch</a></code>,
+	<code class="module"><a href="../mod/mod_proxy_fcgi.html">mod_proxy_fcgi</a></code> ne d�finit
+	pas la variable d'environnement <var>PATH_INFO</var>,
 	ce qui permet au serveur FCGI d'arri�re-plan de d�terminer
 	correctement <var>SCRIPT_NAME</var> et <var>Script-URI</var>, et
 	de se conformer � la section 3.3 de la RFC 3875. Si au contraire
diff --git a/docs/manual/mod/mod_proxy_wstunnel.html.en b/docs/manual/mod/mod_proxy_wstunnel.html.en
index fe8c817..a67cf5b 100644
--- a/docs/manual/mod/mod_proxy_wstunnel.html.en
+++ b/docs/manual/mod/mod_proxy_wstunnel.html.en
@@ -55,7 +55,9 @@ ProxyPass "/wss2/" "wss://echo.websocket.org/"</pre>
 <p>In fact the module can be used to upgrade to other protocols, you can set the <code>upgrade</code>
 parameter in the <code class="directive"><a href="../mod/mod_proxy.html#proxypass">ProxyPass</a></code>
 directive to allow the module to accept other protocol.
-NONE means you bypass the check for the header but still upgrade to WebSocket.</p>
+NONE means you bypass the check for the header but still upgrade to WebSocket.
+ANY means that <code>Upgrade</code> will read in the request headers and use
+in the response <code>Upgrade</code></p>
 </div>
 <div id="quickview"><a href="https://www.apache.org/foundation/contributing.html" class="badge"><img src="https://www.apache.org/images/SupportApache-small.png" alt="Support Apache!" /></a><h3 class="directives">Directives</h3>
 <p>This module provides no
diff --git a/docs/manual/mod/mod_reqtimeout.html.fr b/docs/manual/mod/mod_reqtimeout.html.fr
index 97fd974..5620f97 100644
--- a/docs/manual/mod/mod_reqtimeout.html.fr
+++ b/docs/manual/mod/mod_reqtimeout.html.fr
@@ -56,7 +56,7 @@ donn
         Accorde 10 secondes pour la r�ception des en-t�tes de la requ�te
 	et 30 secondes pour la r�ception du corps :
 
-        <pre class="prettyprint lang-config">RequestTimeout headerinit=10 body=30</pre>
+        <pre class="prettyprint lang-config">RequestReadTimeout headerinit=10 body=30</pre>
 
       </li>
 
diff --git a/docs/manual/mod/mpm_common.html.en b/docs/manual/mod/mpm_common.html.en
index 64643e2..281e7f2 100644
--- a/docs/manual/mod/mpm_common.html.en
+++ b/docs/manual/mod/mpm_common.html.en
@@ -306,6 +306,27 @@ in *BSDs.</td></tr>
     The number of children processes needs to be a multiple of the number 
     of buckets to optimally accept connections.</p>
 
+    <div class="note">
+    <h3>Multiple <code class="directive">Listen</code>ers or Apache HTTP servers on
+    the same IP address and port</h3>
+    <p>Setting the <code>SO_REUSEPORT</code> option on the listening socket(s)
+    consequently allows multiple processes (sharing the same <code>EUID</code>,
+    e.g. <code>root</code>) to bind to the the same IP address and port,
+    without the binding error raised by the system in the usual case.</p>
+    <p>This also means that multiple instances of Apache httpd configured on a
+    same <code>IP:port</code> and with a positive <code class="directive">ListenCoresBucketsRatio</code>
+    would start without an error too, and then run with incoming connections
+    evenly distributed accross both instances (this is NOT a recommendation or
+    a sensible usage in any case, but just a notice that it would prevent such
+    possible issues to be detected).</p>
+    <p>Within the same instance, Apache httpd will check and fail to start if
+    multiple <code class="directive">Listen</code> directives on the exact same IP (or
+    hostname) and port are configured, thus avoiding the creation of some
+    duplicated buckets which would be useless and kill performances.  However
+    it can't (and won't try harder to) catch all the possible overlapping cases
+    (like a hostname resolving to an IP used elsewhere).</p>
+    </div>
+
 </div>
 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
 <div class="directive-section"><h2><a name="MaxConnectionsPerChild" id="MaxConnectionsPerChild">MaxConnectionsPerChild</a> <a name="maxconnectionsperchild" id="maxconnectionsperchild">Directive</a></h2>
diff --git a/docs/manual/mod/mpm_common.html.fr b/docs/manual/mod/mpm_common.html.fr
index 73641ec..6a414e7 100644
--- a/docs/manual/mod/mpm_common.html.fr
+++ b/docs/manual/mod/mpm_common.html.fr
@@ -338,6 +338,32 @@ plateformes de type BSD.</td></tr>
     connexions de mani�re optimale, le nombre de processus enfants doit �tre un
     multiple du nombre de segments d'�coute.</p>
 
+    <div class="note">
+    <h3>Cas o� plusieurs <code class="directive">Listen</code>ers ou serveurs HTTP
+    Apache partagent la m�me adresse IP et port</h3>
+    <p>La d�finition de l'option <code>SO_REUSEPORT</code> pour les sockets
+    d'�coute permet � plusieurs processus (partageant le m�me <code>EUID</code>,
+    par exemple <code>root</code>) de se rattacher � la m�me adresse IP et port,
+    sans obtenir l'erreur de rattachement que le syst�me g�n�re habituellement
+    lorsque ce cas se produit.</p>
+    <p>Cela signifie aussi que plusieurs instances d'Apache httpd configur�es
+    avec le m�me <code>IP:port</code> et avec une valeur
+    <code class="directive">ListenCoresBucketsRatio</code> positive pourraient d�marrer
+    sans erreur, et fonctionner ensuite avec une r�partition uniforme des
+    connexions entrantes sur ces diff�rentes instances (ce n'est PAS une
+    recommandation et ne constitue pas un usage appropri� � tous les cas, mais
+    juste un avertissement sur le fait qu'un v�ritable probl�me de rattachement
+    multiple � un <code>IP:port</code> pourrait alors �tre occult�).</p>
+    <p>Au sein d'une m�me instance, Apache httpd v�rifie la pr�sence de
+    directives <code class="directive">Listen</code> multiples avec la m�me adresse IP
+    (ou nom d'h�te) et le m�me port, et refuse de d�marrer si c'est le cas, ce
+    qui permet d'�viter la cr�ation de segments d'�coute dupliqu�s qui seraient
+    du coup inutiles et affecteraient les performances. Cependant, il ne peut
+    pas (et n'essaiera pas de le faire) intercepter tous les cas possibles de
+    recouvrement (comme un nom d'h�te correspondant � une adresse IP utilis�e
+    quelque part ailleurs).</p>
+    </div>
+    
 </div>
 <div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
 <div class="directive-section"><h2><a name="maxconnectionsperchild" id="maxconnectionsperchild">Directive</a> <a name="MaxConnectionsPerChild" id="MaxConnectionsPerChild">MaxConnectionsPerChild</a></h2>
diff --git a/docs/manual/mod/mpm_common.html.tr.utf8 b/docs/manual/mod/mpm_common.html.tr.utf8
index 515479c..56f760b 100644
--- a/docs/manual/mod/mpm_common.html.tr.utf8
+++ b/docs/manual/mod/mpm_common.html.tr.utf8
@@ -32,6 +32,7 @@
 <a href="../ja/mod/mpm_common.html" hreflang="ja" rel="alternate" title="Japanese"> ja </a> |
 <a href="../tr/mod/mpm_common.html" title="Türkçe"> tr </a></p>
 </div>
+<div class="outofdate">Bu çeviri güncel olmayabilir. Son değişiklikler için İngilizce sürüm geçerlidir.</div>
 <table class="module"><tr><th><a href="module-dict.html#Description">Açıklama:</a></th><td>Birden fazla Çok Süreçlilik Modülü (MPM) tarafından gerçeklenmiş
   yönergeler bütünü.</td></tr>
 <tr><th><a href="module-dict.html#Status">Durum:</a></th><td>MPM</td></tr></table>
diff --git a/docs/manual/mod/overrides.html b/docs/manual/mod/overrides.html
new file mode 100644
index 0000000..c1e8e6e
--- /dev/null
+++ b/docs/manual/mod/overrides.html
@@ -0,0 +1,5 @@
+# GENERATED FROM XML -- DO NOT EDIT
+
+URI: overrides.html.en
+Content-Language: en
+Content-type: text/html; charset=ISO-8859-1
diff --git a/docs/manual/mod/overrides.html.en b/docs/manual/mod/overrides.html.en
new file mode 100644
index 0000000..7f46bb4
--- /dev/null
+++ b/docs/manual/mod/overrides.html.en
@@ -0,0 +1,767 @@
+<?xml version="1.0" encoding="ISO-8859-1"?>
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en"><head>
+<meta content="text/html; charset=ISO-8859-1" http-equiv="Content-Type" />
+<!--
+        XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
+              This file is generated from xml source: DO NOT EDIT
+        XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
+      -->
+<title>Override Class Index for .htaccess - Apache HTTP Server Version 2.4</title>
+<link href="../style/css/manual.css" rel="stylesheet" media="all" type="text/css" title="Main stylesheet" />
+<link href="../style/css/manual-loose-100pc.css" rel="alternate stylesheet" media="all" type="text/css" title="No Sidebar - Default font size" />
+<link href="../style/css/manual-print.css" rel="stylesheet" media="print" type="text/css" /><link rel="stylesheet" type="text/css" href="../style/css/prettify.css" />
+<script src="../style/scripts/prettify.min.js" type="text/javascript">
+</script>
+
+<link href="../images/favicon.ico" rel="shortcut icon" /></head>
+<body id="override-index">
+<div id="page-header">
+<p class="menu"><a href="../mod/">Modules</a> | <a href="../mod/directives.html">Directives</a> | <a href="http://wiki.apache.org/httpd/FAQ">FAQ</a> | <a href="../glossary.html">Glossary</a> | <a href="../sitemap.html">Sitemap</a></p>
+<p class="apache">Apache HTTP Server Version 2.4</p>
+<img alt="" src="../images/feather.png" /></div>
+<div class="up"><a href="./"><img title="<-" alt="<-" src="../images/left.gif" /></a></div>
+<div id="path">
+<a href="http://www.apache.org/">Apache</a> > <a href="http://httpd.apache.org/">HTTP Server</a> > <a href="http://httpd.apache.org/docs/">Documentation</a> > <a href="../">Version 2.4</a></div>
+
+<div id="page-content"><div id="preamble"><h1>Override Class Index for .htaccess</h1>
+<div class="toplang">
+<p><span>Available Languages: </span><a href="../en/mod/overrides.html" title="English"> en </a></p>
+</div>
+
+    <p>
+      This is an index of the directives that are allowed in .htaccess files for
+      various <code class="directive"><a href="../mod/core.html#allowoverride">AllowOverride</a></code> settings,
+      organized by class. Its intended purpose is to help server administrators
+      verify the privileges they're granting to .htaccess users. For an overview
+      of how .htaccess works, see the
+      <a href="../howto/htaccess.html">.htaccess tutorial</a>.
+    </p>
+
+    <p>
+      To determine the set of directives that your server configuration allows
+      .htaccess users to use:
+    </p>
+
+    <ol>
+      <li>Start with the set of directives in the <code>AllowOverrideList</code>
+      for the directory in question. (By default, this is set to
+      <code>None</code>.)</li>
+      <li>Find the <code>AllowOverride</code> setting for the directory in
+      question. (By default, it is set to <code>None</code>.) There are two
+      special cases:
+        <ol>
+          <li>If your <code>AllowOverride</code> setting is <code>All</code>,
+          add every directive listed on this page to the list.</li>
+          <li>If your <code>AllowOverride</code> setting is <code>None</code>,
+          you're done. Only the directives in the <code>AllowOverrideList</code>
+          (if any) will be allowed.</li>
+        </ol>
+      </li>
+      <li>For each override class listed in <code>AllowOverride</code>, look up
+      the corresponding set of directives below and add them to the list.</li>
+      <li>Finally, add the set of directives that is always allowed in
+      .htaccess (these are listed in the
+      <a href="#override-all">All section</a>, below).</li>
+    </ol>
+
+    <p>
+      Several of the override classes are quite powerful and give .htaccess
+      users a large amount of control over the server. For a stricter approach,
+      set <code>AllowOverride None</code> and use
+      <code class="directive"><a href="../mod/core.html#allowoverridelist">AllowOverrideList</a></code> to specify the
+      exact list of directives that .htaccess users are allowed to use.
+    </p>
+  </div>
+<div id="quickview"><h3>Topics</h3>
+<ul id="topics">
+<li><img alt="" src="../images/down.gif" /> <a href="#override-all">All</a></li>
+<li><img alt="" src="../images/down.gif" /> <a href="#override-authconfig">AuthConfig</a></li>
+<li><img alt="" src="../images/down.gif" /> <a href="#override-fileinfo">FileInfo</a></li>
+<li><img alt="" src="../images/down.gif" /> <a href="#override-indexes">Indexes</a></li>
+<li><img alt="" src="../images/down.gif" /> <a href="#override-limit">Limit</a></li>
+<li><img alt="" src="../images/down.gif" /> <a href="#override-options">Options</a></li>
+</ul><h3>See also</h3>
+<ul class="seealso">
+<li><a href="#comments_section">Comments</a></li></ul></div>
+<div id="override-list"><div class="top"><a href="#page-header"><img src="../images/up.gif" alt="top" /></a></div><div class="section"><h2><a name="override-all">All</a></h2>
+    <p>
+      The following directives are allowed in any .htaccess file, as long as
+      overrides are enabled in the server configuration.
+    </p>
+  <table class="qref"><tr><td><a href="core.html#else"><Else></a></td><td class="module"><a href="core.html">core</a></td></tr>
+<tr><td colspan="2" class="descr">Contains directives that apply only if the condition of a
+previous <code class="directive"><a href="../mod/core.html#if"><If></a></code> or
+<code class="directive"><a href="../mod/core.html#elseif"><ElseIf></a></code> section is not
+satisfied by a request at runtime</td></tr>
+<tr class="odd"><td><a href="core.html#elseif"><ElseIf></a></td><td class="module"><a href="core.html">core</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Contains directives that apply only if a condition is satisfied
+by a request at runtime while the condition of a previous
+<code class="directive"><a href="../mod/core.html#if"><If></a></code> or
+<code class="directive"><ElseIf></code> section is not
+satisfied</td></tr>
+<tr><td><a href="core.html#files"><Files></a></td><td class="module"><a href="core.html">core</a></td></tr>
+<tr><td colspan="2" class="descr">Contains directives that apply to matched
+filenames</td></tr>
+<tr class="odd"><td><a href="core.html#filesmatch"><FilesMatch></a></td><td class="module"><a href="core.html">core</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Contains directives that apply to regular-expression matched
+filenames</td></tr>
+<tr><td><a href="core.html#if"><If></a></td><td class="module"><a href="core.html">core</a></td></tr>
+<tr><td colspan="2" class="descr">Contains directives that apply only if a condition is
+satisfied by a request at runtime</td></tr>
+<tr class="odd"><td><a href="core.html#ifdefine"><IfDefine></a></td><td class="module"><a href="core.html">core</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Encloses directives that will be processed only
+if a test is true at startup</td></tr>
+<tr><td><a href="core.html#ifmodule"><IfModule></a></td><td class="module"><a href="core.html">core</a></td></tr>
+<tr><td colspan="2" class="descr">Encloses directives that are processed conditional on the
+presence or absence of a specific module</td></tr>
+<tr class="odd"><td><a href="mod_version.html#ifversion"><IfVersion></a></td><td class="module"><a href="mod_version.html">mod_version</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">contains version dependent configuration</td></tr>
+<tr><td><a href="core.html#limitrequestbody">LimitRequestBody</a></td><td class="module"><a href="core.html">core</a></td></tr>
+<tr><td colspan="2" class="descr">Restricts the total size of the HTTP request body sent
+from the client</td></tr>
+<tr class="odd"><td><a href="core.html#limitxmlrequestbody">LimitXMLRequestBody</a></td><td class="module"><a href="core.html">core</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Limits the size of an XML-based request body</td></tr>
+<tr><td><a href="mod_lua.html#luacodecache">LuaCodeCache</a></td><td class="module"><a href="mod_lua.html">mod_lua</a></td></tr>
+<tr><td colspan="2" class="descr">Configure the compiled code cache.</td></tr>
+<tr class="odd"><td><a href="mod_lua.html#luahookaccesschecker">LuaHookAccessChecker</a></td><td class="module"><a href="mod_lua.html">mod_lua</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Provide a hook for the access_checker phase of request processing</td></tr>
+<tr><td><a href="mod_lua.html#luahookauthchecker">LuaHookAuthChecker</a></td><td class="module"><a href="mod_lua.html">mod_lua</a></td></tr>
+<tr><td colspan="2" class="descr">Provide a hook for the auth_checker phase of request processing</td></tr>
+<tr class="odd"><td><a href="mod_lua.html#luahookcheckuserid">LuaHookCheckUserID</a></td><td class="module"><a href="mod_lua.html">mod_lua</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Provide a hook for the check_user_id phase of request processing</td></tr>
+<tr><td><a href="mod_lua.html#luahookfixups">LuaHookFixups</a></td><td class="module"><a href="mod_lua.html">mod_lua</a></td></tr>
+<tr><td colspan="2" class="descr">Provide a hook for the fixups phase of a request
+processing</td></tr>
+<tr class="odd"><td><a href="mod_lua.html#luahookinsertfilter">LuaHookInsertFilter</a></td><td class="module"><a href="mod_lua.html">mod_lua</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Provide a hook for the insert_filter phase of request processing</td></tr>
+<tr><td><a href="mod_lua.html#luahooklog">LuaHookLog</a></td><td class="module"><a href="mod_lua.html">mod_lua</a></td></tr>
+<tr><td colspan="2" class="descr">Provide a hook for the access log phase of a request
+processing</td></tr>
+<tr class="odd"><td><a href="mod_lua.html#luahookmaptostorage">LuaHookMapToStorage</a></td><td class="module"><a href="mod_lua.html">mod_lua</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Provide a hook for the map_to_storage phase of request processing</td></tr>
+<tr><td><a href="mod_lua.html#luahooktranslatename">LuaHookTranslateName</a></td><td class="module"><a href="mod_lua.html">mod_lua</a></td></tr>
+<tr><td colspan="2" class="descr">Provide a hook for the translate name phase of request processing</td></tr>
+<tr class="odd"><td><a href="mod_lua.html#luahooktypechecker">LuaHookTypeChecker</a></td><td class="module"><a href="mod_lua.html">mod_lua</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Provide a hook for the type_checker phase of request processing</td></tr>
+<tr><td><a href="mod_lua.html#luainherit">LuaInherit</a></td><td class="module"><a href="mod_lua.html">mod_lua</a></td></tr>
+<tr><td colspan="2" class="descr">Controls how parent configuration sections are merged into children</td></tr>
+<tr class="odd"><td><a href="mod_lua.html#luamaphandler">LuaMapHandler</a></td><td class="module"><a href="mod_lua.html">mod_lua</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Map a path to a lua handler</td></tr>
+<tr><td><a href="mod_lua.html#luapackagecpath">LuaPackageCPath</a></td><td class="module"><a href="mod_lua.html">mod_lua</a></td></tr>
+<tr><td colspan="2" class="descr">Add a directory to lua's package.cpath</td></tr>
+<tr class="odd"><td><a href="mod_lua.html#luapackagepath">LuaPackagePath</a></td><td class="module"><a href="mod_lua.html">mod_lua</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Add a directory to lua's package.path</td></tr>
+<tr><td><a href="mod_lua.html#luaquickhandler">LuaQuickHandler</a></td><td class="module"><a href="mod_lua.html">mod_lua</a></td></tr>
+<tr><td colspan="2" class="descr">Provide a hook for the quick handler of request processing</td></tr>
+<tr class="odd"><td><a href="mod_lua.html#luaroot">LuaRoot</a></td><td class="module"><a href="mod_lua.html">mod_lua</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Specify the base path for resolving relative paths for mod_lua directives</td></tr>
+<tr><td><a href="mod_lua.html#luascope">LuaScope</a></td><td class="module"><a href="mod_lua.html">mod_lua</a></td></tr>
+<tr><td colspan="2" class="descr">One of once, request, conn, thread -- default is once</td></tr>
+<tr class="odd"><td><a href="core.html#rlimitcpu">RLimitCPU</a></td><td class="module"><a href="core.html">core</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Limits the CPU consumption of processes launched
+by Apache httpd children</td></tr>
+<tr><td><a href="core.html#rlimitmem">RLimitMEM</a></td><td class="module"><a href="core.html">core</a></td></tr>
+<tr><td colspan="2" class="descr">Limits the memory consumption of processes launched
+by Apache httpd children</td></tr>
+<tr class="odd"><td><a href="core.html#rlimitnproc">RLimitNPROC</a></td><td class="module"><a href="core.html">core</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Limits the number of processes that can be launched by
+processes launched by Apache httpd children</td></tr>
+<tr><td><a href="core.html#serversignature">ServerSignature</a></td><td class="module"><a href="core.html">core</a></td></tr>
+<tr><td colspan="2" class="descr">Configures the footer on server-generated documents</td></tr>
+<tr class="odd"><td><a href="mod_include.html#ssierrormsg">SSIErrorMsg</a></td><td class="module"><a href="mod_include.html">mod_include</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Error message displayed when there is an SSI
+error</td></tr>
+<tr><td><a href="mod_include.html#ssitimeformat">SSITimeFormat</a></td><td class="module"><a href="mod_include.html">mod_include</a></td></tr>
+<tr><td colspan="2" class="descr">Configures the format in which date strings are
+displayed</td></tr>
+<tr class="odd"><td><a href="mod_include.html#ssiundefinedecho">SSIUndefinedEcho</a></td><td class="module"><a href="mod_include.html">mod_include</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">String displayed when an unset variable is echoed</td></tr>
+</table></div><div class="top"><a href="#page-header"><img src="../images/up.gif" alt="top" /></a></div><div class="section"><h2><a name="override-authconfig">AuthConfig</a></h2>
+    <p>
+      The following directives are allowed in .htaccess files when
+      <code>AllowOverride AuthConfig</code> is in effect. They give .htaccess
+      users control over the authentication and authorization methods that are
+      applied to their directory subtrees, including several related utility
+      directives for session handling and TLS settings.
+    </p>
+  <table class="qref"><tr><td><a href="mod_authn_anon.html#anonymous">Anonymous</a></td><td class="module"><a href="mod_authn_anon.html">mod_authn_anon</a></td></tr>
+<tr><td colspan="2" class="descr">Specifies userIDs that are allowed access without
+password verification</td></tr>
+<tr class="odd"><td><a href="mod_authn_anon.html#anonymous_logemail">Anonymous_LogEmail</a></td><td class="module"><a href="mod_authn_anon.html">mod_authn_anon</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Sets whether the password entered will be logged in the
+error log</td></tr>
+<tr><td><a href="mod_authn_anon.html#anonymous_mustgiveemail">Anonymous_MustGiveEmail</a></td><td class="module"><a href="mod_authn_anon.html">mod_authn_anon</a></td></tr>
+<tr><td colspan="2" class="descr">Specifies whether blank passwords are allowed</td></tr>
+<tr class="odd"><td><a href="mod_authn_anon.html#anonymous_nouserid">Anonymous_NoUserID</a></td><td class="module"><a href="mod_authn_anon.html">mod_authn_anon</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Sets whether the userID field may be empty</td></tr>
+<tr><td><a href="mod_authn_anon.html#anonymous_verifyemail">Anonymous_VerifyEmail</a></td><td class="module"><a href="mod_authn_anon.html">mod_authn_anon</a></td></tr>
+<tr><td colspan="2" class="descr">Sets whether to check the password field for a correctly
+formatted email address</td></tr>
+<tr class="odd"><td><a href="mod_auth_basic.html#authbasicauthoritative">AuthBasicAuthoritative</a></td><td class="module"><a href="mod_auth_basic.html">mod_auth_basic</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Sets whether authorization and authentication are passed to
+lower level modules</td></tr>
+<tr><td><a href="mod_auth_basic.html#authbasicfake">AuthBasicFake</a></td><td class="module"><a href="mod_auth_basic.html">mod_auth_basic</a></td></tr>
+<tr><td colspan="2" class="descr">Fake basic authentication using the given expressions for
+username and password</td></tr>
+<tr class="odd"><td><a href="mod_auth_basic.html#authbasicprovider">AuthBasicProvider</a></td><td class="module"><a href="mod_auth_basic.html">mod_auth_basic</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Sets the authentication provider(s) for this location</td></tr>
+<tr><td><a href="mod_auth_basic.html#authbasicusedigestalgorithm">AuthBasicUseDigestAlgorithm</a></td><td class="module"><a href="mod_auth_basic.html">mod_auth_basic</a></td></tr>
+<tr><td colspan="2" class="descr">Check passwords against the authentication providers as if
+Digest Authentication was in force instead of Basic Authentication.
+</td></tr>
+<tr class="odd"><td><a href="mod_authz_dbm.html#authdbmgroupfile">AuthDBMGroupFile</a></td><td class="module"><a href="mod_authz_dbm.html">mod_authz_dbm</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Sets the name of the database file containing the list
+of user groups for authorization</td></tr>
+<tr><td><a href="mod_authn_dbm.html#authdbmtype">AuthDBMType</a></td><td class="module"><a href="mod_authn_dbm.html">mod_authn_dbm</a></td></tr>
+<tr><td colspan="2" class="descr">Sets the type of database file that is used to
+store passwords</td></tr>
+<tr class="odd"><td><a href="mod_authn_dbm.html#authdbmuserfile">AuthDBMUserFile</a></td><td class="module"><a href="mod_authn_dbm.html">mod_authn_dbm</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Sets the name of a database file containing the list of users and
+passwords for authentication</td></tr>
+<tr><td><a href="mod_auth_digest.html#authdigestalgorithm">AuthDigestAlgorithm</a></td><td class="module"><a href="mod_auth_digest.html">mod_auth_digest</a></td></tr>
+<tr><td colspan="2" class="descr">Selects the algorithm used to calculate the challenge and
+response hashes in digest authentication</td></tr>
+<tr class="odd"><td><a href="mod_auth_digest.html#authdigestdomain">AuthDigestDomain</a></td><td class="module"><a href="mod_auth_digest.html">mod_auth_digest</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">URIs that are in the same protection space for digest
+authentication</td></tr>
+<tr><td><a href="mod_auth_digest.html#authdigestnoncelifetime">AuthDigestNonceLifetime</a></td><td class="module"><a href="mod_auth_digest.html">mod_auth_digest</a></td></tr>
+<tr><td colspan="2" class="descr">How long the server nonce is valid</td></tr>
+<tr class="odd"><td><a href="mod_auth_digest.html#authdigestprovider">AuthDigestProvider</a></td><td class="module"><a href="mod_auth_digest.html">mod_auth_digest</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Sets the authentication provider(s) for this location</td></tr>
+<tr><td><a href="mod_auth_digest.html#authdigestqop">AuthDigestQop</a></td><td class="module"><a href="mod_auth_digest.html">mod_auth_digest</a></td></tr>
+<tr><td colspan="2" class="descr">Determines the quality-of-protection to use in digest
+authentication</td></tr>
+<tr class="odd"><td><a href="mod_auth_form.html#authformauthoritative">AuthFormAuthoritative</a></td><td class="module"><a href="mod_auth_form.html">mod_auth_form</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Sets whether authorization and authentication are passed to
+lower level modules</td></tr>
+<tr><td><a href="mod_auth_form.html#authformprovider">AuthFormProvider</a></td><td class="module"><a href="mod_auth_form.html">mod_auth_form</a></td></tr>
+<tr><td colspan="2" class="descr">Sets the authentication provider(s) for this location</td></tr>
+<tr class="odd"><td><a href="mod_authz_groupfile.html#authgroupfile">AuthGroupFile</a></td><td class="module"><a href="mod_authz_groupfile.html">mod_authz_groupfile</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Sets the name of a text file containing the list
+of user groups for authorization</td></tr>
+<tr><td><a href="mod_authnz_ldap.html#authldapauthorizeprefix">AuthLDAPAuthorizePrefix</a></td><td class="module"><a href="mod_authnz_ldap.html">mod_authnz_ldap</a></td></tr>
+<tr><td colspan="2" class="descr">Specifies the prefix for environment variables set during
+authorization</td></tr>
+<tr class="odd"><td><a href="mod_authnz_ldap.html#authldapbindauthoritative">AuthLDAPBindAuthoritative</a></td><td class="module"><a href="mod_authnz_ldap.html">mod_authnz_ldap</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Determines if other authentication providers are used when a user can be mapped to a DN but the server cannot successfully bind with the user's credentials.</td></tr>
+<tr><td><a href="mod_authnz_ldap.html#authldapbinddn">AuthLDAPBindDN</a></td><td class="module"><a href="mod_authnz_ldap.html">mod_authnz_ldap</a></td></tr>
+<tr><td colspan="2" class="descr">Optional DN to use in binding to the LDAP server</td></tr>
+<tr class="odd"><td><a href="mod_authnz_ldap.html#authldapbindpassword">AuthLDAPBindPassword</a></td><td class="module"><a href="mod_authnz_ldap.html">mod_authnz_ldap</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Password used in conjunction with the bind DN</td></tr>
+<tr><td><a href="mod_authnz_ldap.html#authldapcompareasuser">AuthLDAPCompareAsUser</a></td><td class="module"><a href="mod_authnz_ldap.html">mod_authnz_ldap</a></td></tr>
+<tr><td colspan="2" class="descr">Use the authenticated user's credentials to perform authorization comparisons</td></tr>
+<tr class="odd"><td><a href="mod_authnz_ldap.html#authldapcomparednonserver">AuthLDAPCompareDNOnServer</a></td><td class="module"><a href="mod_authnz_ldap.html">mod_authnz_ldap</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Use the LDAP server to compare the DNs</td></tr>
+<tr><td><a href="mod_authnz_ldap.html#authldapdereferencealiases">AuthLDAPDereferenceAliases</a></td><td class="module"><a href="mod_authnz_ldap.html">mod_authnz_ldap</a></td></tr>
+<tr><td colspan="2" class="descr">When will the module de-reference aliases</td></tr>
+<tr class="odd"><td><a href="mod_authnz_ldap.html#authldapgroupattribute">AuthLDAPGroupAttribute</a></td><td class="module"><a href="mod_authnz_ldap.html">mod_authnz_ldap</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">LDAP attributes used to identify the user members of
+groups.</td></tr>
+<tr><td><a href="mod_authnz_ldap.html#authldapgroupattributeisdn">AuthLDAPGroupAttributeIsDN</a></td><td class="module"><a href="mod_authnz_ldap.html">mod_authnz_ldap</a></td></tr>
+<tr><td colspan="2" class="descr">Use the DN of the client username when checking for
+group membership</td></tr>
+<tr class="odd"><td><a href="mod_authnz_ldap.html#authldapinitialbindasuser">AuthLDAPInitialBindAsUser</a></td><td class="module"><a href="mod_authnz_ldap.html">mod_authnz_ldap</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Determines if the server does the initial DN lookup using the basic authentication users'
+own username, instead of anonymously or with hard-coded credentials for the server</td></tr>
+<tr><td><a href="mod_authnz_ldap.html#authldapinitialbindpattern">AuthLDAPInitialBindPattern</a></td><td class="module"><a href="mod_authnz_ldap.html">mod_authnz_ldap</a></td></tr>
+<tr><td colspan="2" class="descr">Specifies the transformation of the basic authentication username to be used when binding to the LDAP server
+to perform a DN lookup</td></tr>
+<tr class="odd"><td><a href="mod_authnz_ldap.html#authldapmaxsubgroupdepth">AuthLDAPMaxSubGroupDepth</a></td><td class="module"><a href="mod_authnz_ldap.html">mod_authnz_ldap</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Specifies the maximum sub-group nesting depth that will be
+evaluated before the user search is discontinued.</td></tr>
+<tr><td><a href="mod_authnz_ldap.html#authldapremoteuserattribute">AuthLDAPRemoteUserAttribute</a></td><td class="module"><a href="mod_authnz_ldap.html">mod_authnz_ldap</a></td></tr>
+<tr><td colspan="2" class="descr">Use the value of the attribute returned during the user
+query to set the REMOTE_USER environment variable</td></tr>
+<tr class="odd"><td><a href="mod_authnz_ldap.html#authldapremoteuserisdn">AuthLDAPRemoteUserIsDN</a></td><td class="module"><a href="mod_authnz_ldap.html">mod_authnz_ldap</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Use the DN of the client username to set the REMOTE_USER
+environment variable</td></tr>
+<tr><td><a href="mod_authnz_ldap.html#authldapsearchasuser">AuthLDAPSearchAsUser</a></td><td class="module"><a href="mod_authnz_ldap.html">mod_authnz_ldap</a></td></tr>
+<tr><td colspan="2" class="descr">Use the authenticated user's credentials to perform authorization searches</td></tr>
+<tr class="odd"><td><a href="mod_authnz_ldap.html#authldapsubgroupattribute">AuthLDAPSubGroupAttribute</a></td><td class="module"><a href="mod_authnz_ldap.html">mod_authnz_ldap</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Specifies the attribute labels, one value per
+directive line, used to distinguish the members of the current group that
+are groups.</td></tr>
+<tr><td><a href="mod_authnz_ldap.html#authldapsubgroupclass">AuthLDAPSubGroupClass</a></td><td class="module"><a href="mod_authnz_ldap.html">mod_authnz_ldap</a></td></tr>
+<tr><td colspan="2" class="descr">Specifies which LDAP objectClass values identify directory
+objects that are groups during sub-group processing.</td></tr>
+<tr class="odd"><td><a href="mod_authnz_ldap.html#authldapurl">AuthLDAPUrl</a></td><td class="module"><a href="mod_authnz_ldap.html">mod_authnz_ldap</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">URL specifying the LDAP search parameters</td></tr>
+<tr><td><a href="mod_authz_core.html#authmerging">AuthMerging</a></td><td class="module"><a href="mod_authz_core.html">mod_authz_core</a></td></tr>
+<tr><td colspan="2" class="descr">Controls the manner in which each configuration section's
+authorization logic is combined with that of preceding configuration
+sections.</td></tr>
+<tr class="odd"><td><a href="mod_authn_core.html#authname">AuthName</a></td><td class="module"><a href="mod_authn_core.html">mod_authn_core</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Authorization realm for use in HTTP
+authentication</td></tr>
+<tr><td><a href="mod_authn_socache.html#authncacheprovidefor">AuthnCacheProvideFor</a></td><td class="module"><a href="mod_authn_socache.html">mod_authn_socache</a></td></tr>
+<tr><td colspan="2" class="descr">Specify which authn provider(s) to cache for</td></tr>
+<tr class="odd"><td><a href="mod_authn_socache.html#authncachetimeout">AuthnCacheTimeout</a></td><td class="module"><a href="mod_authn_socache.html">mod_authn_socache</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Set a timeout for cache entries</td></tr>
+<tr><td><a href="mod_authn_core.html#authtype">AuthType</a></td><td class="module"><a href="mod_authn_core.html">mod_authn_core</a></td></tr>
+<tr><td colspan="2" class="descr">Type of user authentication</td></tr>
+<tr class="odd"><td><a href="mod_authn_file.html#authuserfile">AuthUserFile</a></td><td class="module"><a href="mod_authn_file.html">mod_authn_file</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Sets the name of a text file containing the list of users and
+passwords for authentication</td></tr>
+<tr><td><a href="mod_authz_dbm.html#authzdbmtype">AuthzDBMType</a></td><td class="module"><a href="mod_authz_dbm.html">mod_authz_dbm</a></td></tr>
+<tr><td colspan="2" class="descr">Sets the type of database file that is used to
+store list of user groups</td></tr>
+<tr class="odd"><td><a href="core.html#cgipassauth">CGIPassAuth</a></td><td class="module"><a href="core.html">core</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Enables passing HTTP authorization headers to scripts as CGI
+variables</td></tr>
+<tr><td><a href="mod_ldap.html#ldapreferralhoplimit">LDAPReferralHopLimit</a></td><td class="module"><a href="mod_ldap.html">mod_ldap</a></td></tr>
+<tr><td colspan="2" class="descr">The maximum number of referral hops to chase before terminating an LDAP query.</td></tr>
+<tr class="odd"><td><a href="mod_ldap.html#ldapreferrals">LDAPReferrals</a></td><td class="module"><a href="mod_ldap.html">mod_ldap</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Enable referral chasing during queries to the LDAP server.</td></tr>
+<tr><td><a href="core.html#limit"><Limit></a></td><td class="module"><a href="core.html">core</a></td></tr>
+<tr><td colspan="2" class="descr">Restrict enclosed access controls to only certain HTTP
+methods</td></tr>
+<tr class="odd"><td><a href="core.html#limitexcept"><LimitExcept></a></td><td class="module"><a href="core.html">core</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Restrict access controls to all HTTP methods
+except the named ones</td></tr>
+<tr><td><a href="mod_authz_core.html#require">Require</a></td><td class="module"><a href="mod_authz_core.html">mod_authz_core</a></td></tr>
+<tr><td colspan="2" class="descr">Tests whether an authenticated user is authorized by
+an authorization provider.</td></tr>
+<tr class="odd"><td><a href="mod_authz_core.html#requireall"><RequireAll></a></td><td class="module"><a href="mod_authz_core.html">mod_authz_core</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Enclose a group of authorization directives of which none
+must fail and at least one must succeed for the enclosing directive to
+succeed.</td></tr>
+<tr><td><a href="mod_authz_core.html#requireany"><RequireAny></a></td><td class="module"><a href="mod_authz_core.html">mod_authz_core</a></td></tr>
+<tr><td colspan="2" class="descr">Enclose a group of authorization directives of which one
+must succeed for the enclosing directive to succeed.</td></tr>
+<tr class="odd"><td><a href="mod_authz_core.html#requirenone"><RequireNone></a></td><td class="module"><a href="mod_authz_core.html">mod_authz_core</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Enclose a group of authorization directives of which none
+must succeed for the enclosing directive to not fail.</td></tr>
+<tr><td><a href="mod_access_compat.html#satisfy">Satisfy</a></td><td class="module"><a href="mod_access_compat.html">mod_access_compat</a></td></tr>
+<tr><td colspan="2" class="descr">Interaction between host-level access control and
+user authentication</td></tr>
+<tr class="odd"><td><a href="mod_session.html#session">Session</a></td><td class="module"><a href="mod_session.html">mod_session</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Enables a session for the current directory or location</td></tr>
+<tr><td><a href="mod_session.html#sessionenv">SessionEnv</a></td><td class="module"><a href="mod_session.html">mod_session</a></td></tr>
+<tr><td colspan="2" class="descr">Control whether the contents of the session are written to the
+<var>HTTP_SESSION</var> environment variable</td></tr>
+<tr class="odd"><td><a href="mod_session.html#sessionheader">SessionHeader</a></td><td class="module"><a href="mod_session.html">mod_session</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Import session updates from a given HTTP response header</td></tr>
+<tr><td><a href="mod_session.html#sessioninclude">SessionInclude</a></td><td class="module"><a href="mod_session.html">mod_session</a></td></tr>
+<tr><td colspan="2" class="descr">Define URL prefixes for which a session is valid</td></tr>
+<tr class="odd"><td><a href="mod_session.html#sessionmaxage">SessionMaxAge</a></td><td class="module"><a href="mod_session.html">mod_session</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Define a maximum age in seconds for a session</td></tr>
+<tr><td><a href="mod_ssl.html#sslciphersuite">SSLCipherSuite</a></td><td class="module"><a href="mod_ssl.html">mod_ssl</a></td></tr>
+<tr><td colspan="2" class="descr">Cipher Suite available for negotiation in SSL
+handshake</td></tr>
+<tr class="odd"><td><a href="mod_ssl.html#sslproxyciphersuite">SSLProxyCipherSuite</a></td><td class="module"><a href="mod_ssl.html">mod_ssl</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Cipher Suite available for negotiation in SSL
+proxy handshake</td></tr>
+<tr><td><a href="mod_ssl.html#sslrenegbuffersize">SSLRenegBufferSize</a></td><td class="module"><a href="mod_ssl.html">mod_ssl</a></td></tr>
+<tr><td colspan="2" class="descr">Set the size for the SSL renegotiation buffer</td></tr>
+<tr class="odd"><td><a href="mod_ssl.html#sslrequire">SSLRequire</a></td><td class="module"><a href="mod_ssl.html">mod_ssl</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Allow access only when an arbitrarily complex
+boolean expression is true</td></tr>
+<tr><td><a href="mod_ssl.html#sslrequiressl">SSLRequireSSL</a></td><td class="module"><a href="mod_ssl.html">mod_ssl</a></td></tr>
+<tr><td colspan="2" class="descr">Deny access when SSL is not used for the
+HTTP request</td></tr>
+<tr class="odd"><td><a href="mod_ssl.html#sslusername">SSLUserName</a></td><td class="module"><a href="mod_ssl.html">mod_ssl</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Variable name to determine user name</td></tr>
+<tr><td><a href="mod_ssl.html#sslverifyclient">SSLVerifyClient</a></td><td class="module"><a href="mod_ssl.html">mod_ssl</a></td></tr>
+<tr><td colspan="2" class="descr">Type of Client Certificate verification</td></tr>
+<tr class="odd"><td><a href="mod_ssl.html#sslverifydepth">SSLVerifyDepth</a></td><td class="module"><a href="mod_ssl.html">mod_ssl</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Maximum depth of CA Certificates in Client
+Certificate verification</td></tr>
+</table></div><div class="top"><a href="#page-header"><img src="../images/up.gif" alt="top" /></a></div><div class="section"><h2><a name="override-fileinfo">FileInfo</a></h2>
+    <p>
+      The following directives are allowed in .htaccess files when
+      <code>AllowOverride FileInfo</code> is in effect. They give .htaccess
+      users a wide range of control over the responses and metadata given by the
+      server.
+    </p>
+  <table class="qref"><tr><td><a href="core.html#acceptpathinfo">AcceptPathInfo</a></td><td class="module"><a href="core.html">core</a></td></tr>
+<tr><td colspan="2" class="descr">Resources accept trailing pathname information</td></tr>
+<tr class="odd"><td><a href="mod_actions.html#action">Action</a></td><td class="module"><a href="mod_actions.html">mod_actions</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Activates a CGI script for a particular handler or
+content-type</td></tr>
+<tr><td><a href="mod_mime.html#addcharset">AddCharset</a></td><td class="module"><a href="mod_mime.html">mod_mime</a></td></tr>
+<tr><td colspan="2" class="descr">Maps the given filename extensions to the specified content
+charset</td></tr>
+<tr class="odd"><td><a href="core.html#adddefaultcharset">AddDefaultCharset</a></td><td class="module"><a href="core.html">core</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Default charset parameter to be added when a response
+content-type is <code>text/plain</code> or <code>text/html</code></td></tr>
+<tr><td><a href="mod_mime.html#addencoding">AddEncoding</a></td><td class="module"><a href="mod_mime.html">mod_mime</a></td></tr>
+<tr><td colspan="2" class="descr">Maps the given filename extensions to the specified encoding
+type</td></tr>
+<tr class="odd"><td><a href="mod_mime.html#addhandler">AddHandler</a></td><td class="module"><a href="mod_mime.html">mod_mime</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Maps the filename extensions to the specified
+handler</td></tr>
+<tr><td><a href="mod_mime.html#addinputfilter">AddInputFilter</a></td><td class="module"><a href="mod_mime.html">mod_mime</a></td></tr>
+<tr><td colspan="2" class="descr">Maps filename extensions to the filters that will process
+client requests</td></tr>
+<tr class="odd"><td><a href="mod_mime.html#addlanguage">AddLanguage</a></td><td class="module"><a href="mod_mime.html">mod_mime</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Maps the given filename extension to the specified content
+language</td></tr>
+<tr><td><a href="mod_mime.html#addoutputfilter">AddOutputFilter</a></td><td class="module"><a href="mod_mime.html">mod_mime</a></td></tr>
+<tr><td colspan="2" class="descr">Maps filename extensions to the filters that will process
+responses from the server</td></tr>
+<tr class="odd"><td><a href="mod_filter.html#addoutputfilterbytype">AddOutputFilterByType</a></td><td class="module"><a href="mod_filter.html">mod_filter</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">assigns an output filter to a particular media-type</td></tr>
+<tr><td><a href="mod_mime.html#addtype">AddType</a></td><td class="module"><a href="mod_mime.html">mod_mime</a></td></tr>
+<tr><td colspan="2" class="descr">Maps the given filename extensions onto the specified content
+type</td></tr>
+<tr class="odd"><td><a href="mod_setenvif.html#browsermatch">BrowserMatch</a></td><td class="module"><a href="mod_setenvif.html">mod_setenvif</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Sets environment variables conditional on HTTP User-Agent
+</td></tr>
+<tr><td><a href="mod_setenvif.html#browsermatchnocase">BrowserMatchNoCase</a></td><td class="module"><a href="mod_setenvif.html">mod_setenvif</a></td></tr>
+<tr><td colspan="2" class="descr">Sets environment variables conditional on User-Agent without
+respect to case</td></tr>
+<tr class="odd"><td><a href="core.html#cgimapextension">CGIMapExtension</a></td><td class="module"><a href="core.html">core</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Technique for locating the interpreter for CGI
+scripts</td></tr>
+<tr><td><a href="core.html#cgivar">CGIVar</a></td><td class="module"><a href="core.html">core</a></td></tr>
+<tr><td colspan="2" class="descr">Controls how some CGI variables are set</td></tr>
+<tr class="odd"><td><a href="mod_charset_lite.html#charsetdefault">CharsetDefault</a></td><td class="module"><a href="mod_charset_lite.html">mod_charset_lite</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Charset to translate into</td></tr>
+<tr><td><a href="mod_charset_lite.html#charsetoptions">CharsetOptions</a></td><td class="module"><a href="mod_charset_lite.html">mod_charset_lite</a></td></tr>
+<tr><td colspan="2" class="descr">Configures charset translation behavior</td></tr>
+<tr class="odd"><td><a href="mod_charset_lite.html#charsetsourceenc">CharsetSourceEnc</a></td><td class="module"><a href="mod_charset_lite.html">mod_charset_lite</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Source charset of files</td></tr>
+<tr><td><a href="mod_usertrack.html#cookiedomain">CookieDomain</a></td><td class="module"><a href="mod_usertrack.html">mod_usertrack</a></td></tr>
+<tr><td colspan="2" class="descr">The domain to which the tracking cookie applies</td></tr>
+<tr class="odd"><td><a href="mod_usertrack.html#cookieexpires">CookieExpires</a></td><td class="module"><a href="mod_usertrack.html">mod_usertrack</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Expiry time for the tracking cookie</td></tr>
+<tr><td><a href="mod_usertrack.html#cookiename">CookieName</a></td><td class="module"><a href="mod_usertrack.html">mod_usertrack</a></td></tr>
+<tr><td colspan="2" class="descr">Name of the tracking cookie</td></tr>
+<tr class="odd"><td><a href="mod_usertrack.html#cookiestyle">CookieStyle</a></td><td class="module"><a href="mod_usertrack.html">mod_usertrack</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Format of the cookie header field</td></tr>
+<tr><td><a href="mod_usertrack.html#cookietracking">CookieTracking</a></td><td class="module"><a href="mod_usertrack.html">mod_usertrack</a></td></tr>
+<tr><td colspan="2" class="descr">Enables tracking cookie</td></tr>
+<tr class="odd"><td><a href="mod_mime.html#defaultlanguage">DefaultLanguage</a></td><td class="module"><a href="mod_mime.html">mod_mime</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Defines a default language-tag to be sent in the Content-Language
+header field for all resources in the current context that have not been
+assigned a language-tag by some other means.</td></tr>
+<tr><td><a href="core.html#defaulttype">DefaultType</a></td><td class="module"><a href="core.html">core</a></td></tr>
+<tr><td colspan="2" class="descr">This directive has no effect other than to emit warnings
+if the value is not <code>none</code>. In prior versions, DefaultType
+would specify a default media type to assign to response content for
+which no other media type configuration could be found.
+</td></tr>
+<tr class="odd"><td><a href="core.html#enablemmap">EnableMMAP</a></td><td class="module"><a href="core.html">core</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Use memory-mapping to read files during delivery</td></tr>
+<tr><td><a href="core.html#enablesendfile">EnableSendfile</a></td><td class="module"><a href="core.html">core</a></td></tr>
+<tr><td colspan="2" class="descr">Use the kernel sendfile support to deliver files to the client</td></tr>
+<tr class="odd"><td><a href="core.html#errordocument">ErrorDocument</a></td><td class="module"><a href="core.html">core</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">What the server will return to the client
+in case of an error</td></tr>
+<tr><td><a href="core.html#fileetag">FileETag</a></td><td class="module"><a href="core.html">core</a></td></tr>
+<tr><td colspan="2" class="descr">File attributes used to create the ETag
+HTTP response header for static files</td></tr>
+<tr class="odd"><td><a href="mod_negotiation.html#forcelanguagepriority">ForceLanguagePriority</a></td><td class="module"><a href="mod_negotiation.html">mod_negotiation</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Action to take if a single acceptable document is not
+found</td></tr>
+<tr><td><a href="core.html#forcetype">ForceType</a></td><td class="module"><a href="core.html">core</a></td></tr>
+<tr><td colspan="2" class="descr">Forces all matching files to be served with the specified
+media type in the HTTP Content-Type header field</td></tr>
+<tr class="odd"><td><a href="mod_headers.html#header">Header</a></td><td class="module"><a href="mod_headers.html">mod_headers</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Configure HTTP response headers</td></tr>
+<tr><td><a href="mod_isapi.html#isapiappendlogtoerrors">ISAPIAppendLogToErrors</a></td><td class="module"><a href="mod_isapi.html">mod_isapi</a></td></tr>
+<tr><td colspan="2" class="descr">Record <code>HSE_APPEND_LOG_PARAMETER</code> requests from
+ISAPI extensions to the error log</td></tr>
+<tr class="odd"><td><a href="mod_isapi.html#isapiappendlogtoquery">ISAPIAppendLogToQuery</a></td><td class="module"><a href="mod_isapi.html">mod_isapi</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Record <code>HSE_APPEND_LOG_PARAMETER</code> requests from
+ISAPI extensions to the query field</td></tr>
+<tr><td><a href="mod_isapi.html#isapifakeasync">ISAPIFakeAsync</a></td><td class="module"><a href="mod_isapi.html">mod_isapi</a></td></tr>
+<tr><td colspan="2" class="descr">Fake asynchronous support for ISAPI callbacks</td></tr>
+<tr class="odd"><td><a href="mod_isapi.html#isapilognotsupported">ISAPILogNotSupported</a></td><td class="module"><a href="mod_isapi.html">mod_isapi</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Log unsupported feature requests from ISAPI
+extensions</td></tr>
+<tr><td><a href="mod_isapi.html#isapireadaheadbuffer">ISAPIReadAheadBuffer</a></td><td class="module"><a href="mod_isapi.html">mod_isapi</a></td></tr>
+<tr><td colspan="2" class="descr">Size of the Read Ahead Buffer sent to ISAPI
+extensions</td></tr>
+<tr class="odd"><td><a href="mod_negotiation.html#languagepriority">LanguagePriority</a></td><td class="module"><a href="mod_negotiation.html">mod_negotiation</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">The precedence of language variants for cases where
+the client does not express a preference</td></tr>
+<tr><td><a href="mod_mime.html#multiviewsmatch">MultiviewsMatch</a></td><td class="module"><a href="mod_mime.html">mod_mime</a></td></tr>
+<tr><td colspan="2" class="descr">The types of files that will be included when searching for
+a matching file with MultiViews</td></tr>
+<tr class="odd"><td><a href="mod_env.html#passenv">PassEnv</a></td><td class="module"><a href="mod_env.html">mod_env</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Passes environment variables from the shell</td></tr>
+<tr><td><a href="core.html#qualifyredirecturl">QualifyRedirectURL</a></td><td class="module"><a href="core.html">core</a></td></tr>
+<tr><td colspan="2" class="descr">Controls whether the REDIRECT_URL environment variable is
+             fully qualified</td></tr>
+<tr class="odd"><td><a href="mod_alias.html#redirect">Redirect</a></td><td class="module"><a href="mod_alias.html">mod_alias</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Sends an external redirect asking the client to fetch
+a different URL</td></tr>
+<tr><td><a href="mod_alias.html#redirectmatch">RedirectMatch</a></td><td class="module"><a href="mod_alias.html">mod_alias</a></td></tr>
+<tr><td colspan="2" class="descr">Sends an external redirect based on a regular expression match
+of the current URL</td></tr>
+<tr class="odd"><td><a href="mod_alias.html#redirectpermanent">RedirectPermanent</a></td><td class="module"><a href="mod_alias.html">mod_alias</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Sends an external permanent redirect asking the client to fetch
+a different URL</td></tr>
+<tr><td><a href="mod_alias.html#redirecttemp">RedirectTemp</a></td><td class="module"><a href="mod_alias.html">mod_alias</a></td></tr>
+<tr><td colspan="2" class="descr">Sends an external temporary redirect asking the client to fetch
+a different URL</td></tr>
+<tr class="odd"><td><a href="mod_mime.html#removecharset">RemoveCharset</a></td><td class="module"><a href="mod_mime.html">mod_mime</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Removes any character set associations for a set of file
+extensions</td></tr>
+<tr><td><a href="mod_mime.html#removeencoding">RemoveEncoding</a></td><td class="module"><a href="mod_mime.html">mod_mime</a></td></tr>
+<tr><td colspan="2" class="descr">Removes any content encoding associations for a set of file
+extensions</td></tr>
+<tr class="odd"><td><a href="mod_mime.html#removehandler">RemoveHandler</a></td><td class="module"><a href="mod_mime.html">mod_mime</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Removes any handler associations for a set of file
+extensions</td></tr>
+<tr><td><a href="mod_mime.html#removeinputfilter">RemoveInputFilter</a></td><td class="module"><a href="mod_mime.html">mod_mime</a></td></tr>
+<tr><td colspan="2" class="descr">Removes any input filter associations for a set of file
+extensions</td></tr>
+<tr class="odd"><td><a href="mod_mime.html#removelanguage">RemoveLanguage</a></td><td class="module"><a href="mod_mime.html">mod_mime</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Removes any language associations for a set of file
+extensions</td></tr>
+<tr><td><a href="mod_mime.html#removeoutputfilter">RemoveOutputFilter</a></td><td class="module"><a href="mod_mime.html">mod_mime</a></td></tr>
+<tr><td colspan="2" class="descr">Removes any output filter associations for a set of file
+extensions</td></tr>
+<tr class="odd"><td><a href="mod_mime.html#removetype">RemoveType</a></td><td class="module"><a href="mod_mime.html">mod_mime</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Removes any content type associations for a set of file
+extensions</td></tr>
+<tr><td><a href="mod_headers.html#requestheader">RequestHeader</a></td><td class="module"><a href="mod_headers.html">mod_headers</a></td></tr>
+<tr><td colspan="2" class="descr">Configure HTTP request headers</td></tr>
+<tr class="odd"><td><a href="mod_rewrite.html#rewritebase">RewriteBase</a></td><td class="module"><a href="mod_rewrite.html">mod_rewrite</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Sets the base URL for per-directory rewrites</td></tr>
+<tr><td><a href="mod_rewrite.html#rewritecond">RewriteCond</a></td><td class="module"><a href="mod_rewrite.html">mod_rewrite</a></td></tr>
+<tr><td colspan="2" class="descr">Defines a condition under which rewriting will take place
+</td></tr>
+<tr class="odd"><td><a href="mod_rewrite.html#rewriteengine">RewriteEngine</a></td><td class="module"><a href="mod_rewrite.html">mod_rewrite</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Enables or disables runtime rewriting engine</td></tr>
+<tr><td><a href="mod_rewrite.html#rewriteoptions">RewriteOptions</a></td><td class="module"><a href="mod_rewrite.html">mod_rewrite</a></td></tr>
+<tr><td colspan="2" class="descr">Sets some special options for the rewrite engine</td></tr>
+<tr class="odd"><td><a href="mod_rewrite.html#rewriterule">RewriteRule</a></td><td class="module"><a href="mod_rewrite.html">mod_rewrite</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Defines rules for the rewriting engine</td></tr>
+<tr><td><a href="core.html#scriptinterpretersource">ScriptInterpreterSource</a></td><td class="module"><a href="core.html">core</a></td></tr>
+<tr><td colspan="2" class="descr">Technique for locating the interpreter for CGI
+scripts</td></tr>
+<tr class="odd"><td><a href="mod_env.html#setenv">SetEnv</a></td><td class="module"><a href="mod_env.html">mod_env</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Sets environment variables</td></tr>
+<tr><td><a href="mod_setenvif.html#setenvif">SetEnvIf</a></td><td class="module"><a href="mod_setenvif.html">mod_setenvif</a></td></tr>
+<tr><td colspan="2" class="descr">Sets environment variables based on attributes of the request
+</td></tr>
+<tr class="odd"><td><a href="mod_setenvif.html#setenvifexpr">SetEnvIfExpr</a></td><td class="module"><a href="mod_setenvif.html">mod_setenvif</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Sets environment variables based on an ap_expr expression</td></tr>
+<tr><td><a href="mod_setenvif.html#setenvifnocase">SetEnvIfNoCase</a></td><td class="module"><a href="mod_setenvif.html">mod_setenvif</a></td></tr>
+<tr><td colspan="2" class="descr">Sets environment variables based on attributes of the request
+without respect to case</td></tr>
+<tr class="odd"><td><a href="core.html#sethandler">SetHandler</a></td><td class="module"><a href="core.html">core</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Forces all matching files to be processed by a
+handler</td></tr>
+<tr><td><a href="core.html#setinputfilter">SetInputFilter</a></td><td class="module"><a href="core.html">core</a></td></tr>
+<tr><td colspan="2" class="descr">Sets the filters that will process client requests and POST
+input</td></tr>
+<tr class="odd"><td><a href="core.html#setoutputfilter">SetOutputFilter</a></td><td class="module"><a href="core.html">core</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Sets the filters that will process responses from the
+server</td></tr>
+<tr><td><a href="mod_substitute.html#substitute">Substitute</a></td><td class="module"><a href="mod_substitute.html">mod_substitute</a></td></tr>
+<tr><td colspan="2" class="descr">Pattern to filter the response content</td></tr>
+<tr class="odd"><td><a href="mod_substitute.html#substituteinheritbefore">SubstituteInheritBefore</a></td><td class="module"><a href="mod_substitute.html">mod_substitute</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Change the merge order of inherited patterns</td></tr>
+<tr><td><a href="mod_substitute.html#substitutemaxlinelength">SubstituteMaxLineLength</a></td><td class="module"><a href="mod_substitute.html">mod_substitute</a></td></tr>
+<tr><td colspan="2" class="descr">Set the maximum line size</td></tr>
+<tr class="odd"><td><a href="mod_env.html#unsetenv">UnsetEnv</a></td><td class="module"><a href="mod_env.html">mod_env</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Removes variables from the environment</td></tr>
+</table></div><div class="top"><a href="#page-header"><img src="../images/up.gif" alt="top" /></a></div><div class="section"><h2><a name="override-indexes">Indexes</a></h2>
+    <p>
+      The following directives are allowed in .htaccess files when
+      <code>AllowOverride Indexes</code> is in effect. They allow .htaccess
+      users to control aspects of the directory index pages provided by the
+      server, including autoindex generation.
+    </p>
+  <table class="qref"><tr><td><a href="mod_autoindex.html#addalt">AddAlt</a></td><td class="module"><a href="mod_autoindex.html">mod_autoindex</a></td></tr>
+<tr><td colspan="2" class="descr">Alternate text to display for a file, instead of an
+icon selected by filename</td></tr>
+<tr class="odd"><td><a href="mod_autoindex.html#addaltbyencoding">AddAltByEncoding</a></td><td class="module"><a href="mod_autoindex.html">mod_autoindex</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Alternate text to display for a file instead of an icon
+selected by MIME-encoding</td></tr>
+<tr><td><a href="mod_autoindex.html#addaltbytype">AddAltByType</a></td><td class="module"><a href="mod_autoindex.html">mod_autoindex</a></td></tr>
+<tr><td colspan="2" class="descr">Alternate text to display for a file, instead of an
+icon selected by MIME content-type</td></tr>
+<tr class="odd"><td><a href="mod_autoindex.html#adddescription">AddDescription</a></td><td class="module"><a href="mod_autoindex.html">mod_autoindex</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Description to display for a file</td></tr>
+<tr><td><a href="mod_autoindex.html#addicon">AddIcon</a></td><td class="module"><a href="mod_autoindex.html">mod_autoindex</a></td></tr>
+<tr><td colspan="2" class="descr">Icon to display for a file selected by name</td></tr>
+<tr class="odd"><td><a href="mod_autoindex.html#addiconbyencoding">AddIconByEncoding</a></td><td class="module"><a href="mod_autoindex.html">mod_autoindex</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Icon to display next to files selected by MIME
+content-encoding</td></tr>
+<tr><td><a href="mod_autoindex.html#addiconbytype">AddIconByType</a></td><td class="module"><a href="mod_autoindex.html">mod_autoindex</a></td></tr>
+<tr><td colspan="2" class="descr">Icon to display next to files selected by MIME
+content-type</td></tr>
+<tr class="odd"><td><a href="mod_autoindex.html#defaulticon">DefaultIcon</a></td><td class="module"><a href="mod_autoindex.html">mod_autoindex</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Icon to display for files when no specific icon is
+configured</td></tr>
+<tr><td><a href="mod_dir.html#directorycheckhandler">DirectoryCheckHandler</a></td><td class="module"><a href="mod_dir.html">mod_dir</a></td></tr>
+<tr><td colspan="2" class="descr">Toggle how this module responds when another handler is configured</td></tr>
+<tr class="odd"><td><a href="mod_dir.html#directoryindex">DirectoryIndex</a></td><td class="module"><a href="mod_dir.html">mod_dir</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">List of resources to look for when the client requests
+a directory</td></tr>
+<tr><td><a href="mod_dir.html#directoryindexredirect">DirectoryIndexRedirect</a></td><td class="module"><a href="mod_dir.html">mod_dir</a></td></tr>
+<tr><td colspan="2" class="descr">Configures an external redirect for directory indexes.
+</td></tr>
+<tr class="odd"><td><a href="mod_dir.html#directoryslash">DirectorySlash</a></td><td class="module"><a href="mod_dir.html">mod_dir</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Toggle trailing slash redirects on or off</td></tr>
+<tr><td><a href="mod_expires.html#expiresactive">ExpiresActive</a></td><td class="module"><a href="mod_expires.html">mod_expires</a></td></tr>
+<tr><td colspan="2" class="descr">Enables generation of <code>Expires</code>
+headers</td></tr>
+<tr class="odd"><td><a href="mod_expires.html#expiresbytype">ExpiresByType</a></td><td class="module"><a href="mod_expires.html">mod_expires</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Value of the <code>Expires</code> header configured
+by MIME type</td></tr>
+<tr><td><a href="mod_expires.html#expiresdefault">ExpiresDefault</a></td><td class="module"><a href="mod_expires.html">mod_expires</a></td></tr>
+<tr><td colspan="2" class="descr">Default algorithm for calculating expiration time</td></tr>
+<tr class="odd"><td><a href="mod_dir.html#fallbackresource">FallbackResource</a></td><td class="module"><a href="mod_dir.html">mod_dir</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Define a default URL for requests that don't map to a file</td></tr>
+<tr><td><a href="mod_autoindex.html#headername">HeaderName</a></td><td class="module"><a href="mod_autoindex.html">mod_autoindex</a></td></tr>
+<tr><td colspan="2" class="descr">Name of the file that will be inserted at the top
+of the index listing</td></tr>
+<tr class="odd"><td><a href="mod_imagemap.html#imapbase">ImapBase</a></td><td class="module"><a href="mod_imagemap.html">mod_imagemap</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Default <code>base</code> for imagemap files</td></tr>
+<tr><td><a href="mod_imagemap.html#imapdefault">ImapDefault</a></td><td class="module"><a href="mod_imagemap.html">mod_imagemap</a></td></tr>
+<tr><td colspan="2" class="descr">Default action when an imagemap is called with coordinates
+that are not explicitly mapped</td></tr>
+<tr class="odd"><td><a href="mod_imagemap.html#imapmenu">ImapMenu</a></td><td class="module"><a href="mod_imagemap.html">mod_imagemap</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Action if no coordinates are given when calling
+an imagemap</td></tr>
+<tr><td><a href="mod_autoindex.html#indexheadinsert">IndexHeadInsert</a></td><td class="module"><a href="mod_autoindex.html">mod_autoindex</a></td></tr>
+<tr><td colspan="2" class="descr">Inserts text in the HEAD section of an index page.</td></tr>
+<tr class="odd"><td><a href="mod_autoindex.html#indexignore">IndexIgnore</a></td><td class="module"><a href="mod_autoindex.html">mod_autoindex</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Adds to the list of files to hide when listing
+a directory</td></tr>
+<tr><td><a href="mod_autoindex.html#indexignorereset">IndexIgnoreReset</a></td><td class="module"><a href="mod_autoindex.html">mod_autoindex</a></td></tr>
+<tr><td colspan="2" class="descr">Empties the list of files to hide when listing
+a directory</td></tr>
+<tr class="odd"><td><a href="mod_autoindex.html#indexoptions">IndexOptions</a></td><td class="module"><a href="mod_autoindex.html">mod_autoindex</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Various configuration settings for directory
+indexing</td></tr>
+<tr><td><a href="mod_autoindex.html#indexorderdefault">IndexOrderDefault</a></td><td class="module"><a href="mod_autoindex.html">mod_autoindex</a></td></tr>
+<tr><td colspan="2" class="descr">Sets the default ordering of the directory index</td></tr>
+<tr class="odd"><td><a href="mod_autoindex.html#indexstylesheet">IndexStyleSheet</a></td><td class="module"><a href="mod_autoindex.html">mod_autoindex</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Adds a CSS stylesheet to the directory index</td></tr>
+<tr><td><a href="mod_cern_meta.html#metadir">MetaDir</a></td><td class="module"><a href="mod_cern_meta.html">mod_cern_meta</a></td></tr>
+<tr><td colspan="2" class="descr">Name of the directory to find CERN-style meta information
+files</td></tr>
+<tr class="odd"><td><a href="mod_cern_meta.html#metafiles">MetaFiles</a></td><td class="module"><a href="mod_cern_meta.html">mod_cern_meta</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Activates CERN meta-file processing</td></tr>
+<tr><td><a href="mod_cern_meta.html#metasuffix">MetaSuffix</a></td><td class="module"><a href="mod_cern_meta.html">mod_cern_meta</a></td></tr>
+<tr><td colspan="2" class="descr">File name suffix for the file containing CERN-style
+meta information</td></tr>
+<tr class="odd"><td><a href="mod_autoindex.html#readmename">ReadmeName</a></td><td class="module"><a href="mod_autoindex.html">mod_autoindex</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Name of the file that will be inserted at the end
+of the index listing</td></tr>
+</table></div><div class="top"><a href="#page-header"><img src="../images/up.gif" alt="top" /></a></div><div class="section"><h2><a name="override-limit">Limit</a></h2>
+    <p>
+      The following directives are allowed in .htaccess files when
+      <code>AllowOverride Limit</code> is in effect. This extremely narrow
+      override type mostly allows the use of the legacy authorization directives
+      provided by <code class="module"><a href="../mod/mod_access_compat.html">mod_access_compat</a></code>.
+    </p>
+  <table class="qref"><tr><td><a href="mod_access_compat.html#allow">Allow</a></td><td class="module"><a href="mod_access_compat.html">mod_access_compat</a></td></tr>
+<tr><td colspan="2" class="descr">Controls which hosts can access an area of the
+server</td></tr>
+<tr class="odd"><td><a href="mod_access_compat.html#deny">Deny</a></td><td class="module"><a href="mod_access_compat.html">mod_access_compat</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Controls which hosts are denied access to the
+server</td></tr>
+<tr><td><a href="core.html#limit"><Limit></a></td><td class="module"><a href="core.html">core</a></td></tr>
+<tr><td colspan="2" class="descr">Restrict enclosed access controls to only certain HTTP
+methods</td></tr>
+<tr class="odd"><td><a href="core.html#limitexcept"><LimitExcept></a></td><td class="module"><a href="core.html">core</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Restrict access controls to all HTTP methods
+except the named ones</td></tr>
+<tr><td><a href="mod_access_compat.html#order">Order</a></td><td class="module"><a href="mod_access_compat.html">mod_access_compat</a></td></tr>
+<tr><td colspan="2" class="descr">Controls the default access state and the order in which
+<code class="directive">Allow</code> and <code class="directive">Deny</code> are
+evaluated.</td></tr>
+</table></div><div class="top"><a href="#page-header"><img src="../images/up.gif" alt="top" /></a></div><div class="section"><h2><a name="override-none">none</a></h2>
+    <p><em>
+    [This section has no description. It's possible that the documentation is
+    incomplete, or that the directives here have an incorrect or misspelled
+    Override type. Please consider reporting this in the
+    <a href="#comments_section">comments section</a>.]
+    </em></p>
+  <table class="qref"><tr><td><a href="mod_logio.html#logiotrackttfb">LogIOTrackTTFB</a></td><td class="module"><a href="mod_logio.html">mod_logio</a></td></tr>
+<tr><td colspan="2" class="descr">Enable tracking of time to first byte (TTFB)</td></tr>
+</table></div><div class="top"><a href="#page-header"><img src="../images/up.gif" alt="top" /></a></div><div class="section"><h2><a name="override-none">None</a></h2>
+    <p><em>
+    [This section has no description. It's possible that the documentation is
+    incomplete, or that the directives here have an incorrect or misspelled
+    Override type. Please consider reporting this in the
+    <a href="#comments_section">comments section</a>.]
+    </em></p>
+  <table class="qref"><tr><td><a href="mod_authn_socache.html#authncacheenable">AuthnCacheEnable</a></td><td class="module"><a href="mod_authn_socache.html">mod_authn_socache</a></td></tr>
+<tr><td colspan="2" class="descr">Enable Authn caching configured anywhere</td></tr>
+<tr class="odd"><td><a href="mod_authn_socache.html#authncachesocache">AuthnCacheSOCache</a></td><td class="module"><a href="mod_authn_socache.html">mod_authn_socache</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Select socache backend provider to use</td></tr>
+</table></div><div class="top"><a href="#page-header"><img src="../images/up.gif" alt="top" /></a></div><div class="section"><h2><a name="override-not applicable">Not applicable</a></h2>
+    <p><em>
+    [This section has no description. It's possible that the documentation is
+    incomplete, or that the directives here have an incorrect or misspelled
+    Override type. Please consider reporting this in the
+    <a href="#comments_section">comments section</a>.]
+    </em></p>
+  <table class="qref"><tr><td><a href="mod_ssl.html#sslproxymachinecertificatechainfile">SSLProxyMachineCertificateChainFile</a></td><td class="module"><a href="mod_ssl.html">mod_ssl</a></td></tr>
+<tr><td colspan="2" class="descr">File of concatenated PEM-encoded CA certificates to be used by the proxy for choosing a certificate</td></tr>
+<tr class="odd"><td><a href="mod_ssl.html#sslproxymachinecertificatefile">SSLProxyMachineCertificateFile</a></td><td class="module"><a href="mod_ssl.html">mod_ssl</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">File of concatenated PEM-encoded client certificates and keys to be used by the proxy</td></tr>
+<tr><td><a href="mod_ssl.html#sslproxymachinecertificatepath">SSLProxyMachineCertificatePath</a></td><td class="module"><a href="mod_ssl.html">mod_ssl</a></td></tr>
+<tr><td colspan="2" class="descr">Directory of PEM-encoded client certificates and keys to be used by the proxy</td></tr>
+</table></div><div class="top"><a href="#page-header"><img src="../images/up.gif" alt="top" /></a></div><div class="section"><h2><a name="override-options">Options</a></h2>
+    <p>
+      The following directives are allowed in .htaccess files when
+      <code>AllowOverride Options</code> is in effect. They give .htaccess
+      users access to <code>Options</code> and similar directives, as well as
+      directives that control the filter chain.
+    </p>
+  <table class="qref"><tr><td><a href="mod_speling.html#checkcaseonly">CheckCaseOnly</a></td><td class="module"><a href="mod_speling.html">mod_speling</a></td></tr>
+<tr><td colspan="2" class="descr">Limits the action of the speling module to case corrections</td></tr>
+<tr class="odd"><td><a href="mod_speling.html#checkspelling">CheckSpelling</a></td><td class="module"><a href="mod_speling.html">mod_speling</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Enables the spelling
+module</td></tr>
+<tr><td><a href="core.html#contentdigest">ContentDigest</a></td><td class="module"><a href="core.html">core</a></td></tr>
+<tr><td colspan="2" class="descr">Enables the generation of <code>Content-MD5</code> HTTP Response
+headers</td></tr>
+<tr class="odd"><td><a href="mod_filter.html#filterchain">FilterChain</a></td><td class="module"><a href="mod_filter.html">mod_filter</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Configure the filter chain</td></tr>
+<tr><td><a href="mod_filter.html#filterdeclare">FilterDeclare</a></td><td class="module"><a href="mod_filter.html">mod_filter</a></td></tr>
+<tr><td colspan="2" class="descr">Declare a smart filter</td></tr>
+<tr class="odd"><td><a href="mod_filter.html#filterprotocol">FilterProtocol</a></td><td class="module"><a href="mod_filter.html">mod_filter</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Deal with correct HTTP protocol handling</td></tr>
+<tr><td><a href="mod_filter.html#filterprovider">FilterProvider</a></td><td class="module"><a href="mod_filter.html">mod_filter</a></td></tr>
+<tr><td colspan="2" class="descr">Register a content filter</td></tr>
+<tr class="odd"><td><a href="core.html#options">Options</a></td><td class="module"><a href="core.html">core</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Configures what features are available in a particular
+directory</td></tr>
+<tr><td><a href="mod_reflector.html#reflectorheader">ReflectorHeader</a></td><td class="module"><a href="mod_reflector.html">mod_reflector</a></td></tr>
+<tr><td colspan="2" class="descr">Reflect an input header to the output headers</td></tr>
+<tr class="odd"><td><a href="mod_ssl.html#ssloptions">SSLOptions</a></td><td class="module"><a href="mod_ssl.html">mod_ssl</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Configure various SSL engine run-time options</td></tr>
+<tr><td><a href="mod_ssl.html#sslproxyprotocol">SSLProxyProtocol</a></td><td class="module"><a href="mod_ssl.html">mod_ssl</a></td></tr>
+<tr><td colspan="2" class="descr">Configure usable SSL protocol flavors for proxy usage</td></tr>
+<tr class="odd"><td><a href="mod_include.html#xbithack">XBitHack</a></td><td class="module"><a href="mod_include.html">mod_include</a></td></tr>
+<tr class="odd"><td colspan="2" class="descr">Parse SSI directives in files with the execute bit
+set</td></tr>
+</table></div></div></div><div class="bottomlang">
+<p><span>Available Languages: </span><a href="../en/mod/overrides.html" title="English"> en </a></p>
+</div><div class="top"><a href="#page-header"><img src="../images/up.gif" alt="top" /></a></div><div class="section"><h2><a id="comments_section" name="comments_section">Comments</a></h2><div class="warning"><strong>Notice:</strong><br />This is not a Q&A section. Comments placed here should be pointed towards suggestions on improving the documentation or server, and may be removed again by our moderators if they are either implemented or considered invalid/off-topic. Questions on ho [...]
+<script type="text/javascript"><!--//--><![CDATA[//><!--
+var comments_shortname = 'httpd';
+var comments_identifier = 'http://httpd.apache.org/docs/2.4/mod/overrides.html';
+(function(w, d) {
+    if (w.location.hostname.toLowerCase() == "httpd.apache.org") {
+        d.write('<div id="comments_thread"><\/div>');
+        var s = d.createElement('script');
+        s.type = 'text/javascript';
+        s.async = true;
+        s.src = 'https://comments.apache.org/show_comments.lua?site=' + comments_shortname + '&page=' + comments_identifier;
+        (d.getElementsByTagName('head')[0] || d.getElementsByTagName('body')[0]).appendChild(s);
+    }
+    else { 
+        d.write('<div id="comments_thread">Comments are disabled for this page at the moment.<\/div>');
+    }
+})(window, document);
+//--><!]]></script></div><div id="footer">
+<p class="apache">Copyright 2017 The Apache Software Foundation.<br />Licensed under the <a href="http://www.apache.org/licenses/LICENSE-2.0">Apache License, Version 2.0</a>.</p>
+<p class="menu"><a href="../mod/">Modules</a> | <a href="../mod/directives.html">Directives</a> | <a href="http://wiki.apache.org/httpd/FAQ">FAQ</a> | <a href="../glossary.html">Glossary</a> | <a href="../sitemap.html">Sitemap</a></p></div><script type="text/javascript"><!--//--><![CDATA[//><!--
+if (typeof(prettyPrint) !== 'undefined') {
+    prettyPrint();
+}
+//--><!]]></script>
+</body></html>
\ No newline at end of file
diff --git a/docs/manual/mod/quickreference.html.en b/docs/manual/mod/quickreference.html.en
index 25fba20..db73fb4 100644
--- a/docs/manual/mod/quickreference.html.en
+++ b/docs/manual/mod/quickreference.html.en
@@ -434,7 +434,7 @@ after a crash</td></tr>
 <tr><td><a href="core.html#error">Error <var>message</var></a></td><td></td><td>svdh</td><td>C</td></tr><tr><td class="descr" colspan="4">Abort configuration parsing with a custom error message</td></tr>
 <tr class="odd"><td><a href="core.html#errordocument">ErrorDocument <var>error-code</var> <var>document</var></a></td><td></td><td>svdh</td><td>C</td></tr><tr class="odd"><td class="descr" colspan="4">What the server will return to the client
 in case of an error</td></tr>
-<tr><td><a href="core.html#errorlog"> ErrorLog <var>file-path</var>|syslog[:<var>facility</var>]</a></td><td> logs/error_log (Uni +</td><td>sv</td><td>C</td></tr><tr><td class="descr" colspan="4">Location where the server will log errors</td></tr>
+<tr><td><a href="core.html#errorlog"> ErrorLog <var>file-path</var>|syslog[:[<var>facility</var>][:<var>tag</var>]]</a></td><td> logs/error_log (Uni +</td><td>sv</td><td>C</td></tr><tr><td class="descr" colspan="4">Location where the server will log errors</td></tr>
 <tr class="odd"><td><a href="core.html#errorlogformat"> ErrorLogFormat [connection|request] <var>format</var></a></td><td></td><td>sv</td><td>C</td></tr><tr class="odd"><td class="descr" colspan="4">Format specification for error log entries</td></tr>
 <tr><td><a href="mod_example_hooks.html#example">Example</a></td><td></td><td>svdh</td><td>X</td></tr><tr><td class="descr" colspan="4">Demonstration directive to illustrate the Apache module
 API</td></tr>
diff --git a/docs/manual/mod/quickreference.html.fr b/docs/manual/mod/quickreference.html.fr
index 8da4955..4168f48 100644
--- a/docs/manual/mod/quickreference.html.fr
+++ b/docs/manual/mod/quickreference.html.fr
@@ -539,7 +539,7 @@ fichiers aux clients</td></tr>
 d'erreur personnalis�</td></tr>
 <tr class="odd"><td><a href="core.html#errordocument">ErrorDocument <var>code erreur</var> <var>document</var></a></td><td></td><td>svdh</td><td>C</td></tr><tr class="odd"><td class="descr" colspan="4">Document que le serveur renvoie au client en cas
 d'erreur</td></tr>
-<tr><td><a href="core.html#errorlog"> ErrorLog <var>chemin fichier</var>|syslog[:<var>facility</var>]</a></td><td> logs/error_log (Uni +</td><td>sv</td><td>C</td></tr><tr><td class="descr" colspan="4">D�finition du chemin du journal des erreurs</td></tr>
+<tr><td><a href="core.html#errorlog"> ErrorLog <var>file-path</var>|syslog[:[<var>facility</var>][:<var>tag</var>]]</a></td><td> logs/error_log (Uni +</td><td>sv</td><td>C</td></tr><tr><td class="descr" colspan="4">D�finition du chemin du journal des erreurs</td></tr>
 <tr class="odd"><td><a href="core.html#errorlogformat"> ErrorLogFormat [connection|request] <var>format</var></a></td><td></td><td>sv</td><td>C</td></tr><tr class="odd"><td class="descr" colspan="4">Sp�cification du format des entr�es du journal des erreurs</td></tr>
 <tr><td><a href="mod_example_hooks.html#example">Example</a></td><td></td><td>svdh</td><td>X</td></tr><tr><td class="descr" colspan="4">Directive de d�monstration pour illustrer l'API des modules
 Apache</td></tr>
diff --git a/docs/manual/mod/quickreference.html.ko.euc-kr b/docs/manual/mod/quickreference.html.ko.euc-kr
index 5906c7a..8efb498 100644
--- a/docs/manual/mod/quickreference.html.ko.euc-kr
+++ b/docs/manual/mod/quickreference.html.ko.euc-kr
@@ -413,7 +413,7 @@ after a crash</td></tr>
 <tr><td><a href="core.html#error">Error <var>message</var></a></td><td></td><td>svdh</td><td>C</td></tr><tr><td class="descr" colspan="4">Abort configuration parsing with a custom error message</td></tr>
 <tr class="odd"><td><a href="core.html#errordocument">ErrorDocument <var>error-code</var> <var>document</var></a></td><td></td><td>svdh</td><td>C</td></tr><tr class="odd"><td class="descr" colspan="4">What the server will return to the client
 in case of an error</td></tr>
-<tr><td><a href="core.html#errorlog"> ErrorLog <var>file-path</var>|syslog[:<var>facility</var>]</a></td><td> logs/error_log (Uni +</td><td>sv</td><td>C</td></tr><tr><td class="descr" colspan="4">Location where the server will log errors</td></tr>
+<tr><td><a href="core.html#errorlog"> ErrorLog <var>file-path</var>|syslog[:[<var>facility</var>][:<var>tag</var>]]</a></td><td> logs/error_log (Uni +</td><td>sv</td><td>C</td></tr><tr><td class="descr" colspan="4">Location where the server will log errors</td></tr>
 <tr class="odd"><td><a href="core.html#errorlogformat"> ErrorLogFormat [connection|request] <var>format</var></a></td><td></td><td>sv</td><td>C</td></tr><tr class="odd"><td class="descr" colspan="4">Format specification for error log entries</td></tr>
 <tr><td><a href="mod_example_hooks.html#example">Example</a></td><td></td><td>svdh</td><td>X</td></tr><tr><td class="descr" colspan="4">����ġ ��� API�� �����ϱ����� ���� ���þ�</td></tr>
 <tr class="odd"><td><a href="mod_expires.html#expiresactive">ExpiresActive On|Off</a></td><td></td><td>svdh</td><td>E</td></tr><tr class="odd"><td class="descr" colspan="4"><code>Expires</code> ����� �����Ѵ�</td></tr>
diff --git a/docs/manual/mod/quickreference.html.zh-cn.utf8 b/docs/manual/mod/quickreference.html.zh-cn.utf8
index 6a58da8..637e572 100644
--- a/docs/manual/mod/quickreference.html.zh-cn.utf8
+++ b/docs/manual/mod/quickreference.html.zh-cn.utf8
@@ -429,7 +429,7 @@ after a crash</td></tr>
 <tr><td><a href="core.html#error">Error <var>message</var></a></td><td></td><td>svdh</td><td>C</td></tr><tr><td class="descr" colspan="4">Abort configuration parsing with a custom error message</td></tr>
 <tr class="odd"><td><a href="core.html#errordocument">ErrorDocument <var>error-code</var> <var>document</var></a></td><td></td><td>svdh</td><td>C</td></tr><tr class="odd"><td class="descr" colspan="4">What the server will return to the client
 in case of an error</td></tr>
-<tr><td><a href="core.html#errorlog"> ErrorLog <var>file-path</var>|syslog[:<var>facility</var>]</a></td><td> logs/error_log (Uni +</td><td>sv</td><td>C</td></tr><tr><td class="descr" colspan="4">Location where the server will log errors</td></tr>
+<tr><td><a href="core.html#errorlog"> ErrorLog <var>file-path</var>|syslog[:[<var>facility</var>][:<var>tag</var>]]</a></td><td> logs/error_log (Uni +</td><td>sv</td><td>C</td></tr><tr><td class="descr" colspan="4">Location where the server will log errors</td></tr>
 <tr class="odd"><td><a href="core.html#errorlogformat"> ErrorLogFormat [connection|request] <var>format</var></a></td><td></td><td>sv</td><td>C</td></tr><tr class="odd"><td class="descr" colspan="4">Format specification for error log entries</td></tr>
 <tr><td><a href="mod_example_hooks.html#example">Example</a></td><td></td><td>svdh</td><td>X</td></tr><tr><td class="descr" colspan="4">Demonstration directive to illustrate the Apache module
 API</td></tr>
diff --git a/docs/manual/rewrite/flags.html.en b/docs/manual/rewrite/flags.html.en
index 7fcca2a..63c61a5 100644
--- a/docs/manual/rewrite/flags.html.en
+++ b/docs/manual/rewrite/flags.html.en
@@ -536,7 +536,7 @@ client undue influence.</p>
 <p>Using this flag triggers the use of <code class="module"><a href="../mod/mod_proxy.html">mod_proxy</a></code>, without handling of persistent connections. This
 means the performance of your proxy will be better if you set it up with <code class="directive"><a href="../mod/mod_proxy.html#proxypass">ProxyPass</a></code> or
 <code class="directive"><a href="../mod/mod_proxy.html#proxypassmatch">ProxyPassMatch</a></code></p>
-<p>This is because this flag triggers the use of the default worker, which does not handle connection pooling.</p>
+<p>This is because this flag triggers the use of the default worker, which does not handle connection pooling/reuse.</p>
 <p>Avoid using this flag and prefer those directives, whenever you can.</p>
 </div>
 
diff --git a/docs/manual/rewrite/flags.html.fr b/docs/manual/rewrite/flags.html.fr
index 7ce4506..5e8f2b2 100644
--- a/docs/manual/rewrite/flags.html.fr
+++ b/docs/manual/rewrite/flags.html.fr
@@ -588,7 +588,7 @@ local.</p>
       persistantes, ce qui signifie que vous obtiendrez des performances meilleurs si vous utilisez
       <code class="directive"><a href="../mod/mod_proxy.html#proxypass">ProxyPass</a></code> ou <code class="directive"><a href="../mod/mod_proxy.html#proxypassmatch">ProxyPassMatch</a></code>.</p>
       <p>Ceci est du au fait que ce drapeau induit l'utilisation du worker par d�faut, qui
-      ne g�re pas la mise en commun des connexions.</p>
+      ne g�re pas la mise en commun et la r�utilisation des connexions.</p>
       <p>Partout o� cela est possible, pr�f�rez l'utilisation de ces directives.</p>
 </div>
 
diff --git a/docs/manual/rewrite/rewritemap.html.en b/docs/manual/rewrite/rewritemap.html.en
index a450aa3..9caef79 100644
--- a/docs/manual/rewrite/rewritemap.html.en
+++ b/docs/manual/rewrite/rewritemap.html.en
@@ -359,6 +359,11 @@ by many requests.
     a context that does not have <code class="directive"><a href="../mod/mod_rewrite.html#rewriteengine">RewriteEngine</a></code> set to
     <code>on</code>.</p>
 
+    <p>By default, external rewriting programs are started as root.
+    This can be changed on UNIX systems by passing user name and
+    group name as third argument to <code class="directive"><a href="../mod/mod_rewrite.html#rewritemap">
+    RewriteMap</a></code> in the <code>username:groupname</code> format.</p>
+
     <p>This feature utilizes the <code>rewrite-map</code> mutex,
     which is required for reliable communication with the program.
     The mutex mechanism and lock file can be configured with the
@@ -368,7 +373,7 @@ by many requests.
     underscores in a request URI.</p>
 
     <p><strong>Rewrite configuration</strong></p>
-    <pre class="prettyprint lang-config">RewriteMap d2u "prg:/www/bin/dash2under.pl"
+    <pre class="prettyprint lang-config">RewriteMap d2u "prg:/www/bin/dash2under.pl" apache:apache
 RewriteRule "-" "${d2u:%{REQUEST_URI}}"</pre>
 
 
diff --git a/docs/manual/rewrite/rewritemap.html.fr b/docs/manual/rewrite/rewritemap.html.fr
index eb4957a..5cbba05 100644
--- a/docs/manual/rewrite/rewritemap.html.fr
+++ b/docs/manual/rewrite/rewritemap.html.fr
@@ -26,6 +26,8 @@
 <p><span>Langues Disponibles: </span><a href="../en/rewrite/rewritemap.html" hreflang="en" rel="alternate" title="English"> en </a> |
 <a href="../fr/rewrite/rewritemap.html" title="Fran�ais"> fr </a></p>
 </div>
+<div class="outofdate">Cette traduction peut �tre p�rim�e. V�rifiez la version
+            anglaise pour les changements r�cents.</div>
 
 
     <p>Ce document est un compl�ment � la <a href="../mod/mod_rewrite.html">documentation de r�f�rence</a> du
diff --git a/docs/manual/sitemap.html.en b/docs/manual/sitemap.html.en
index 0b3baf4..0ed5e9a 100644
--- a/docs/manual/sitemap.html.en
+++ b/docs/manual/sitemap.html.en
@@ -332,6 +332,7 @@ log_server_status</a></li>
 <li><a href="mod/">Module index</a></li>
 <li><a href="mod/directives.html">Directive index</a></li>
 <li><a href="mod/quickreference.html">Directive Quick-Reference</a></li>
+<li><a href="mod/overrides.html">Override class index for .htaccess</a></li>
 </ul>
 </div></div>
 <div class="bottomlang">
diff --git a/docs/manual/sitemap.html.es b/docs/manual/sitemap.html.es
index b438409..41433a7 100644
--- a/docs/manual/sitemap.html.es
+++ b/docs/manual/sitemap.html.es
@@ -34,6 +34,10 @@
 <a href="./tr/sitemap.html" hreflang="tr" rel="alternate" title="T�rk�e"> tr </a> |
 <a href="./zh-cn/sitemap.html" hreflang="zh-cn" rel="alternate" title="Simplified Chinese"> zh-cn </a></p>
 </div>
+<div class="outofdate">Esta traducci�n podr�a estar
+            obsoleta. Consulte la versi�n en ingl�s de la
+            documentaci�n para comprobar si se han producido cambios
+            recientemente.</div>
 
 <p>Esta p�gina contiene la lista con los documentos actualmente
 disponibles de la <a href="./">Versi�n 2.4 de la
diff --git a/docs/manual/sitemap.html.fr b/docs/manual/sitemap.html.fr
index a730f10..a5920ab 100644
--- a/docs/manual/sitemap.html.fr
+++ b/docs/manual/sitemap.html.fr
@@ -354,6 +354,8 @@ threads dans la version 2.x</a></li>
 <li><a href="mod/">Index des modules</a></li>
 <li><a href="mod/directives.html">Index des directives</a></li>
 <li><a href="mod/quickreference.html">R�f�rence rapide des directives</a></li>
+<li><a href="mod/overrides.html">Index des directives disponibles dans les
+fichiers .htaccess</a></li>
 </ul>
 </div></div>
 <div class="bottomlang">
diff --git a/docs/manual/sitemap.html.tr.utf8 b/docs/manual/sitemap.html.tr.utf8
index e041c03..04f7811 100644
--- a/docs/manual/sitemap.html.tr.utf8
+++ b/docs/manual/sitemap.html.tr.utf8
@@ -34,6 +34,7 @@
 <a href="./tr/sitemap.html" title="Türkçe"> tr </a> |
 <a href="./zh-cn/sitemap.html" hreflang="zh-cn" rel="alternate" title="Simplified Chinese"> zh-cn </a></p>
 </div>
+<div class="outofdate">Bu çeviri güncel olmayabilir. Son değişiklikler için İngilizce sürüm geçerlidir.</div>
 
 <p>Bu sayfada <a href="./">Apache HTTP Sunucusu Sürüm 2.4
 Belgeleri</a>nin tamamı listelenmiştir.</p>
diff --git a/docs/manual/style/css/manual.css b/docs/manual/style/css/manual.css
index da86a9a..57b5e7d 100644
--- a/docs/manual/style/css/manual.css
+++ b/docs/manual/style/css/manual.css
@@ -611,6 +611,12 @@ div#directive-list ul {
     padding: 0;
 }
 
+/* override index */
+/* ============== */
+div#override-list td.module {
+    width: 20%;
+}
+
 /* indextable */
 /* ========== */
 table#indextable td ul {
diff --git a/docs/manual/style/modulesynopsis.dtd b/docs/manual/style/modulesynopsis.dtd
index 4dac5ef..1ca9b06 100644
--- a/docs/manual/style/modulesynopsis.dtd
+++ b/docs/manual/style/modulesynopsis.dtd
@@ -75,3 +75,11 @@ usage?, seealso*)>
 <!ATTLIST quickreference metafile CDATA  #REQUIRED>
 
 <!ELEMENT legend (table, table)>
+
+<!-- Used in overrides.xml -->
+<!ELEMENT overrideindex (title | summary | overridesummary)+>
+<!ATTLIST overrideindex metafile CDATA #REQUIRED>
+
+<!ELEMENT overridesummary %Block;>
+<!ATTLIST overridesummary class    CDATA #IMPLIED
+                          fallback CDATA #IMPLIED>
diff --git a/docs/manual/style/scripts/prettify.js b/docs/manual/style/scripts/prettify.js
index 2fa959a..bb74158 100644
--- a/docs/manual/style/scripts/prettify.js
+++ b/docs/manual/style/scripts/prettify.js
@@ -132,7 +132,7 @@ var prettyPrint;
   var SH_KEYWORDS = [FLOW_CONTROL_KEYWORDS, "case,done,elif,esac,eval,fi," +
       "function,in,local,set,then,until,echo"];
   var CONFIG_ENVS = ["User-Agent,HTTP_USER_AGENT,HTTP_REFERER,HTTP_COOKIE,HTTP_FORWARDED,HTTP_HOST,HTTP_PROXY_CONNECTION,HTTP_ACCEPT,REMOTE_ADDR,REMOTE_HOST,REMOTE_PORT,REMOTE_USER,REMOTE_IDENT,REQUEST_METHOD,SCRIPT_FILENAME,PATH_INFO,QUERY_STRING,AUTH_TYPE,DOCUMENT_ROOT,SERVER_ADMIN,SERVER_NAME,SERVER_ADDR,SERVER_PORT,SERVER_PROTOCOL,SERVER_SOFTWARE,TIME_YEAR,TIME_MON,TIME_DAY,TIME_HOUR,TIME_MIN,TIME_SEC,TIME_WDAY,TIME,API_VERSION,THE_REQUEST,REQUEST_URI,REQUEST_FILENAME,IS_SUBREQ,HTTPS [...]
-  var CONFIG_KEYWORDS = ["Macro,UndefMacro,Use,AuthLDAPURL,AcceptFilter,AcceptPathInfo,AccessFileName,Action,AddAlt,AddAltByEncoding,AddAltByType,AddCharset,AddDefaultCharset,AddDescription,AddEncoding,AddHandler,AddIcon,AddIconByEncoding,AddIconByType,AddInputFilter,AddLanguage,AddModuleInfo,AddOutputFilter,AddOutputFilterByType,AddType,Alias,AliasMatch,Allow,AllowCONNECT,AllowEncodedSlashes,AllowMethods,AllowOverride,AllowOverrideList,Anonymous,Anonymous_LogEmail,Anonymous_MustGiveEmai [...]
+  var CONFIG_KEYWORDS = ["AcceptFilter,AcceptPathInfo,AccessFileName,Action,AddAlt,AddAltByEncoding,AddAltByType,AddCharset,AddDefaultCharset,AddDescription,AddEncoding,AddHandler,AddIcon,AddIconByEncoding,AddIconByType,AddInputFilter,AddLanguage,AddModuleInfo,AddOutputFilter,AddOutputFilterByType,AddType,Alias,AliasMatch,Allow,AllowCONNECT,AllowEncodedSlashes,AllowMethods,AllowOverride,AllowOverrideList,Anonymous,Anonymous_LogEmail,Anonymous_MustGiveEmail,Anonymous_NoUserID,Anonymous_Ve [...]
   var CONFIG_OPTIONS = /^[\\+\\-]?(AuthConfig|IncludesNOEXEC|ExecCGI|FollowSymLinks|MultiViews|Includes|Indexes|SymLinksIfOwnerMatch)\b/i;
   var ALL_KEYWORDS = [
       CPP_KEYWORDS, CSHARP_KEYWORDS, JSCRIPT_KEYWORDS, PERL_KEYWORDS +
diff --git a/docs/manual/style/scripts/prettify.min.js b/docs/manual/style/scripts/prettify.min.js
index 4f0f9f5..adb92be 100644
--- a/docs/manual/style/scripts/prettify.min.js
+++ b/docs/manual/style/scripts/prettify.min.js
@@ -1,5 +1,5 @@
 // see prettify.js for copyright, license and expanded version
-window['PR_SHOULD_USE_CONTINUATION']=true;var prettyPrintOne;var prettyPrint;(function(){var win=window;var FLOW_CONTROL_KEYWORDS=["break,continue,do,else,for,if,return,while"];var C_KEYWORDS=[FLOW_CONTROL_KEYWORDS,"auto,case,char,const,default,"+"double,enum,extern,float,goto,int,long,register,short,signed,sizeof,module,"+"static,struct,switch,typedef,union,unsigned,void,volatile"];var COMMON_KEYWORDS=[C_KEYWORDS,"catch,class,delete,false,import,"+"new,operator,private,protected,public, [...]
+window['PR_SHOULD_USE_CONTINUATION']=true;var prettyPrintOne;var prettyPrint;(function(){var win=window;var FLOW_CONTROL_KEYWORDS=["break,continue,do,else,for,if,return,while"];var C_KEYWORDS=[FLOW_CONTROL_KEYWORDS,"auto,case,char,const,default,"+"double,enum,extern,float,goto,int,long,register,short,signed,sizeof,module,"+"static,struct,switch,typedef,union,unsigned,void,volatile"];var COMMON_KEYWORDS=[C_KEYWORDS,"catch,class,delete,false,import,"+"new,operator,private,protected,public, [...]
 PYTHON_KEYWORDS,RUBY_KEYWORDS,SH_KEYWORDS,CONFIG_KEYWORDS,PHP_KEYWORDS];var C_TYPES=/^(DIR|FILE|vector|(de|priority_)?queue|list|stack|(const_)?iterator|(multi)?(set|map)|bitset|u?(int|float|char|void|const|static|struct)\d*(_t)?\b)|[a-z_]+_rec|cmd_parms\b/;var PR_STRING='str';var PR_KEYWORD='kwd';var PR_COMMENT='com';var PR_TYPE='typ';var PR_LITERAL='lit';var PR_PUNCTUATION='pun';var PR_PLAIN='pln';var PR_TAG='tag';var PR_DECLARATION='dec';var PR_SOURCE='src';var PR_ATTRIB_NAME='atn';va [...]
 var escapeCharToCodeUnit={'b':8,'t':9,'n':0xa,'v':0xb,'f':0xc,'r':0xd};function decodeEscape(charsetPart){var cc0=charsetPart.charCodeAt(0);if(cc0!==92){return cc0;}
 var c1=charsetPart.charAt(1);cc0=escapeCharToCodeUnit[c1];if(cc0){return cc0;}else if('0'<=c1&&c1<='7'){return parseInt(charsetPart.substring(1),8);}else if(c1==='u'||c1==='x'){return parseInt(charsetPart.substring(2),16);}else{return charsetPart.charCodeAt(1);}}
diff --git a/docs/manual/style/version.ent b/docs/manual/style/version.ent
index 66952cd..b44b2a7 100644
--- a/docs/manual/style/version.ent
+++ b/docs/manual/style/version.ent
@@ -19,6 +19,6 @@
 
 <!ENTITY httpd.major "2">
 <!ENTITY httpd.minor "4">
-<!ENTITY httpd.patch "27">
+<!ENTITY httpd.patch "29">
 
 <!ENTITY httpd.docs "2.4">
diff --git a/httpd.spec b/httpd.spec
index c4839eb..7ab4dbb 100644
--- a/httpd.spec
+++ b/httpd.spec
@@ -4,7 +4,7 @@
 
 Summary: Apache HTTP Server
 Name: httpd
-Version: 2.4.27
+Version: 2.4.29
 Release: 1
 URL: http://httpd.apache.org/
 Vendor: Apache Software Foundation
diff --git a/include/ap_release.h b/include/ap_release.h
index 5e83332..98ededd 100644
--- a/include/ap_release.h
+++ b/include/ap_release.h
@@ -43,7 +43,7 @@
 
 #define AP_SERVER_MAJORVERSION_NUMBER 2
 #define AP_SERVER_MINORVERSION_NUMBER 4
-#define AP_SERVER_PATCHLEVEL_NUMBER   27
+#define AP_SERVER_PATCHLEVEL_NUMBER   29
 #define AP_SERVER_DEVBUILD_BOOLEAN    0
 
 /* Synchronize the above with docs/manual/style/version.ent */
diff --git a/libhttpd.dsp b/libhttpd.dsp
index ae4b17b..7fbc85e 100644
--- a/libhttpd.dsp
+++ b/libhttpd.dsp
@@ -379,6 +379,35 @@ InputPath=.\modules\core\mod_so.h
 # End Source File
 # Begin Source File
 
+SOURCE=.\modules\core\mod_watchdog.h
+
+!IF  "$(CFG)" == "libhttpd - Win32 Release"
+
+# PROP Ignore_Default_Tool 1
+# Begin Custom Build - Creating include/mod_watchdog.h
+InputPath=.\modules\core\mod_watchdog.h
+
+".\include\mod_watchdog.h" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
+	type .\modules\core\mod_watchdog.h > .\include\mod_watchdog.h
+
+# End Custom Build
+
+!ELSEIF  "$(CFG)" == "libhttpd - Win32 Debug"
+
+# PROP Ignore_Default_Tool 1
+# Begin Custom Build - Creating include/mod_watchdog.h
+InputPath=.\modules\core\mod_watchdog.h
+
+".\include\mod_watchdog.h" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
+	type .\modules\core\mod_watchdog.h > .\include\mod_watchdog.h
+
+# End Custom Build
+
+!ENDIF 
+
+# End Source File
+# Begin Source File
+
 SOURCE=.\os\win32\os.h
 
 !IF  "$(CFG)" == "libhttpd - Win32 Release"
diff --git a/libhttpd.mak b/libhttpd.mak
index 0975ec1..caabb55 100644
--- a/libhttpd.mak
+++ b/libhttpd.mak
@@ -37,11 +37,11 @@ OutDir=.\Release
 
 !IF "$(RECURSE)" == "0" 
 
-ALL : ".\include\mod_dav.h" "$(OUTDIR)\libhttpd.dll" "$(DS_POSTBUILD_DEP)"
+ALL : ".\include\mod_dav.h" ".\include\mod_watchdog.h" "$(OUTDIR)\libhttpd.dll" "$(DS_POSTBUILD_DEP)"
 
 !ELSE 
 
-ALL : "gen_test_char - Win32 Release" "libaprutil - Win32 Release" "libapriconv - Win32 Release" "libapr - Win32 Release" ".\include\mod_dav.h" "$(OUTDIR)\libhttpd.dll" "$(DS_POSTBUILD_DEP)"
+ALL : "gen_test_char - Win32 Release" "libaprutil - Win32 Release" "libapriconv - Win32 Release" "libapr - Win32 Release" ".\include\mod_dav.h" ".\include\mod_watchdog.h" "$(OUTDIR)\libhttpd.dll" "$(DS_POSTBUILD_DEP)"
 
 !ENDIF 
 
@@ -233,11 +233,11 @@ OutDir=.\Debug
 
 !IF "$(RECURSE)" == "0" 
 
-ALL : ".\server\test_char.h" ".\include\mod_so.h" ".\include\mod_proxy.h" ".\include\mod_include.h" ".\include\mod_dav.h" ".\include\mod_cgi.h" ".\include\ap_config_layout.h" "$(OUTDIR)\libhttpd.dll" "$(DS_POSTBUILD_DEP)"
+ALL : ".\server\test_char.h" ".\include\mod_watchdog.h" ".\include\mod_so.h" ".\include\mod_proxy.h" ".\include\mod_include.h" ".\include\mod_dav.h" ".\include\mod_cgi.h" ".\include\ap_config_layout.h" "$(OUTDIR)\libhttpd.dll" "$(DS_POSTBUILD_DEP)"
 
 !ELSE 
 
-ALL : "gen_test_char - Win32 Debug" "libaprutil - Win32 Debug" "libapriconv - Win32 Debug" "libapr - Win32 Debug" ".\server\test_char.h" ".\include\mod_so.h" ".\include\mod_proxy.h" ".\include\mod_include.h" ".\include\mod_dav.h" ".\include\mod_cgi.h" ".\include\ap_config_layout.h" "$(OUTDIR)\libhttpd.dll" "$(DS_POSTBUILD_DEP)"
+ALL : "gen_test_char - Win32 Debug" "libaprutil - Win32 Debug" "libapriconv - Win32 Debug" "libapr - Win32 Debug" ".\server\test_char.h" ".\include\mod_watchdog.h" ".\include\mod_so.h" ".\include\mod_proxy.h" ".\include\mod_include.h" ".\include\mod_dav.h" ".\include\mod_cgi.h" ".\include\ap_config_layout.h" "$(OUTDIR)\libhttpd.dll" "$(DS_POSTBUILD_DEP)"
 
 !ENDIF 
 
@@ -305,6 +305,7 @@ CLEAN :
 	- at erase ".\include\mod_include.h"
 	- at erase ".\include\mod_proxy.h"
 	- at erase ".\include\mod_so.h"
+	- at erase ".\include\mod_watchdog.h"
 	- at erase ".\server\test_char.h"
 
 "$(OUTDIR)" :
@@ -772,6 +773,34 @@ InputPath=.\modules\core\mod_so.h
 
 !ENDIF 
 
+SOURCE=.\modules\core\mod_watchdog.h
+
+!IF  "$(CFG)" == "libhttpd - Win32 Release"
+
+InputPath=.\modules\core\mod_watchdog.h
+
+".\include\mod_watchdog.h" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
+	<<tempfile.bat 
+	@echo off 
+	type .\modules\core\mod_watchdog.h > .\include\mod_watchdog.h
+<< 
+	
+
+!ELSEIF  "$(CFG)" == "libhttpd - Win32 Debug"
+
+InputPath=.\modules\core\mod_watchdog.h
+
+".\include\mod_watchdog.h" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
+	<<tempfile.bat 
+	@echo off 
+	type .\modules\core\mod_watchdog.h > .\include\mod_watchdog.h
+<< 
+	
+
+!ELSEIF  "$(CFG)" == "libhttpd - Win32 Lexical"
+
+!ENDIF 
+
 SOURCE=.\os\win32\os.h
 
 !IF  "$(CFG)" == "libhttpd - Win32 Release"
diff --git a/modules/aaa/mod_authz_dbd.c b/modules/aaa/mod_authz_dbd.c
index 52aab38..e1bb623 100644
--- a/modules/aaa/mod_authz_dbd.c
+++ b/modules/aaa/mod_authz_dbd.c
@@ -119,7 +119,7 @@ static int authz_dbd_login(request_rec *r, authz_dbd_cfg *cfg,
     const char *newuri = NULL;
     int nrows;
     const char *message;
-    ap_dbd_t *dbd = dbd_handle(r);
+    ap_dbd_t *dbd;
     apr_dbd_prepared_t *query;
     apr_dbd_results_t *res = NULL;
     apr_dbd_row_t *row = NULL;
@@ -129,6 +129,8 @@ static int authz_dbd_login(request_rec *r, authz_dbd_cfg *cfg,
                       "No query configured for %s!", action);
         return HTTP_INTERNAL_SERVER_ERROR;
     }
+    
+    dbd = dbd_handle(r);
     if (dbd == NULL) {
         ap_log_rerror(APLOG_MARK, APLOG_ERR, 0, r, APLOGNO(02902)
                       "No db handle available for %s! "
@@ -136,6 +138,7 @@ static int authz_dbd_login(request_rec *r, authz_dbd_cfg *cfg,
                       action);
         return HTTP_INTERNAL_SERVER_ERROR;
     }
+
     query = apr_hash_get(dbd->prepared, cfg->query, APR_HASH_KEY_STRING);
     if (query == NULL) {
         ap_log_rerror(APLOG_MARK, APLOG_ERR, 0, r, APLOGNO(01643)
@@ -212,7 +215,7 @@ static int authz_dbd_group_query(request_rec *r, authz_dbd_cfg *cfg,
     /* SELECT group FROM authz WHERE user = %s */
     int rv;
     const char *message;
-    ap_dbd_t *dbd = dbd_handle(r);
+    ap_dbd_t *dbd;
     apr_dbd_prepared_t *query;
     apr_dbd_results_t *res = NULL;
     apr_dbd_row_t *row = NULL;
@@ -222,12 +225,15 @@ static int authz_dbd_group_query(request_rec *r, authz_dbd_cfg *cfg,
                       "No query configured for dbd-group!");
         return HTTP_INTERNAL_SERVER_ERROR;
     }
+    
+    dbd = dbd_handle(r);
     if (dbd == NULL) {
         ap_log_rerror(APLOG_MARK, APLOG_ERR, 0, r, APLOGNO(02903)
                       "No db handle available for dbd-query! "
                       "Check your database access");
         return HTTP_INTERNAL_SERVER_ERROR;
     }
+
     query = apr_hash_get(dbd->prepared, cfg->query, APR_HASH_KEY_STRING);
     if (query == NULL) {
         ap_log_rerror(APLOG_MARK, APLOG_ERR, 0, r, APLOGNO(01650)
diff --git a/modules/core/mod_watchdog.c b/modules/core/mod_watchdog.c
index 9f10c0d..b6deaba 100644
--- a/modules/core/mod_watchdog.c
+++ b/modules/core/mod_watchdog.c
@@ -66,7 +66,6 @@ struct wd_server_conf_t
 
 static wd_server_conf_t *wd_server_conf = NULL;
 static apr_interval_time_t wd_interval = AP_WD_TM_INTERVAL;
-static int wd_interval_set = 0;
 static int mpm_is_forked = AP_MPMQ_NOT_SUPPORTED;
 static const char *wd_proc_mutex_type = "watchdog-callback";
 
@@ -450,6 +449,9 @@ static int wd_post_config_hook(apr_pool_t *pconf, apr_pool_t *plog,
         apr_pool_create(&wd_server_conf->pool, ppconf);
         apr_pool_userdata_set(wd_server_conf, pk, apr_pool_cleanup_null, ppconf);
     }
+    ap_log_error(APLOG_MARK, APLOG_DEBUG, 0, s, APLOGNO(010033)
+                 "Watchdog: Running with WatchdogInterval %"
+                 APR_TIME_T_FMT "ms", apr_time_as_msec(wd_interval));
     wd_server_conf->s = s;
     if ((wl = ap_list_provider_names(pconf, AP_WATCHDOG_PGROUP,
                                             AP_WATCHDOG_PVERSION))) {
@@ -597,18 +599,20 @@ static void wd_child_init_hook(apr_pool_t *p, server_rec *s)
 static const char *wd_cmd_watchdog_int(cmd_parms *cmd, void *dummy,
                                        const char *arg)
 {
-    int i;
+    apr_status_t rv;
     const char *errs = ap_check_cmd_context(cmd, GLOBAL_ONLY);
 
     if (errs != NULL)
         return errs;
-    if (wd_interval_set)
-       return "Duplicate WatchdogInterval directives are not allowed";
-    if ((i = atoi(arg)) < 1)
-        return "Invalid WatchdogInterval value";
+    rv = ap_timeout_parameter_parse(arg, &wd_interval, "s");
+
+    if (rv != APR_SUCCESS)
+        return "Unparse-able WatchdogInterval setting";
+    if (wd_interval < AP_WD_TM_SLICE) {
+        return apr_psprintf(cmd->pool, "Invalid WatchdogInterval: minimal value %"
+                APR_TIME_T_FMT "ms", apr_time_as_msec(AP_WD_TM_SLICE));
+    }
 
-    wd_interval = apr_time_from_sec(i);
-    wd_interval_set = 1;
     return NULL;
 }
 
diff --git a/modules/dav/main/mod_dav.c b/modules/dav/main/mod_dav.c
index 7599c6d..e3a3246 100644
--- a/modules/dav/main/mod_dav.c
+++ b/modules/dav/main/mod_dav.c
@@ -1025,17 +1025,10 @@ static int dav_method_put(request_rec *r)
             if (rc != APR_SUCCESS) {
                 int http_err;
                 char *msg = ap_escape_html(r->pool, r->uri);
-                if (APR_STATUS_IS_TIMEUP(rc)) {
-                    http_err = HTTP_REQUEST_TIME_OUT;
-                    msg = apr_psprintf(r->pool, "Timeout reading the body "
-                                       "(URI: %s)", msg);
-                }
-                else {
-                    http_err = ap_map_http_request_error(rc, HTTP_BAD_REQUEST);
-                    msg = apr_psprintf(r->pool,
-                            "An error occurred while reading"
-                                    " the request body (URI: %s)", msg);
-                }
+                http_err = ap_map_http_request_error(rc, HTTP_BAD_REQUEST);
+                msg = apr_psprintf(r->pool, "An error occurred while reading "
+                                            "the request body (URI: %s)",
+                                            msg);
                 err = dav_new_error(r->pool, http_err, 0, rc, msg);
                 break;
             }
diff --git a/modules/generators/mod_cgi.c b/modules/generators/mod_cgi.c
index 000f06e..8c4a2c6 100644
--- a/modules/generators/mod_cgi.c
+++ b/modules/generators/mod_cgi.c
@@ -853,11 +853,6 @@ static int cgi_handler(request_rec *r)
                             APR_BLOCK_READ, HUGE_STRING_LEN);
 
         if (rv != APR_SUCCESS) {
-            if (APR_STATUS_IS_TIMEUP(rv)) {
-                ap_log_rerror(APLOG_MARK, APLOG_ERR, rv, r, APLOGNO(01224)
-                              "Timeout during reading request entity data");
-                return HTTP_REQUEST_TIME_OUT;
-            }
             ap_log_rerror(APLOG_MARK, APLOG_ERR, rv, r, APLOGNO(01225)
                           "Error reading request entity data");
             return ap_map_http_request_error(rv, HTTP_BAD_REQUEST);
diff --git a/modules/generators/mod_cgid.c b/modules/generators/mod_cgid.c
index 1148467..b827ed6 100644
--- a/modules/generators/mod_cgid.c
+++ b/modules/generators/mod_cgid.c
@@ -1534,11 +1534,6 @@ static int cgid_handler(request_rec *r)
                             APR_BLOCK_READ, HUGE_STRING_LEN);
 
         if (rv != APR_SUCCESS) {
-            if (APR_STATUS_IS_TIMEUP(rv)) {
-                ap_log_rerror(APLOG_MARK, APLOG_ERR, rv, r, APLOGNO(01269)
-                              "Timeout during reading request entity data");
-                return HTTP_REQUEST_TIME_OUT;
-            }
             ap_log_rerror(APLOG_MARK, APLOG_ERR, rv, r, APLOGNO(01270)
                           "Error reading request entity data");
             return ap_map_http_request_error(rv, HTTP_BAD_REQUEST);
diff --git a/modules/http2/config2.m4 b/modules/http2/config2.m4
index fac130b..e8cefe3 100644
--- a/modules/http2/config2.m4
+++ b/modules/http2/config2.m4
@@ -80,12 +80,18 @@ AC_DEFUN([APACHE_CHECK_NGHTTP2],[
     if test -n "$PKGCONFIG"; then
       saved_PKG_CONFIG_PATH="$PKG_CONFIG_PATH"
       AC_MSG_CHECKING([for pkg-config along $PKG_CONFIG_PATH])
-      if test "x$ap_nghttp2_base" != "x" -a \
-              -f "${ap_nghttp2_base}/lib/pkgconfig/libnghttp2.pc"; then
-        dnl Ensure that the given path is used by pkg-config too, otherwise
-        dnl the system libnghttp2.pc might be picked up instead.
-        PKG_CONFIG_PATH="${ap_nghttp2_base}/lib/pkgconfig${PKG_CONFIG_PATH+:}${PKG_CONFIG_PATH}"
-        export PKG_CONFIG_PATH
+      if test "x$ap_nghttp2_base" != "x" ; then
+        if test -f "${ap_nghttp2_base}/lib/pkgconfig/libnghttp2.pc"; then
+          dnl Ensure that the given path is used by pkg-config too, otherwise
+          dnl the system libnghttp2.pc might be picked up instead.
+          PKG_CONFIG_PATH="${ap_nghttp2_base}/lib/pkgconfig${PKG_CONFIG_PATH+:}${PKG_CONFIG_PATH}"
+          export PKG_CONFIG_PATH
+        elif test -f "${ap_nghttp2_base}/lib64/pkgconfig/libnghttp2.pc"; then
+          dnl Ensure that the given path is used by pkg-config too, otherwise
+          dnl the system libnghttp2.pc might be picked up instead.
+          PKG_CONFIG_PATH="${ap_nghttp2_base}/lib64/pkgconfig${PKG_CONFIG_PATH+:}${PKG_CONFIG_PATH}"
+          export PKG_CONFIG_PATH
+        fi
       fi
       AC_ARG_ENABLE(nghttp2-staticlib-deps,APACHE_HELP_STRING(--enable-nghttp2-staticlib-deps,[link mod_http2 with dependencies of libnghttp2's static libraries (as indicated by "pkg-config --static"). Must be specified in addition to --enable-http2.]), [
         if test "$enableval" = "yes"; then
diff --git a/modules/http2/h2_bucket_beam.c b/modules/http2/h2_bucket_beam.c
index fff3f5d..6b8c645 100644
--- a/modules/http2/h2_bucket_beam.c
+++ b/modules/http2/h2_bucket_beam.c
@@ -210,16 +210,7 @@ static apr_status_t mutex_enter(void *ctx, h2_beam_lock *pbl)
 
 static apr_status_t enter_yellow(h2_bucket_beam *beam, h2_beam_lock *pbl)
 {
-    h2_beam_mutex_enter *enter = beam->m_enter;
-    if (enter) {
-        void *ctx = beam->m_ctx;
-        if (ctx) {
-            return enter(ctx, pbl);
-        }
-    }
-    pbl->mutex = NULL;
-    pbl->leave = NULL;
-    return APR_SUCCESS;
+    return mutex_enter(beam, pbl);
 }
 
 static void leave_yellow(h2_bucket_beam *beam, h2_beam_lock *pbl)
@@ -287,7 +278,7 @@ static apr_size_t calc_buffered(h2_bucket_beam *beam)
             /* do not count */
         }
         else if (APR_BUCKET_IS_FILE(b)) {
-            /* if unread, has no real mem footprint. how to test? */
+            /* if unread, has no real mem footprint. */
         }
         else {
             len += b->length;
@@ -316,32 +307,80 @@ static apr_size_t calc_space_left(h2_bucket_beam *beam)
     return APR_SIZE_MAX;
 }
 
-static apr_status_t wait_cond(h2_bucket_beam *beam, apr_thread_mutex_t *lock)
+static int buffer_is_empty(h2_bucket_beam *beam)
+{
+    return ((!beam->recv_buffer || APR_BRIGADE_EMPTY(beam->recv_buffer))
+            && H2_BLIST_EMPTY(&beam->send_list));
+}
+
+static apr_status_t wait_empty(h2_bucket_beam *beam, apr_read_type_e block,  
+                               apr_thread_mutex_t *lock)
 {
-    if (beam->timeout > 0) {
-        return apr_thread_cond_timedwait(beam->cond, lock, beam->timeout);
+    apr_status_t rv = APR_SUCCESS;
+    
+    while (!buffer_is_empty(beam) && APR_SUCCESS == rv) {
+        if (APR_BLOCK_READ != block || !lock) {
+            rv = APR_EAGAIN;
+        }
+        else if (beam->timeout > 0) {
+            rv = apr_thread_cond_timedwait(beam->change, lock, beam->timeout);
+        }
+        else {
+            rv = apr_thread_cond_wait(beam->change, lock);
+        }
     }
-    else {
-        return apr_thread_cond_wait(beam->cond, lock);
+    return rv;
+}
+
+static apr_status_t wait_not_empty(h2_bucket_beam *beam, apr_read_type_e block,  
+                                   apr_thread_mutex_t *lock)
+{
+    apr_status_t rv = APR_SUCCESS;
+    
+    while (buffer_is_empty(beam) && APR_SUCCESS == rv) {
+        if (beam->aborted) {
+            rv = APR_ECONNABORTED;
+        }
+        else if (beam->closed) {
+            rv = APR_EOF;
+        }
+        else if (APR_BLOCK_READ != block || !lock) {
+            rv = APR_EAGAIN;
+        }
+        else if (beam->timeout > 0) {
+            rv = apr_thread_cond_timedwait(beam->change, lock, beam->timeout);
+        }
+        else {
+            rv = apr_thread_cond_wait(beam->change, lock);
+        }
     }
+    return rv;
 }
 
-static apr_status_t r_wait_space(h2_bucket_beam *beam, apr_read_type_e block,
-                                 h2_beam_lock *pbl, apr_size_t *premain) 
+static apr_status_t wait_not_full(h2_bucket_beam *beam, apr_read_type_e block, 
+                                  apr_size_t *pspace_left, h2_beam_lock *bl)
 {
-    *premain = calc_space_left(beam);
-    while (!beam->aborted && *premain <= 0 
-           && (block == APR_BLOCK_READ) && pbl->mutex) {
-        apr_status_t status;
-        report_prod_io(beam, 1, pbl);
-        status = wait_cond(beam, pbl->mutex);
-        if (APR_STATUS_IS_TIMEUP(status)) {
-            return status;
+    apr_status_t rv = APR_SUCCESS;
+    apr_size_t left;
+    
+    while (0 == (left = calc_space_left(beam)) && APR_SUCCESS == rv) {
+        if (beam->aborted) {
+            rv = APR_ECONNABORTED;
+        }
+        else if (block != APR_BLOCK_READ || !bl->mutex) {
+            rv = APR_EAGAIN;
+        }
+        else {
+            if (beam->timeout > 0) {
+                rv = apr_thread_cond_timedwait(beam->change, bl->mutex, beam->timeout);
+            }
+            else {
+                rv = apr_thread_cond_wait(beam->change, bl->mutex);
+            }
         }
-        r_purge_sent(beam);
-        *premain = calc_space_left(beam);
     }
-    return beam->aborted? APR_ECONNABORTED : APR_SUCCESS;
+    *pspace_left = left;
+    return rv;
 }
 
 static void h2_beam_emitted(h2_bucket_beam *beam, h2_beam_proxy *proxy)
@@ -404,8 +443,8 @@ static void h2_beam_emitted(h2_bucket_beam *beam, h2_beam_proxy *proxy)
         if (!bl.mutex) {
             r_purge_sent(beam);
         }
-        else if (beam->cond) {
-            apr_thread_cond_broadcast(beam->cond);
+        else {
+            apr_thread_cond_broadcast(beam->change);
         }
         leave_yellow(beam, &bl);
     }
@@ -425,9 +464,7 @@ static apr_status_t beam_close(h2_bucket_beam *beam)
 {
     if (!beam->closed) {
         beam->closed = 1;
-        if (beam->cond) {
-            apr_thread_cond_broadcast(beam->cond);
-        }
+        apr_thread_cond_broadcast(beam->change);
     }
     return APR_SUCCESS;
 }
@@ -522,13 +559,12 @@ static apr_status_t beam_cleanup(void *data)
 {
     h2_bucket_beam *beam = data;
     apr_status_t status = APR_SUCCESS;
-    int safe_send = !beam->m_enter || (beam->owner == H2_BEAM_OWNER_SEND);
-    int safe_recv = !beam->m_enter || (beam->owner == H2_BEAM_OWNER_RECV);
+    int safe_send = (beam->owner == H2_BEAM_OWNER_SEND);
+    int safe_recv = (beam->owner == H2_BEAM_OWNER_RECV);
     
     /* 
      * Owner of the beam is going away, depending on which side it owns,
-     * cleanup strategies will differ with multi-thread protection
-     * still in place (beam->m_enter).
+     * cleanup strategies will differ.
      *
      * In general, receiver holds references to memory from sender. 
      * Clean up receiver first, if safe, then cleanup sender, if safe.
@@ -582,7 +618,7 @@ apr_status_t h2_beam_create(h2_bucket_beam **pbeam, apr_pool_t *pool,
                             apr_interval_time_t timeout)
 {
     h2_bucket_beam *beam;
-    apr_status_t status = APR_SUCCESS;
+    apr_status_t rv = APR_SUCCESS;
     
     beam = apr_pcalloc(pool, sizeof(*beam));
     if (!beam) {
@@ -601,16 +637,15 @@ apr_status_t h2_beam_create(h2_bucket_beam **pbeam, apr_pool_t *pool,
     beam->max_buf_size = max_buf_size;
     beam->timeout = timeout;
 
-    status = apr_thread_mutex_create(&beam->lock, APR_THREAD_MUTEX_DEFAULT, 
-                                     pool);
-    if (status == APR_SUCCESS) {
-        status = apr_thread_cond_create(&beam->cond, pool);
-        if (status == APR_SUCCESS) {
+    rv = apr_thread_mutex_create(&beam->lock, APR_THREAD_MUTEX_DEFAULT, pool);
+    if (APR_SUCCESS == rv) {
+        rv = apr_thread_cond_create(&beam->change, pool);
+        if (APR_SUCCESS == rv) {
             apr_pool_pre_cleanup_register(pool, beam, beam_cleanup);
             *pbeam = beam;
         }
     }
-    return status;
+    return rv;
 }
 
 void h2_beam_buffer_size_set(h2_bucket_beam *beam, apr_size_t buffer_size)
@@ -635,29 +670,6 @@ apr_size_t h2_beam_buffer_size_get(h2_bucket_beam *beam)
     return buffer_size;
 }
 
-void h2_beam_mutex_set(h2_bucket_beam *beam, 
-                       h2_beam_mutex_enter m_enter,
-                       void *m_ctx)
-{
-    h2_beam_lock bl;
-    
-    if (enter_yellow(beam, &bl) == APR_SUCCESS) {
-        beam->m_enter = m_enter;
-        beam->m_ctx   = m_ctx;
-        leave_yellow(beam, &bl);
-    }
-}
-
-void h2_beam_mutex_enable(h2_bucket_beam *beam)
-{
-    h2_beam_mutex_set(beam, mutex_enter, beam);
-}
-
-void h2_beam_mutex_disable(h2_bucket_beam *beam)
-{
-    h2_beam_mutex_set(beam, NULL, NULL);
-}
-
 void h2_beam_timeout_set(h2_bucket_beam *beam, apr_interval_time_t timeout)
 {
     h2_beam_lock bl;
@@ -691,9 +703,7 @@ void h2_beam_abort(h2_bucket_beam *beam)
             h2_blist_cleanup(&beam->send_list);
             report_consumption(beam, &bl);
         }
-        if (beam->cond) {
-            apr_thread_cond_broadcast(beam->cond);
-        }
+        apr_thread_cond_broadcast(beam->change);
         leave_yellow(beam, &bl);
     }
 }
@@ -730,18 +740,7 @@ apr_status_t h2_beam_wait_empty(h2_bucket_beam *beam, apr_read_type_e block)
     h2_beam_lock bl;
     
     if ((status = enter_yellow(beam, &bl)) == APR_SUCCESS) {
-        while (status == APR_SUCCESS
-               && !H2_BLIST_EMPTY(&beam->send_list)
-               && !H2_BPROXY_LIST_EMPTY(&beam->proxies)) {
-            if (block == APR_NONBLOCK_READ || !bl.mutex) {
-                status = APR_EAGAIN;
-                break;
-            }
-            if (beam->cond) {
-                apr_thread_cond_broadcast(beam->cond);
-            }
-            status = wait_cond(beam, bl.mutex);
-        }
+        status = wait_empty(beam, block, bl.mutex);
         leave_yellow(beam, &bl);
     }
     return status;
@@ -761,12 +760,17 @@ static void move_to_hold(h2_bucket_beam *beam,
 static apr_status_t append_bucket(h2_bucket_beam *beam, 
                                   apr_bucket *b,
                                   apr_read_type_e block,
+                                  apr_size_t *pspace_left,
                                   h2_beam_lock *pbl)
 {
     const char *data;
     apr_size_t len;
-    apr_size_t space_left = 0;
     apr_status_t status;
+    int can_beam, check_len;
+    
+    if (beam->aborted) {
+        return APR_ECONNABORTED;
+    }
     
     if (APR_BUCKET_IS_METADATA(b)) {
         if (APR_BUCKET_IS_EOS(b)) {
@@ -777,30 +781,46 @@ static apr_status_t append_bucket(h2_bucket_beam *beam,
         return APR_SUCCESS;
     }
     else if (APR_BUCKET_IS_FILE(b)) {
-        /* file bucket lengths do not really count */
+        /* For file buckets the problem is their internal readpool that
+         * is used on the first read to allocate buffer/mmap.
+         * Since setting aside a file bucket will de-register the
+         * file cleanup function from the previous pool, we need to
+         * call that only from the sender thread.
+         *
+         * Currently, we do not handle file bucket with refcount > 1 as
+         * the beam is then not in complete control of the file's lifetime.
+         * Which results in the bug that a file get closed by the receiver
+         * while the sender or the beam still have buckets using it. 
+         * 
+         * Additionally, we allow callbacks to prevent beaming file
+         * handles across. The use case for this is to limit the number 
+         * of open file handles and rather use a less efficient beam
+         * transport. */
+        apr_bucket_file *bf = b->data;
+        apr_file_t *fd = bf->fd;
+        can_beam = (bf->refcount.refcount == 1);
+        if (can_beam && beam->can_beam_fn) {
+            can_beam = beam->can_beam_fn(beam->can_beam_ctx, beam, fd);
+        }
+        check_len = !can_beam;
     }
     else {
-        space_left = calc_space_left(beam);
-        if (space_left > 0 && b->length == ((apr_size_t)-1)) {
+        if (b->length == ((apr_size_t)-1)) {
             const char *data;
             status = apr_bucket_read(b, &data, &len, APR_BLOCK_READ);
             if (status != APR_SUCCESS) {
                 return status;
             }
         }
-        
-        if (space_left <= 0) {
-            status = r_wait_space(beam, block, pbl, &space_left);
-            if (status != APR_SUCCESS) {
-                return status;
-            }
-            if (space_left <= 0) {
-                return APR_EAGAIN;
-            }
-        }
-        /* space available, maybe need bucket split */
+        check_len = 1;
     }
     
+    if (check_len) {
+        if (b->length > *pspace_left) {
+            apr_bucket_split(b, *pspace_left);
+        }
+        *pspace_left -= b->length;
+    }
 
     /* The fundamental problem is that reading a sender bucket from
      * a receiver thread is a total NO GO, because the bucket might use
@@ -830,32 +850,8 @@ static apr_status_t append_bucket(h2_bucket_beam *beam,
             apr_bucket_heap_make(b, data, len, NULL);
         }
     }
-    else if (APR_BUCKET_IS_FILE(b)) {
-        /* For file buckets the problem is their internal readpool that
-         * is used on the first read to allocate buffer/mmap.
-         * Since setting aside a file bucket will de-register the
-         * file cleanup function from the previous pool, we need to
-         * call that only from the sender thread.
-         *
-         * Currently, we do not handle file bucket with refcount > 1 as
-         * the beam is then not in complete control of the file's lifetime.
-         * Which results in the bug that a file get closed by the receiver
-         * while the sender or the beam still have buckets using it. 
-         * 
-         * Additionally, we allow callbacks to prevent beaming file
-         * handles across. The use case for this is to limit the number 
-         * of open file handles and rather use a less efficient beam
-         * transport. */
-        apr_bucket_file *bf = b->data;
-        apr_file_t *fd = bf->fd;
-        int can_beam = (bf->refcount.refcount == 1);
-        if (can_beam && beam->can_beam_fn) {
-            can_beam = beam->can_beam_fn(beam->can_beam_ctx, beam, fd);
-        }
-        if (can_beam) {
-            status = apr_bucket_setaside(b, beam->send_pool);
-        }
-        /* else: enter ENOTIMPL case below */
+    else if (APR_BUCKET_IS_FILE(b) && can_beam) {
+        status = apr_bucket_setaside(b, beam->send_pool);
     }
     
     if (status == APR_ENOTIMPL) {
@@ -865,12 +861,6 @@ static apr_status_t append_bucket(h2_bucket_beam *beam,
          * a counter example).
          * We do the read while in the sender thread, so that the bucket may
          * use pools/allocators safely. */
-        if (space_left < APR_BUCKET_BUFF_SIZE) {
-            space_left = APR_BUCKET_BUFF_SIZE;
-        }
-        if (space_left < b->length) {
-            apr_bucket_split(b, space_left);
-        }
         status = apr_bucket_read(b, &data, &len, APR_BLOCK_READ);
         if (status == APR_SUCCESS) {
             status = apr_bucket_setaside(b, beam->send_pool);
@@ -884,7 +874,7 @@ static apr_status_t append_bucket(h2_bucket_beam *beam,
     APR_BUCKET_REMOVE(b);
     H2_BLIST_INSERT_TAIL(&beam->send_list, b);
     beam->sent_bytes += b->length;
-    
+
     return APR_SUCCESS;
 }
 
@@ -904,7 +894,8 @@ apr_status_t h2_beam_send(h2_bucket_beam *beam,
                           apr_read_type_e block)
 {
     apr_bucket *b;
-    apr_status_t status = APR_SUCCESS;
+    apr_status_t rv = APR_SUCCESS;
+    apr_size_t space_left = 0;
     h2_beam_lock bl;
 
     /* Called from the sender thread to add buckets to the beam */
@@ -914,23 +905,31 @@ apr_status_t h2_beam_send(h2_bucket_beam *beam,
         
         if (beam->aborted) {
             move_to_hold(beam, sender_bb);
-            status = APR_ECONNABORTED;
+            rv = APR_ECONNABORTED;
         }
         else if (sender_bb) {
-            int force_report = !APR_BRIGADE_EMPTY(sender_bb); 
-            while (!APR_BRIGADE_EMPTY(sender_bb) && status == APR_SUCCESS) {
+            int force_report = !APR_BRIGADE_EMPTY(sender_bb);
+            
+            space_left = calc_space_left(beam);
+            while (!APR_BRIGADE_EMPTY(sender_bb) && APR_SUCCESS == rv) {
+                if (space_left <= 0) {
+                    report_prod_io(beam, force_report, &bl);
+                    rv = wait_not_full(beam, block, &space_left, &bl);
+                    if (APR_SUCCESS != rv) {
+                        break;
+                    }
+                }
                 b = APR_BRIGADE_FIRST(sender_bb);
-                status = append_bucket(beam, b, block, &bl);
+                rv = append_bucket(beam, b, block, &space_left, &bl);
             }
+            
             report_prod_io(beam, force_report, &bl);
-            if (beam->cond) {
-                apr_thread_cond_broadcast(beam->cond);
-            }
+            apr_thread_cond_broadcast(beam->change);
         }
         report_consumption(beam, &bl);
         leave_yellow(beam, &bl);
     }
-    return status;
+    return rv;
 }
 
 apr_status_t h2_beam_receive(h2_bucket_beam *beam, 
@@ -942,11 +941,16 @@ apr_status_t h2_beam_receive(h2_bucket_beam *beam,
     apr_bucket *bsender, *brecv, *ng;
     int transferred = 0;
     apr_status_t status = APR_SUCCESS;
-    apr_off_t remain = readbytes;
+    apr_off_t remain;
     int transferred_buckets = 0;
     
     /* Called from the receiver thread to take buckets from the beam */
     if (enter_yellow(beam, &bl) == APR_SUCCESS) {
+        if (readbytes <= 0) {
+            readbytes = APR_SIZE_MAX;
+        }
+        remain = readbytes;
+        
 transfer:
         if (beam->aborted) {
             recv_buffer_cleanup(beam, &bl);
@@ -955,11 +959,12 @@ transfer:
         }
 
         /* transfer enough buckets from our receiver brigade, if we have one */
-        while (beam->recv_buffer
-               && !APR_BRIGADE_EMPTY(beam->recv_buffer)
-               && (readbytes <= 0 || remain >= 0)) {
+        while (remain >= 0 
+               && beam->recv_buffer 
+               && !APR_BRIGADE_EMPTY(beam->recv_buffer)) {
+               
             brecv = APR_BRIGADE_FIRST(beam->recv_buffer);
-            if (readbytes > 0 && brecv->length > 0 && remain <= 0) {
+            if (brecv->length > 0 && remain <= 0) {
                 break;
             }            
             APR_BUCKET_REMOVE(brecv);
@@ -970,11 +975,11 @@ transfer:
 
         /* transfer from our sender brigade, transforming sender buckets to
          * receiver ones until we have enough */
-        while (!H2_BLIST_EMPTY(&beam->send_list) && (readbytes <= 0 || remain >= 0)) {
-            bsender = H2_BLIST_FIRST(&beam->send_list);
+        while (remain >= 0 && !H2_BLIST_EMPTY(&beam->send_list)) {
+               
             brecv = NULL;
-            
-            if (readbytes > 0 && bsender->length > 0 && remain <= 0) {
+            bsender = H2_BLIST_FIRST(&beam->send_list);            
+            if (bsender->length > 0 && remain <= 0) {
                 break;
             }
                         
@@ -1020,11 +1025,12 @@ transfer:
                  * been handed out. See also PR 59348 */
                 apr_bucket_file_enable_mmap(ng, 0);
 #endif
-                remain -= bsender->length;
-                ++transferred;
                 APR_BUCKET_REMOVE(bsender);
                 H2_BLIST_INSERT_TAIL(&beam->hold_list, bsender);
+
+                remain -= bsender->length;
                 ++transferred;
+                ++transferred_buckets;
                 continue;
             }
             else {
@@ -1041,6 +1047,7 @@ transfer:
              * receiver bucket references it any more. */
             APR_BUCKET_REMOVE(bsender);
             H2_BLIST_INSERT_TAIL(&beam->hold_list, bsender);
+            
             beam->received_bytes += bsender->length;
             ++transferred_buckets;
             
@@ -1063,8 +1070,8 @@ transfer:
             }
         }
 
-        if (readbytes > 0 && remain < 0) {
-            /* too much, put some back */
+        if (remain < 0) {
+            /* too much, put some back into out recv_buffer */
             remain = readbytes;
             for (brecv = APR_BRIGADE_FIRST(bb);
                  brecv != APR_BRIGADE_SENTINEL(bb);
@@ -1081,15 +1088,7 @@ transfer:
             }
         }
 
-        if (transferred_buckets > 0) {
-           if (beam->cons_ev_cb) { 
-               beam->cons_ev_cb(beam->cons_ctx, beam);
-            }
-        }
-        
-        if (beam->closed 
-            && (!beam->recv_buffer || APR_BRIGADE_EMPTY(beam->recv_buffer))
-            && H2_BLIST_EMPTY(&beam->send_list)) {
+        if (beam->closed && buffer_is_empty(beam)) {
             /* beam is closed and we have nothing more to receive */ 
             if (!beam->close_sent) {
                 apr_bucket *b = apr_bucket_eos_create(bb->bucket_alloc);
@@ -1100,28 +1099,23 @@ transfer:
             }
         }
         
-        if (transferred) {
-            if (beam->cond) {
-                apr_thread_cond_broadcast(beam->cond);
+        if (transferred_buckets > 0) {
+           if (beam->cons_ev_cb) { 
+               beam->cons_ev_cb(beam->cons_ctx, beam);
             }
-            status = APR_SUCCESS;
         }
-        else if (beam->closed) {
-            status = APR_EOF;
+        
+        if (transferred) {
+            apr_thread_cond_broadcast(beam->change);
+            status = APR_SUCCESS;
         }
-        else if (block == APR_BLOCK_READ && bl.mutex && beam->cond) {
-            status = wait_cond(beam, bl.mutex);
+        else {
+            status = wait_not_empty(beam, block, bl.mutex);
             if (status != APR_SUCCESS) {
                 goto leave;
             }
             goto transfer;
         }
-        else {
-            if (beam->cond) {
-                apr_thread_cond_broadcast(beam->cond);
-            }
-            status = APR_EAGAIN;
-        }
 leave:        
         leave_yellow(beam, &bl);
     }
diff --git a/modules/http2/h2_bucket_beam.h b/modules/http2/h2_bucket_beam.h
index 64117ff..c48d153 100644
--- a/modules/http2/h2_bucket_beam.h
+++ b/modules/http2/h2_bucket_beam.h
@@ -64,13 +64,11 @@ typedef struct {
  * via the h2_beam_send(). It gives the beam to the green thread which then
  * can receive buckets into its own brigade via h2_beam_receive().
  *
- * Sending and receiving can happen concurrently, if a thread mutex is set
- * for the beam, see h2_beam_mutex_set.
+ * Sending and receiving can happen concurrently.
  *
  * The beam can limit the amount of data it accepts via the buffer_size. This
- * can also be adjusted during its lifetime. When the beam not only gets a 
- * mutex but als a condition variable (in h2_beam_mutex_set()), sends and
- * receives can be done blocking. A timeout can be set for such blocks.
+ * can also be adjusted during its lifetime. Sends and receives can be done blocking. 
+ * A timeout can be set for such blocks.
  *
  * Care needs to be taken when terminating the beam. The beam registers at
  * the pool it was created with and will cleanup after itself. However, if
@@ -190,9 +188,7 @@ struct h2_bucket_beam {
     unsigned int tx_mem_limits : 1; /* only memory size counts on transfers */
 
     struct apr_thread_mutex_t *lock;
-    struct apr_thread_cond_t *cond;
-    void *m_ctx;
-    h2_beam_mutex_enter *m_enter;
+    struct apr_thread_cond_t *change;
     
     apr_off_t cons_bytes_reported;    /* amount of bytes reported as consumed */
     h2_beam_ev_callback *cons_ev_cb;
@@ -315,13 +311,6 @@ int h2_beam_is_closed(h2_bucket_beam *beam);
  */
 apr_status_t h2_beam_wait_empty(h2_bucket_beam *beam, apr_read_type_e block);
 
-void h2_beam_mutex_set(h2_bucket_beam *beam, 
-                       h2_beam_mutex_enter m_enter,
-                       void *m_ctx);
-
-void h2_beam_mutex_enable(h2_bucket_beam *beam);
-void h2_beam_mutex_disable(h2_bucket_beam *beam);
-
 /** 
  * Set/get the timeout for blocking read/write operations. Only works
  * if a mutex has been set for the beam.
diff --git a/modules/http2/h2_mplx.c b/modules/http2/h2_mplx.c
index 204e954..fe73cce 100644
--- a/modules/http2/h2_mplx.c
+++ b/modules/http2/h2_mplx.c
@@ -543,9 +543,6 @@ static apr_status_t out_open(h2_mplx *m, int stream_id, h2_bucket_beam *beam)
         h2_beam_on_file_beam(stream->output, h2_beam_no_files, NULL);
     }
     
-    /* time to protect the beam against multi-threaded use */
-    h2_beam_mutex_enable(stream->output);
-    
     /* we might see some file buckets in the output, see
      * if we have enough handles reserved. */
     check_data_for(m, stream, 0);
@@ -853,10 +850,6 @@ static void task_done(h2_mplx *m, h2_task *task, h2_req_engine *ngn)
                           H2_STRM_MSG(stream, "task_done, stream open")); 
             if (stream->input) {
                 h2_beam_leave(stream->input);
-                h2_beam_mutex_disable(stream->input);
-            }
-            if (stream->output) {
-                h2_beam_mutex_disable(stream->output);
             }
 
             /* more data will not arrive, resume the stream */
@@ -869,10 +862,6 @@ static void task_done(h2_mplx *m, h2_task *task, h2_req_engine *ngn)
                       H2_STRM_MSG(stream, "task_done, in hold"));
         if (stream->input) {
             h2_beam_leave(stream->input);
-            h2_beam_mutex_disable(stream->input);
-        }
-        if (stream->output) {
-            h2_beam_mutex_disable(stream->output);
         }
         stream_joined(m, stream);
     }
diff --git a/modules/http2/h2_stream.c b/modules/http2/h2_stream.c
index 925f3d6..1e87b1c 100644
--- a/modules/http2/h2_stream.c
+++ b/modules/http2/h2_stream.c
@@ -774,20 +774,20 @@ static apr_bucket *get_first_headers_bucket(apr_bucket_brigade *bb)
     return NULL;
 }
 
-static apr_status_t add_data(h2_stream *stream, apr_off_t requested,
-                             apr_off_t *plen, int *peos, int *complete, 
-                             h2_headers **pheaders)
+static apr_status_t add_buffered_data(h2_stream *stream, apr_off_t requested,
+                                      apr_off_t *plen, int *peos, int *is_all, 
+                                      h2_headers **pheaders)
 {
     apr_bucket *b, *e;
     
     *peos = 0;
     *plen = 0;
-    *complete = 0;
+    *is_all = 0;
     if (pheaders) {
         *pheaders = NULL;
     }
 
-    H2_STREAM_OUT_LOG(APLOG_TRACE2, stream, "add_data");
+    H2_STREAM_OUT_LOG(APLOG_TRACE2, stream, "add_buffered_data");
     b = APR_BRIGADE_FIRST(stream->out_buffer);
     while (b != APR_BRIGADE_SENTINEL(stream->out_buffer)) {
         e = APR_BUCKET_NEXT(b);
@@ -833,7 +833,7 @@ static apr_status_t add_data(h2_stream *stream, apr_off_t requested,
         }
         b = e;
     }
-    *complete = 1;
+    *is_all = 1;
     return APR_SUCCESS;
 }
 
@@ -865,7 +865,7 @@ apr_status_t h2_stream_out_prepare(h2_stream *stream, apr_off_t *plen,
     requested = (*plen > 0)? H2MIN(*plen, max_chunk) : max_chunk;
     
     /* count the buffered data until eos or a headers bucket */
-    status = add_data(stream, requested, plen, peos, &complete, pheaders);
+    status = add_buffered_data(stream, requested, plen, peos, &complete, pheaders);
     
     if (status == APR_EAGAIN) {
         /* TODO: ugly, someone needs to retrieve the response first */
@@ -882,28 +882,38 @@ apr_status_t h2_stream_out_prepare(h2_stream *stream, apr_off_t *plen,
         return APR_SUCCESS;
     }
     
+    /* If there we do not have enough buffered data to satisfy the requested
+     * length *and* we counted the _complete_ buffer (and did not stop in the middle
+     * because of meta data there), lets see if we can read more from the
+     * output beam */
     missing = H2MIN(requested, stream->max_mem) - *plen;
     if (complete && !*peos && missing > 0) {
+        apr_status_t rv = APR_EOF;
+        
         if (stream->output) {
             H2_STREAM_OUT_LOG(APLOG_TRACE2, stream, "pre");
-            status = h2_beam_receive(stream->output, stream->out_buffer, 
-                                     APR_NONBLOCK_READ, 
-                                     stream->max_mem - *plen);
+            rv = h2_beam_receive(stream->output, stream->out_buffer, 
+                                 APR_NONBLOCK_READ, stream->max_mem - *plen);
             H2_STREAM_OUT_LOG(APLOG_TRACE2, stream, "post");
         }
-        else {
-            status = APR_EOF;
-        }
         
-        if (APR_STATUS_IS_EOF(status)) {
+        if (rv == APR_SUCCESS) {
+            /* count the buffer again, now that we have read output */
+            status = add_buffered_data(stream, requested, plen, peos, &complete, pheaders);
+        }
+        else if (APR_STATUS_IS_EOF(rv)) {
             apr_bucket *eos = apr_bucket_eos_create(c->bucket_alloc);
             APR_BRIGADE_INSERT_TAIL(stream->out_buffer, eos);
             *peos = 1;
-            status = APR_SUCCESS;
         }
-        else if (status == APR_SUCCESS) {
-            /* do it again, now that we have gotten more */
-            status = add_data(stream, requested, plen, peos, &complete, pheaders);
+        else if (APR_STATUS_IS_EAGAIN(rv)) {
+            /* we set this is the status of this call only if there
+             * is no buffered data, see check below */
+        }
+        else {
+            /* real error reading. Give this back directly, even though
+             * we may have something buffered. */
+            status = rv;
         }
     }
     
diff --git a/modules/http2/h2_task.c b/modules/http2/h2_task.c
index 1ef0d9a..1f2f4c2 100644
--- a/modules/http2/h2_task.c
+++ b/modules/http2/h2_task.c
@@ -129,7 +129,7 @@ static apr_status_t slave_out(h2_task *task, ap_filter_t* f,
                               apr_bucket_brigade* bb)
 {
     apr_bucket *b;
-    apr_status_t status = APR_SUCCESS;
+    apr_status_t rv = APR_SUCCESS;
     int flush = 0, blocking;
     
     if (task->frozen) {
@@ -148,17 +148,16 @@ static apr_status_t slave_out(h2_task *task, ap_filter_t* f,
         return APR_SUCCESS;
     }
 
+send:
     /* we send block once we opened the output, so someone is there
      * reading it *and* the task is not assigned to a h2_req_engine */
     blocking = (!task->assigned && task->output.opened);
-    if (!task->output.opened) {
-        for (b = APR_BRIGADE_FIRST(bb);
-             b != APR_BRIGADE_SENTINEL(bb);
-             b = APR_BUCKET_NEXT(b)) {
-            if (APR_BUCKET_IS_FLUSH(b)) {
-                flush = 1;
-                break;
-            }
+    for (b = APR_BRIGADE_FIRST(bb);
+         b != APR_BRIGADE_SENTINEL(bb);
+         b = APR_BUCKET_NEXT(b)) {
+        if (APR_BUCKET_IS_FLUSH(b) || APR_BUCKET_IS_EOS(b) || AP_BUCKET_IS_EOR(b)) {
+            flush = 1;
+            break;
         }
     }
     
@@ -166,32 +165,48 @@ static apr_status_t slave_out(h2_task *task, ap_filter_t* f,
         /* still have data buffered from previous attempt.
          * setaside and append new data and try to pass the complete data */
         if (!APR_BRIGADE_EMPTY(bb)) {
-            status = ap_save_brigade(f, &task->output.bb, &bb, task->pool);
+            if (APR_SUCCESS != (rv = ap_save_brigade(f, &task->output.bb, &bb, task->pool))) {
+                goto out;
+            }
         }
-        if (status == APR_SUCCESS) {
-            status = send_out(task, task->output.bb, blocking);
-        } 
+        rv = send_out(task, task->output.bb, blocking);
     }
     else {
-        /* no data buffered here, try to pass the brigade directly */
-        status = send_out(task, bb, blocking); 
-        if (status == APR_SUCCESS && !APR_BRIGADE_EMPTY(bb)) {
-            /* could not write all, buffer the rest */
-            ap_log_cerror(APLOG_MARK, APLOG_DEBUG, status, task->c, APLOGNO(03405)
-                          "h2_slave_out(%s): saving brigade", 
-                          task->id);
-            status = ap_save_brigade(f, &task->output.bb, &bb, task->pool);
-            flush = 1;
+        /* no data buffered previously, pass brigade directly */
+        rv = send_out(task, bb, blocking);
+
+        if (APR_SUCCESS == rv && !APR_BRIGADE_EMPTY(bb)) {
+            /* output refused to buffer it all, time to open? */
+            if (!task->output.opened && APR_SUCCESS == (rv = open_output(task))) {
+                /* Make another attempt to send the data. With the output open,
+                 * the call might be blocking and send all data, so we do not need
+                 * to save the brigade */
+                goto send;
+            }
+            else if (blocking && flush) {
+                /* Need to keep on doing this. */
+                goto send;
+            }
+            
+            if (APR_SUCCESS == rv) {
+                /* could not write all, buffer the rest */
+                ap_log_cerror(APLOG_MARK, APLOG_DEBUG, rv, task->c, APLOGNO(03405)
+                              "h2_slave_out(%s): saving brigade", task->id);
+                ap_assert(NULL);
+                rv = ap_save_brigade(f, &task->output.bb, &bb, task->pool);
+                flush = 1;
+            }
         }
     }
     
-    if (status == APR_SUCCESS && !task->output.opened && flush) {
+    if (APR_SUCCESS == rv && !task->output.opened && flush) {
         /* got a flush or could not write all, time to tell someone to read */
-        status = open_output(task);
+        rv = open_output(task);
     }
-    ap_log_cerror(APLOG_MARK, APLOG_TRACE2, status, task->c, 
+out:
+    ap_log_cerror(APLOG_MARK, APLOG_TRACE2, rv, task->c, 
                   "h2_slave_out(%s): slave_out leave", task->id);    
-    return status;
+    return rv;
 }
 
 static apr_status_t output_finish(h2_task *task)
@@ -598,10 +613,6 @@ apr_status_t h2_task_do(h2_task *task, apr_thread_t *thread, int worker_id)
     h2_ctx_create_for(c, task);
     apr_table_setn(c->notes, H2_TASK_ID_NOTE, task->id);
 
-    if (task->input.beam) {
-        h2_beam_mutex_enable(task->input.beam);
-    }
-    
     h2_slave_run_pre_connection(c, ap_get_conn_socket(c));            
 
     task->input.bb = apr_brigade_create(task->pool, c->bucket_alloc);
diff --git a/modules/http2/h2_util.c b/modules/http2/h2_util.c
index e1879cb..47dcdf5 100644
--- a/modules/http2/h2_util.c
+++ b/modules/http2/h2_util.c
@@ -112,6 +112,8 @@ void h2_util_camel_case_header(char *s, size_t len)
     }
 }
 
+/* base64 url encoding ****************************************************************************/
+
 static const int BASE64URL_UINT6[] = {
 /*   0   1   2   3   4   5   6   7   8   9   a   b   c   d   e   f        */
     -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, /*  0 */
@@ -174,6 +176,7 @@ apr_size_t h2_util_base64url_decode(const char **decoded, const char *encoded,
             n = ((BASE64URL_UINT6[ e[mlen+0] ] << 18) +
                  (BASE64URL_UINT6[ e[mlen+1] ] << 12));
             *d++ = n >> 16;
+            remain = 1;
             break;
         case 3:
             n = ((BASE64URL_UINT6[ e[mlen+0] ] << 18) +
@@ -181,6 +184,7 @@ apr_size_t h2_util_base64url_decode(const char **decoded, const char *encoded,
                  (BASE64URL_UINT6[ e[mlen+2] ] << 6));
             *d++ = n >> 16;
             *d++ = n >> 8 & 0xffu;
+            remain = 2;
             break;
         default: /* do nothing */
             break;
@@ -189,78 +193,35 @@ apr_size_t h2_util_base64url_decode(const char **decoded, const char *encoded,
 }
 
 const char *h2_util_base64url_encode(const char *data, 
-                                     apr_size_t len, apr_pool_t *pool)
+                                     apr_size_t dlen, apr_pool_t *pool)
 {
-    apr_size_t mlen = ((len+2)/3)*3;
-    apr_size_t slen = (mlen/3)*4;
-    apr_size_t i;
+    long i, len = (int)dlen;
+    apr_size_t slen = ((dlen+2)/3)*4 + 1; /* 0 terminated */
     const unsigned char *udata = (const unsigned char*)data;
-    char *enc, *p = apr_pcalloc(pool, slen+1); /* 0 terminated */
+    char *enc, *p = apr_pcalloc(pool, slen);
     
     enc = p;
-    for (i = 0; i < mlen; i+= 3) {
+    for (i = 0; i < len-2; i+= 3) {
         *p++ = BASE64URL_CHARS[ (udata[i] >> 2) & 0x3fu ];
-        *p++ = BASE64URL_CHARS[ ((udata[i] << 4) + 
-                                 ((i+1 < len)? (udata[i+1] >> 4) : 0)) & 0x3fu ];
-        *p++ = BASE64URL_CHARS[ ((udata[i+1] << 2) + 
-                                 ((i+2 < len)? (udata[i+2] >> 6) : 0)) & 0x3fu ];
-        if (i+2 < len) {
-            *p++ = BASE64URL_CHARS[ udata[i+2] & 0x3fu ];
-        }
+        *p++ = BASE64URL_CHARS[ ((udata[i] << 4) + (udata[i+1] >> 4)) & 0x3fu ];
+        *p++ = BASE64URL_CHARS[ ((udata[i+1] << 2) + (udata[i+2] >> 6)) & 0x3fu ];
+        *p++ = BASE64URL_CHARS[ udata[i+2] & 0x3fu ];
     }
     
-    return enc;
-}
-
-int h2_util_contains_token(apr_pool_t *pool, const char *s, const char *token)
-{
-    char *c;
-    if (s) {
-        if (!apr_strnatcasecmp(s, token)) {   /* the simple life */
-            return 1;
-        }
-        
-        for (c = ap_get_token(pool, &s, 0); c && *c;
-             c = *s? ap_get_token(pool, &s, 0) : NULL) {
-            if (!apr_strnatcasecmp(c, token)) { /* seeing the token? */
-                return 1;
-            }
-            while (*s++ == ';') {            /* skip parameters */
-                ap_get_token(pool, &s, 0);
-            }
-            if (*s++ != ',') {               /* need comma separation */
-                return 0;
-            }
+    if (i < len) {
+        *p++ = BASE64URL_CHARS[ (udata[i] >> 2) & 0x3fu ];
+        if (i == (len - 1)) {
+            *p++ = BASE64URL_CHARS[ (udata[i] << 4) & 0x3fu ];
         }
-    }
-    return 0;
-}
-
-const char *h2_util_first_token_match(apr_pool_t *pool, const char *s, 
-                                      const char *tokens[], apr_size_t len)
-{
-    char *c;
-    apr_size_t i;
-    if (s && *s) {
-        for (c = ap_get_token(pool, &s, 0); c && *c;
-             c = *s? ap_get_token(pool, &s, 0) : NULL) {
-            for (i = 0; i < len; ++i) {
-                if (!apr_strnatcasecmp(c, tokens[i])) {
-                    return tokens[i];
-                }
-            }
-            while (*s++ == ';') {            /* skip parameters */
-                ap_get_token(pool, &s, 0);
-            }
-            if (*s++ != ',') {               /* need comma separation */
-                return 0;
-            }
+        else {
+            *p++ = BASE64URL_CHARS[ ((udata[i] << 4) + (udata[i+1] >> 4)) & 0x3fu ];
+            *p++ = BASE64URL_CHARS[ (udata[i+1] << 2) & 0x3fu ];
         }
     }
-    return NULL;
+    *p++ = '\0';
+    return enc;
 }
 
-
 /*******************************************************************************
  * ihash - hash for structs with int identifier
  ******************************************************************************/
diff --git a/modules/http2/h2_util.h b/modules/http2/h2_util.h
index b2c25f6..01ccccd 100644
--- a/modules/http2/h2_util.h
+++ b/modules/http2/h2_util.h
@@ -337,15 +337,6 @@ unsigned char h2_log2(int n);
  */
 apr_size_t h2_util_table_bytes(apr_table_t *t, apr_size_t pair_extra);
 
-/**
- * Return != 0 iff the string s contains the token, as specified in
- * HTTP header syntax, rfc7230.
- */
-int h2_util_contains_token(apr_pool_t *pool, const char *s, const char *token);
-
-const char *h2_util_first_token_match(apr_pool_t *pool, const char *s, 
-                                      const char *tokens[], apr_size_t len);
-
 /** Match a header value against a string constance, case insensitive */
 #define H2_HD_MATCH_LIT(l, name, nlen)  \
     ((nlen == sizeof(l) - 1) && !apr_strnatcasecmp(l, name))
diff --git a/modules/http2/h2_version.h b/modules/http2/h2_version.h
index ca0a13a..d843f25 100644
--- a/modules/http2/h2_version.h
+++ b/modules/http2/h2_version.h
@@ -26,7 +26,7 @@
  * @macro
  * Version number of the http2 module as c string
  */
-#define MOD_HTTP2_VERSION "1.10.7"
+#define MOD_HTTP2_VERSION "1.10.12"
 
 /**
  * @macro
@@ -34,7 +34,7 @@
  * release. This is a 24 bit number with 8 bits for major number, 8 bits
  * for minor and 8 bits for patch. Version 1.2.3 becomes 0x010203.
  */
-#define MOD_HTTP2_VERSION_NUM 0x010a06
+#define MOD_HTTP2_VERSION_NUM 0x010a0b
 
 
 #endif /* mod_h2_h2_version_h */
diff --git a/modules/http2/h2_workers.c b/modules/http2/h2_workers.c
index 5abddd4..1276250 100644
--- a/modules/http2/h2_workers.c
+++ b/modules/http2/h2_workers.c
@@ -98,6 +98,8 @@ static apr_status_t activate_slot(h2_workers *workers, h2_slot *slot)
         }
     }
     
+    ap_log_error(APLOG_MARK, APLOG_TRACE2, 0, workers->s,
+                 "h2_workers: new thread for slot %d", slot->id); 
     /* thread will either immediately start work or add itself
      * to the idle queue */
     apr_thread_create(&slot->thread, workers->thread_attr, slot_run, slot, 
diff --git a/modules/mappers/mod_rewrite.c b/modules/mappers/mod_rewrite.c
index 3d1fe3c..05414c4 100644
--- a/modules/mappers/mod_rewrite.c
+++ b/modules/mappers/mod_rewrite.c
@@ -265,6 +265,8 @@ typedef struct {
     const char *dbdq;              /* SQL SELECT statement for rewritemap */
     const char *checkfile2;        /* filename to check for map existence
                                       NULL if only one file               */
+    const char *user;              /* run RewriteMap program as this user */
+    const char *group;             /* run RewriteMap program as this group */
 } rewritemap_entry;
 
 /* special pattern types for RewriteCond */
@@ -1191,6 +1193,7 @@ static void rewrite_child_errfn(apr_pool_t *p, apr_status_t err,
 
 static apr_status_t rewritemap_program_child(apr_pool_t *p,
                                              const char *progname, char **argv,
+                                             const char *user, const char *group,
                                              apr_file_t **fpout,
                                              apr_file_t **fpin)
 {
@@ -1203,6 +1206,8 @@ static apr_status_t rewritemap_program_child(apr_pool_t *p,
                                                   APR_FULL_BLOCK, APR_NO_PIPE))
         && APR_SUCCESS == (rc=apr_procattr_dir_set(procattr,
                                              ap_make_dirstr_parent(p, argv[0])))
+        && (!user || APR_SUCCESS == (rc=apr_procattr_user_set(procattr, user, "")))
+        && (!group || APR_SUCCESS == (rc=apr_procattr_group_set(procattr, group)))
         && APR_SUCCESS == (rc=apr_procattr_cmdtype_set(procattr, APR_PROGRAM))
         && APR_SUCCESS == (rc=apr_procattr_child_errfn_set(procattr,
                                                            rewrite_child_errfn))
@@ -1260,6 +1265,7 @@ static apr_status_t run_rewritemap_programs(server_rec *s, apr_pool_t *p)
         }
 
         rc = rewritemap_program_child(p, map->argv[0], map->argv,
+                                      map->user, map->group,
                                       &fpout, &fpin);
         if (rc != APR_SUCCESS || fpin == NULL || fpout == NULL) {
             ap_log_error(APLOG_MARK, APLOG_ERR, rc, s, APLOGNO(00654)
@@ -1796,7 +1802,10 @@ static const char *lookup_header(const char *name, rewrite_ctx *ctx)
 {
     const char *val = apr_table_get(ctx->r->headers_in, name);
 
-    if (val) {
+    /* Skip the 'Vary: Host' header combination
+     * as indicated in rfc7231 section-7.1.4
+     */
+    if (val && strcasecmp(name, "Host") != 0) {
         ctx->vary_this = ctx->vary_this
                          ? apr_pstrcat(ctx->r->pool, ctx->vary_this, ", ",
                                        name, NULL)
@@ -3048,7 +3057,7 @@ static const char *cmd_rewriteoptions(cmd_parms *cmd,
 }
 
 static const char *cmd_rewritemap(cmd_parms *cmd, void *dconf, const char *a1,
-                                  const char *a2)
+                                  const char *a2, const char *a3)
 {
     rewrite_server_conf *sconf;
     rewritemap_entry *newmap;
@@ -3154,6 +3163,11 @@ static const char *cmd_rewritemap(cmd_parms *cmd, void *dconf, const char *a1,
 
         newmap->type      = MAPTYPE_PRG;
         newmap->checkfile = newmap->argv[0];
+        if (a3) {
+            char *tok_cntx;
+            newmap->user = apr_strtok(apr_pstrdup(cmd->pool, a3), ":", &tok_cntx);
+            newmap->group = apr_strtok(NULL, ":", &tok_cntx);
+        }
     }
     else if (strncasecmp(a2, "int:", 4) == 0) {
         newmap->type      = MAPTYPE_INT;
@@ -5265,8 +5279,8 @@ static const command_rec command_table[] = {
                      "an input string and a to be applied regexp-pattern"),
     AP_INIT_RAW_ARGS("RewriteRule",     cmd_rewriterule,     NULL, OR_FILEINFO,
                      "an URL-applied regexp-pattern and a substitution URL"),
-    AP_INIT_TAKE2(   "RewriteMap",      cmd_rewritemap,      NULL, RSRC_CONF,
-                     "a mapname and a filename"),
+    AP_INIT_TAKE23(   "RewriteMap",      cmd_rewritemap,      NULL, RSRC_CONF,
+                     "a mapname and a filename and options"),
     { NULL }
 };
 
diff --git a/modules/mappers/mod_speling.c b/modules/mappers/mod_speling.c
index a9f3651..3e97423 100644
--- a/modules/mappers/mod_speling.c
+++ b/modules/mappers/mod_speling.c
@@ -488,10 +488,10 @@ static int check_speling(request_rec *r)
             if (ref != NULL) {
                 *(const char **)apr_array_push(t) =
                                "Please consider informing the owner of the "
-                               "<a href=\"";
-                *(const char **)apr_array_push(t) = ap_escape_uri(sub_pool, ref);
-                *(const char **)apr_array_push(t) = "\">referring page</a> "
-                               "about the broken link.\n";
+                               "referring page <tt>";
+                *(const char **)apr_array_push(t) = ap_escape_html(sub_pool, ref);
+                *(const char **)apr_array_push(t) =
+                               "</tt> about the broken link.\n";
             }
 
 
diff --git a/modules/metadata/mod_unique_id.c b/modules/metadata/mod_unique_id.c
index 8bd858f..0b05fbf 100644
--- a/modules/metadata/mod_unique_id.c
+++ b/modules/metadata/mod_unique_id.c
@@ -31,14 +31,11 @@
 #include "http_log.h"
 #include "http_protocol.h"  /* for ap_hook_post_read_request */
 
-#if APR_HAVE_UNISTD_H
-#include <unistd.h>         /* for getpid() */
-#endif
+#define ROOT_SIZE 10
 
 typedef struct {
     unsigned int stamp;
-    unsigned int in_addr;
-    unsigned int pid;
+    char root[ROOT_SIZE];
     unsigned short counter;
     unsigned int thread_index;
 } unique_id_rec;
@@ -64,20 +61,15 @@ typedef struct {
  * gethostbyname (gethostname()) is unique across all the machines at the
  * "site".
  *
- * We also further assume that pids fit in 32-bits.  If something uses more
- * than 32-bits, the fix is trivial, but it requires the unrolled uuencoding
- * loop to be extended.  * A similar fix is needed to support multithreaded
- * servers, using a pid/tid combo.
- *
- * Together, the in_addr and pid are assumed to absolutely uniquely identify
- * this one child from all other currently running children on all servers
- * (including this physical server if it is running multiple httpds) from each
+ * The root is assumed to absolutely uniquely identify this one child
+ * from all other currently running children on all servers (including
+ * this physical server if it is running multiple httpds) from each
  * other.
  *
- * The stamp and counter are used to distinguish all hits for a particular
- * (in_addr,pid) pair.  The stamp is updated using r->request_time,
- * saving cpu cycles.  The counter is never reset, and is used to permit up to
- * 64k requests in a single second by a single child.
+ * The stamp and counter are used to distinguish all hits for a
+ * particular root.  The stamp is updated using r->request_time,
+ * saving cpu cycles.  The counter is never reset, and is used to
+ * permit up to 64k requests in a single second by a single child.
  *
  * The 144-bits of unique_id_rec are encoded using the alphabet
  * [A-Za-z0-9 at -], resulting in 24 bytes of printable characters.  That is then
@@ -92,7 +84,7 @@ typedef struct {
  * module change.
  *
  * It is highly desirable that identifiers exist for "eternity".  But future
- * needs (such as much faster webservers, moving to 64-bit pids, or moving to a
+ * needs (such as much faster webservers, or moving to a
  * multithreaded server) may dictate a need to change the contents of
  * unique_id_rec.  Such a future implementation should ensure that the first
  * field is still a time_t stamp.  By doing that, it is possible for a site to
@@ -100,7 +92,15 @@ typedef struct {
  * wait one entire second, and then start all of their new-servers.  This
  * procedure will ensure that the new space of identifiers is completely unique
  * from the old space.  (Since the first four unencoded bytes always differ.)
+ *
+ * Note: previous implementations used 32-bits of IP address plus pid
+ * in place of the PRNG output in the "root" field.  This was
+ * insufficient for IPv6-only hosts, required working DNS to determine
+ * a unique IP address (fragile), and needed a [0, 1) second sleep
+ * call at startup to avoid pid reuse.  Use of the PRNG avoids all
+ * these issues.
  */
+
 /*
  * Sun Jun  7 05:43:49 CEST 1998 -- Alvaro
  * More comments:
@@ -116,8 +116,6 @@ typedef struct {
  * htonl/ntohl. Well, this shouldn't be a problem till year 2106.
  */
 
-static unsigned global_in_addr;
-
 /*
  * XXX: We should have a per-thread counter and not use cur_unique_id.counter
  * XXX: in all threads, because this is bad for performance on multi-processor
@@ -129,7 +127,7 @@ static unique_id_rec cur_unique_id;
 /*
  * Number of elements in the structure unique_id_rec.
  */
-#define UNIQUE_ID_REC_MAX 5
+#define UNIQUE_ID_REC_MAX 4
 
 static unsigned short unique_id_rec_offset[UNIQUE_ID_REC_MAX],
                       unique_id_rec_size[UNIQUE_ID_REC_MAX],
@@ -138,113 +136,32 @@ static unsigned short unique_id_rec_offset[UNIQUE_ID_REC_MAX],
 
 static int unique_id_global_init(apr_pool_t *p, apr_pool_t *plog, apr_pool_t *ptemp, server_rec *main_server)
 {
-    char str[APRMAXHOSTLEN + 1];
-    apr_status_t rv;
-    char *ipaddrstr;
-    apr_sockaddr_t *sockaddr;
-
     /*
      * Calculate the sizes and offsets in cur_unique_id.
      */
     unique_id_rec_offset[0] = APR_OFFSETOF(unique_id_rec, stamp);
     unique_id_rec_size[0] = sizeof(cur_unique_id.stamp);
-    unique_id_rec_offset[1] = APR_OFFSETOF(unique_id_rec, in_addr);
-    unique_id_rec_size[1] = sizeof(cur_unique_id.in_addr);
-    unique_id_rec_offset[2] = APR_OFFSETOF(unique_id_rec, pid);
-    unique_id_rec_size[2] = sizeof(cur_unique_id.pid);
-    unique_id_rec_offset[3] = APR_OFFSETOF(unique_id_rec, counter);
-    unique_id_rec_size[3] = sizeof(cur_unique_id.counter);
-    unique_id_rec_offset[4] = APR_OFFSETOF(unique_id_rec, thread_index);
-    unique_id_rec_size[4] = sizeof(cur_unique_id.thread_index);
+    unique_id_rec_offset[1] = APR_OFFSETOF(unique_id_rec, root);
+    unique_id_rec_size[1] = sizeof(cur_unique_id.root);
+    unique_id_rec_offset[2] = APR_OFFSETOF(unique_id_rec, counter);
+    unique_id_rec_size[2] = sizeof(cur_unique_id.counter);
+    unique_id_rec_offset[3] = APR_OFFSETOF(unique_id_rec, thread_index);
+    unique_id_rec_size[3] = sizeof(cur_unique_id.thread_index);
     unique_id_rec_total_size = unique_id_rec_size[0] + unique_id_rec_size[1] +
-                               unique_id_rec_size[2] + unique_id_rec_size[3] +
-                               unique_id_rec_size[4];
+                               unique_id_rec_size[2] + unique_id_rec_size[3];
 
     /*
      * Calculate the size of the structure when encoded.
      */
     unique_id_rec_size_uu = (unique_id_rec_total_size*8+5)/6;
 
-    /*
-     * Now get the global in_addr.  Note that it is not sufficient to use one
-     * of the addresses from the main_server, since those aren't as likely to
-     * be unique as the physical address of the machine
-     */
-    if ((rv = apr_gethostname(str, sizeof(str) - 1, p)) != APR_SUCCESS) {
-        ap_log_error(APLOG_MARK, APLOG_ALERT, rv, main_server, APLOGNO(01563)
-          "unable to find hostname of the server");
-        return HTTP_INTERNAL_SERVER_ERROR;
-    }
-
-    if ((rv = apr_sockaddr_info_get(&sockaddr, str, AF_INET, 0, 0, p)) == APR_SUCCESS) {
-        global_in_addr = sockaddr->sa.sin.sin_addr.s_addr;
-    }
-    else {
-        ap_log_error(APLOG_MARK, APLOG_ALERT, rv, main_server, APLOGNO(01564)
-                    "unable to find IPv4 address of \"%s\"", str);
-#if APR_HAVE_IPV6
-        if ((rv = apr_sockaddr_info_get(&sockaddr, str, AF_INET6, 0, 0, p)) == APR_SUCCESS) {
-            memcpy(&global_in_addr,
-                   (char *)sockaddr->ipaddr_ptr + sockaddr->ipaddr_len - sizeof(global_in_addr),
-                   sizeof(global_in_addr));
-            ap_log_error(APLOG_MARK, APLOG_ALERT, rv, main_server, APLOGNO(01565)
-                         "using low-order bits of IPv6 address "
-                         "as if they were unique");
-        }
-        else
-#endif
-        return HTTP_INTERNAL_SERVER_ERROR;
-    }
-
-    apr_sockaddr_ip_get(&ipaddrstr, sockaddr);
-    ap_log_error(APLOG_MARK, APLOG_INFO, 0, main_server, APLOGNO(01566) "using ip addr %s",
-                 ipaddrstr);
-
-    /*
-     * If the server is pummelled with restart requests we could possibly end
-     * up in a situation where we're starting again during the same second
-     * that has been used in previous identifiers.  Avoid that situation.
-     *
-     * In truth, for this to actually happen not only would it have to restart
-     * in the same second, but it would have to somehow get the same pids as
-     * one of the other servers that was running in that second. Which would
-     * mean a 64k wraparound on pids ... not very likely at all.
-     *
-     * But protecting against it is relatively cheap.  We just sleep into the
-     * next second.
-     */
-    apr_sleep(apr_time_from_sec(1) - apr_time_usec(apr_time_now()));
     return OK;
 }
 
 static void unique_id_child_init(apr_pool_t *p, server_rec *s)
 {
-    pid_t pid;
-
-    /*
-     * Note that we use the pid because it's possible that on the same
-     * physical machine there are multiple servers (i.e. using Listen). But
-     * it's guaranteed that none of them will share the same pids between
-     * children.
-     *
-     * XXX: for multithread this needs to use a pid/tid combo and probably
-     * needs to be expanded to 32 bits
-     */
-    pid = getpid();
-    cur_unique_id.pid = pid;
-
-    /*
-     * Test our assumption that the pid is 32-bits.  It's possible that
-     * 64-bit machines will declare pid_t to be 64 bits but only use 32
-     * of them.  It would have been really nice to test this during
-     * global_init ... but oh well.
-     */
-    if ((pid_t)cur_unique_id.pid != pid) {
-        ap_log_error(APLOG_MARK, APLOG_CRIT, 0, s, APLOGNO(01567)
-                    "oh no! pids are greater than 32-bits!  I'm broken!");
-    }
-
-    cur_unique_id.in_addr = global_in_addr;
+    ap_random_insecure_bytes(&cur_unique_id.root,
+                             sizeof(cur_unique_id.root));
 
     /*
      * If we use 0 as the initial counter we have a little less protection
@@ -253,13 +170,6 @@ static void unique_id_child_init(apr_pool_t *p, server_rec *s)
      */
     ap_random_insecure_bytes(&cur_unique_id.counter,
                              sizeof(cur_unique_id.counter));
-
-    /*
-     * We must always use network ordering for these bytes, so that
-     * identifiers are comparable between machines of different byte
-     * orderings.  Note in_addr is already in network order.
-     */
-    cur_unique_id.pid = htonl(cur_unique_id.pid);
 }
 
 /* NOTE: This is *NOT* the same encoding used by base64encode ... the last two
@@ -291,10 +201,8 @@ static const char *gen_unique_id(const request_rec *r)
     unsigned short counter;
     int i,j,k;
 
-    new_unique_id.in_addr = cur_unique_id.in_addr;
-    new_unique_id.pid = cur_unique_id.pid;
+    memcpy(&new_unique_id.root, &cur_unique_id.root, ROOT_SIZE);
     new_unique_id.counter = cur_unique_id.counter;
-
     new_unique_id.stamp = htonl((unsigned int)apr_time_sec(r->request_time));
     new_unique_id.thread_index = htonl((unsigned int)r->connection->id);
 
diff --git a/modules/proxy/balancers/mod_lbmethod_bybusyness.c b/modules/proxy/balancers/mod_lbmethod_bybusyness.c
index 67d53a3..30a8f55 100644
--- a/modules/proxy/balancers/mod_lbmethod_bybusyness.c
+++ b/modules/proxy/balancers/mod_lbmethod_bybusyness.c
@@ -141,7 +141,8 @@ static const proxy_balancer_method bybusyness =
     &find_best_bybusyness,
     NULL,
     &reset,
-    &age
+    &age,
+    NULL
 };
 
 static void register_hook(apr_pool_t *p)
diff --git a/modules/proxy/balancers/mod_lbmethod_byrequests.c b/modules/proxy/balancers/mod_lbmethod_byrequests.c
index 206fe92..83424ce 100644
--- a/modules/proxy/balancers/mod_lbmethod_byrequests.c
+++ b/modules/proxy/balancers/mod_lbmethod_byrequests.c
@@ -177,7 +177,8 @@ static const proxy_balancer_method byrequests =
     &find_best_byrequests,
     NULL,
     &reset,
-    &age
+    &age,
+    NULL
 };
 
 static void register_hook(apr_pool_t *p)
diff --git a/modules/proxy/balancers/mod_lbmethod_bytraffic.c b/modules/proxy/balancers/mod_lbmethod_bytraffic.c
index b3fe556..6cf2478 100644
--- a/modules/proxy/balancers/mod_lbmethod_bytraffic.c
+++ b/modules/proxy/balancers/mod_lbmethod_bytraffic.c
@@ -146,7 +146,8 @@ static const proxy_balancer_method bytraffic =
     &find_best_bytraffic,
     NULL,
     &reset,
-    &age
+    &age,
+    NULL
 };
 
 static void register_hook(apr_pool_t *p)
diff --git a/modules/proxy/balancers/mod_lbmethod_heartbeat.c b/modules/proxy/balancers/mod_lbmethod_heartbeat.c
index 8b52eca..640bddb 100644
--- a/modules/proxy/balancers/mod_lbmethod_heartbeat.c
+++ b/modules/proxy/balancers/mod_lbmethod_heartbeat.c
@@ -358,7 +358,8 @@ static const proxy_balancer_method heartbeat =
     &find_best_hb,
     NULL,
     &reset,
-    &age
+    &age,
+    NULL
 };
 
 static int lb_hb_init(apr_pool_t *p, apr_pool_t *plog,
diff --git a/modules/proxy/mod_proxy.c b/modules/proxy/mod_proxy.c
index f6fb473..d7f79cf 100644
--- a/modules/proxy/mod_proxy.c
+++ b/modules/proxy/mod_proxy.c
@@ -103,8 +103,9 @@ static const char *set_worker_param(apr_pool_t *p,
         /* Normalized load factor. Used with BalancerMember,
          * it is a number between 1 and 100.
          */
-        ival = atoi(val);
-        if (ival < 1 || ival > 100)
+        double fval = atof(val);
+        ival = fval * 100.0;
+        if (ival < 100 || ival > 10000)
             return "LoadFactor must be a number between 1..100";
         worker->s->lbfactor = ival;
     }
@@ -1268,10 +1269,11 @@ static int proxy_handler(request_rec *r)
 
     if (DECLINED == access_status) {
         ap_log_rerror(APLOG_MARK, APLOG_WARNING, 0, r, APLOGNO(01144)
-                      "No protocol handler was valid for the URL %s. "
+                      "No protocol handler was valid for the URL %s " 
+                      "(scheme '%s'). "
                       "If you are using a DSO version of mod_proxy, make sure "
                       "the proxy submodules are included in the configuration "
-                      "using LoadModule.", r->uri);
+                      "using LoadModule.", r->uri, scheme);
         access_status = HTTP_INTERNAL_SERVER_ERROR;
         goto cleanup;
     }
@@ -1451,6 +1453,7 @@ static void *create_proxy_dir_config(apr_pool_t *p, char *dummy)
     new->error_override = 0;
     new->error_override_set = 0;
     new->add_forwarded_headers = 1;
+    new->add_forwarded_headers_set = 0;
 
     return (void *) new;
 }
@@ -1482,7 +1485,12 @@ static void *merge_proxy_dir_config(apr_pool_t *p, void *basev, void *addv)
     new->error_override_set = add->error_override_set || base->error_override_set;
     new->alias = (add->alias_set == 0) ? base->alias : add->alias;
     new->alias_set = add->alias_set || base->alias_set;
-    new->add_forwarded_headers = add->add_forwarded_headers;
+    new->add_forwarded_headers =
+        (add->add_forwarded_headers_set == 0) ? base->add_forwarded_headers
+        : add->add_forwarded_headers;
+    new->add_forwarded_headers_set = add->add_forwarded_headers_set
+        || base->add_forwarded_headers_set;
+    
     return new;
 }
 
@@ -1970,6 +1978,7 @@ static const char *
 {
    proxy_dir_conf *conf = dconf;
    conf->add_forwarded_headers = flag;
+   conf->add_forwarded_headers_set = 1;
    return NULL;
 }
 static const char *
@@ -2677,7 +2686,7 @@ static int proxy_status_hook(request_rec *r, int flags)
                 ap_rvputs(r, ap_proxy_parse_wstatus(r->pool, *worker), NULL);
                 ap_rvputs(r, "</td><td>", (*worker)->s->route, NULL);
                 ap_rvputs(r, "</td><td>", (*worker)->s->redirect, NULL);
-                ap_rprintf(r, "</td><td>%d</td>", (*worker)->s->lbfactor);
+                ap_rprintf(r, "</td><td>%.2f</td>", (float)((*worker)->s->lbfactor)/100.0);
                 ap_rprintf(r, "<td>%d</td>", (*worker)->s->lbset);
                 ap_rprintf(r, "<td>%" APR_SIZE_T_FMT "</td><td>",
                            (*worker)->s->elected);
diff --git a/modules/proxy/mod_proxy.h b/modules/proxy/mod_proxy.h
index 8a0ad10..4f31bed 100644
--- a/modules/proxy/mod_proxy.h
+++ b/modules/proxy/mod_proxy.h
@@ -235,6 +235,7 @@ typedef struct {
     unsigned int error_override_set:1;
     unsigned int alias_set:1;
     unsigned int add_forwarded_headers:1;
+    unsigned int add_forwarded_headers_set:1;
 
     /** Named back references */
     apr_array_header_t *refs;
diff --git a/modules/proxy/mod_proxy_balancer.c b/modules/proxy/mod_proxy_balancer.c
index ec9f103..9c58590 100644
--- a/modules/proxy/mod_proxy_balancer.c
+++ b/modules/proxy/mod_proxy_balancer.c
@@ -22,6 +22,7 @@
 #include "apr_version.h"
 #include "ap_hooks.h"
 #include "apr_date.h"
+#include "mod_watchdog.h"
 
 static const char *balancer_mutex_type = "proxy-balancer-shm";
 ap_slotmem_provider_t *storage = NULL;
@@ -699,10 +700,10 @@ static void recalc_factors(proxy_balancer *balancer)
     /* Recalculate lbfactors */
     workers = (proxy_worker **)balancer->workers->elts;
     /* Special case if there is only one worker its
-     * load factor will always be 1
+     * load factor will always be 100
      */
     if (balancer->workers->nelts == 1) {
-        (*workers)->s->lbstatus = (*workers)->s->lbfactor = 1;
+        (*workers)->s->lbstatus = (*workers)->s->lbfactor = 100;
         return;
     }
     for (i = 0; i < balancer->workers->nelts; i++) {
@@ -1092,8 +1093,10 @@ static int balancer_handler(request_rec *r)
         ap_log_rerror(APLOG_MARK, APLOG_DEBUG, 0, r, APLOGNO(01192) "settings worker params");
 
         if ((val = apr_table_get(params, "w_lf"))) {
-            int ival = atoi(val);
-            if (ival >= 1 && ival <= 100) {
+            int ival;
+            double fval = atof(val);
+            ival = fval * 100.0;
+            if (ival >= 100 && ival <= 10000) {
                 wsel->s->lbfactor = ival;
                 if (bsel)
                     recalc_factors(bsel);
@@ -1140,9 +1143,11 @@ static int balancer_handler(request_rec *r)
              }
         }
         if ((val = apr_table_get(params, "w_hi"))) {
-            int ival = atoi(val);
-            if (ival >= HCHECK_WATHCHDOG_INTERVAL) {
-                wsel->s->interval = apr_time_from_sec(ival);
+            apr_interval_time_t hci;
+            if (ap_timeout_parameter_parse(val, &hci, "ms") == APR_SUCCESS) {
+                if (hci >= AP_WD_TM_SLICE) {
+                    wsel->s->interval = hci;
+                }
              }
         }
         if ((val = apr_table_get(params, "w_hp"))) {
@@ -1359,8 +1364,8 @@ static int balancer_handler(request_rec *r)
                           "</httpd:scheme>\n", NULL);
                 ap_rvputs(r, "          <httpd:hostname>", worker->s->hostname,
                           "</httpd:hostname>\n", NULL);
-                ap_rprintf(r, "          <httpd:loadfactor>%d</httpd:loadfactor>\n",
-                          worker->s->lbfactor);
+                ap_rprintf(r, "          <httpd:loadfactor>%.2f</httpd:loadfactor>\n",
+                          (float)(worker->s->lbfactor)/100.0);
                 ap_rprintf(r,
                            "          <httpd:port>%d</httpd:port>\n",
                            worker->s->port);
@@ -1413,8 +1418,8 @@ static int balancer_handler(request_rec *r)
                            "          <httpd:lbstatus>%d</httpd:lbstatus>\n",
                            worker->s->lbstatus);
                 ap_rprintf(r,
-                           "          <httpd:loadfactor>%d</httpd:loadfactor>\n",
-                           worker->s->lbfactor);
+                           "          <httpd:loadfactor>%.2f</httpd:loadfactor>\n",
+                           (float)(worker->s->lbfactor)/100.0);
                 ap_rprintf(r,
                            "          <httpd:transferred>%" APR_OFF_T_FMT "</httpd:transferred>\n",
                            worker->s->transferred);
@@ -1600,7 +1605,7 @@ static int balancer_handler(request_rec *r)
                           NULL);
                 ap_rvputs(r, "</td><td>",
                           ap_escape_html(r->pool, worker->s->redirect), NULL);
-                ap_rprintf(r, "</td><td>%d</td>", worker->s->lbfactor);
+                ap_rprintf(r, "</td><td>%.2f</td>", (float)(worker->s->lbfactor)/100.0);
                 ap_rprintf(r, "<td>%d</td><td>", worker->s->lbset);
                 ap_rvputs(r, ap_proxy_parse_wstatus(r->pool, worker), NULL);
                 ap_rputs("</td>", r);
@@ -1612,7 +1617,7 @@ static int balancer_handler(request_rec *r)
                 ap_rputs(apr_strfsize(worker->s->read, fbuf), r);
                 if (set_worker_hc_param_f) {
                     ap_rprintf(r, "</td><td>%s</td>", ap_proxy_show_hcmethod(worker->s->method));
-                    ap_rprintf(r, "<td>%d</td>", (int)apr_time_sec(worker->s->interval));
+                    ap_rprintf(r, "<td>%" APR_TIME_T_FMT "ms</td>", apr_time_as_msec(worker->s->interval));
                     ap_rprintf(r, "<td>%d (%d)</td>", worker->s->passes,worker->s->pcount);
                     ap_rprintf(r, "<td>%d (%d)</td>", worker->s->fails, worker->s->fcount);
                     ap_rprintf(r, "<td>%s</td>", worker->s->hcuri);
@@ -1635,7 +1640,7 @@ static int balancer_handler(request_rec *r)
             ap_rputs("<form method='POST' enctype='application/x-www-form-urlencoded' action='", r);
             ap_rvputs(r, ap_escape_uri(r->pool, action), "'>\n", NULL);
             ap_rputs("<table><tr><td>Load factor:</td><td><input name='w_lf' id='w_lf' type=text ", r);
-            ap_rprintf(r, "value='%d'></td></tr>\n", wsel->s->lbfactor);
+            ap_rprintf(r, "value='%.2f'></td></tr>\n", (float)(wsel->s->lbfactor)/100.0);
             ap_rputs("<tr><td>LB Set:</td><td><input name='w_ls' id='w_ls' type=text ", r);
             ap_rprintf(r, "value='%d'></td></tr>\n", wsel->s->lbset);
             ap_rputs("<tr><td>Route:</td><td><input name='w_wr' id='w_wr' type=text ", r);
@@ -1681,8 +1686,8 @@ static int balancer_handler(request_rec *r)
                 ap_rputs("<tr><td>Expr</td><td><select name='w_he'>\n", r);
                 hc_select_exprs_f(r, wsel->s->hcexpr);
                 ap_rputs("</select>\n</td></tr>\n", r);
-                ap_rprintf(r, "<tr><td>Interval (secs)</td><td><input name='w_hi' id='w_hi' type='text'"
-                           "value='%d'></td></tr>\n", (int)apr_time_sec(wsel->s->interval));
+                ap_rprintf(r, "<tr><td>Interval (ms)</td><td><input name='w_hi' id='w_hi' type='text'"
+                           "value='%" APR_TIME_T_FMT "'></td></tr>\n", apr_time_as_msec(wsel->s->interval));
                 ap_rprintf(r, "<tr><td>Passes trigger</td><td><input name='w_hp' id='w_hp' type='text'"
                            "value='%d'></td></tr>\n", wsel->s->passes);
                 ap_rprintf(r, "<tr><td>Fails trigger)</td><td><input name='w_hf' id='w_hf' type='text'"
diff --git a/modules/proxy/mod_proxy_hcheck.c b/modules/proxy/mod_proxy_hcheck.c
index a458a38..1b2833b 100644
--- a/modules/proxy/mod_proxy_hcheck.c
+++ b/modules/proxy/mod_proxy_hcheck.c
@@ -28,7 +28,9 @@ module AP_MODULE_DECLARE_DATA proxy_hcheck_module;
 
 /* Why? So we can easily set/clear HC_USE_THREADS during dev testing */
 #if APR_HAS_THREADS
+#ifndef HC_USE_THREADS
 #define HC_USE_THREADS 1
+#endif
 #else
 #define HC_USE_THREADS 0
 typedef void apr_thread_pool_t;
@@ -113,7 +115,7 @@ static const char *set_worker_hc_param(apr_pool_t *p,
         hc_template_t *template;
         template = (hc_template_t *)ctx->templates->elts;
         for (ival = 0; ival < ctx->templates->nelts; ival++, template++) {
-            if (!strcasecmp(template->name, val)) {
+            if (!ap_cstr_casecmp(template->name, val)) {
                 if (worker) {
                     worker->s->method = template->method;
                     worker->s->interval = template->interval;
@@ -137,7 +139,7 @@ static const char *set_worker_hc_param(apr_pool_t *p,
     else if (!strcasecmp(key, "hcmethod")) {
         proxy_hcmethods_t *method = proxy_hcmethods;
         for (; method->name; method++) {
-            if (!strcasecmp(val, method->name)) {
+            if (!ap_cstr_casecmp(val, method->name)) {
                 if (!method->implemented) {
                     return apr_psprintf(p, "Health check method %s not (yet) implemented",
                                         val);
@@ -153,14 +155,18 @@ static const char *set_worker_hc_param(apr_pool_t *p,
         return "Unknown method";
     }
     else if (!strcasecmp(key, "hcinterval")) {
-        ival = atoi(val);
-        if (ival < HCHECK_WATHCHDOG_INTERVAL)
-            return apr_psprintf(p, "Interval must be a positive value greater than %d seconds",
-                                HCHECK_WATHCHDOG_INTERVAL);
+        apr_interval_time_t hci;
+        apr_status_t rv;
+        rv = ap_timeout_parameter_parse(val, &hci, "s");
+        if (rv != APR_SUCCESS)
+            return "Unparse-able hcinterval setting";
+        if (hci < AP_WD_TM_SLICE)
+            return apr_psprintf(p, "Interval must be a positive value greater than %"
+                                APR_TIME_T_FMT "ms", apr_time_as_msec(AP_WD_TM_SLICE));
         if (worker) {
-            worker->s->interval = apr_time_from_sec(ival);
+            worker->s->interval = hci;
         } else {
-            temp->interval = apr_time_from_sec(ival);
+            temp->interval = hci;
         }
     }
     else if (!strcasecmp(key, "hcpasses")) {
@@ -555,10 +561,10 @@ static apr_status_t backend_cleanup(const char *proxy_function, proxy_conn_rec *
         backend->close = 1;
         ap_proxy_release_connection(proxy_function, backend, s);
         ap_log_error(APLOG_MARK, APLOG_DEBUG, 0, s, APLOGNO(03251)
-                     "Health check %s Status (%d) for %s.",
-                     ap_proxy_show_hcmethod(backend->worker->s->method),
-                     status,
-                     backend->worker->s->name);
+                         "Health check %s Status (%d) for %s.",
+                         ap_proxy_show_hcmethod(backend->worker->s->method),
+                         status,
+                         backend->worker->s->name);
     }
     if (status != OK) {
         return APR_EGENERAL;
@@ -1020,7 +1026,7 @@ static int hc_post_config(apr_pool_t *p, apr_pool_t *plog,
             continue;
         }
         rv = hc_watchdog_register_callback(watchdog,
-                apr_time_from_sec(HCHECK_WATHCHDOG_INTERVAL),
+                AP_WD_TM_SLICE,
                 ctx,
                 hc_watchdog_callback);
         if (rv) {
@@ -1137,7 +1143,7 @@ static const char *hc_expr_var_fn(ap_expr_eval_ctx_t *ctx, const void *data)
 {
     char *var = (char *)data;
 
-    if (var && *var && ctx->r && strcasecmp(var, "BODY") == 0) {
+    if (var && *var && ctx->r && ap_cstr_casecmp(var, "BODY") == 0) {
         return hc_get_body(ctx->r);
     }
     return NULL;
@@ -1148,7 +1154,7 @@ static const char *hc_expr_func_fn(ap_expr_eval_ctx_t *ctx, const void *data,
 {
     char *var = (char *)arg;
 
-    if (var && *var && ctx->r && strcasecmp(var, "BODY") == 0) {
+    if (var && *var && ctx->r && ap_cstr_casecmp(var, "BODY") == 0) {
         return hc_get_body(ctx->r);
     }
     return NULL;
diff --git a/modules/proxy/mod_proxy_wstunnel.c b/modules/proxy/mod_proxy_wstunnel.c
index 0130699..c9949e2 100644
--- a/modules/proxy/mod_proxy_wstunnel.c
+++ b/modules/proxy/mod_proxy_wstunnel.c
@@ -131,6 +131,10 @@ static int proxy_wstunnel_request(apr_pool_t *p, request_rec *r,
 
     if (ap_cstr_casecmp(upgrade_method, "NONE") == 0) {
         buf = apr_pstrdup(p, "Upgrade: WebSocket" CRLF "Connection: Upgrade" CRLF CRLF);
+    } else if (ap_cstr_casecmp(upgrade_method, "ANY") == 0) {
+        const char *upgrade;
+        upgrade = apr_table_get(r->headers_in, "Upgrade");
+        buf = apr_pstrcat(p, "Upgrade: ", upgrade, CRLF "Connection: Upgrade" CRLF CRLF, NULL);
     } else {
         buf = apr_pstrcat(p, "Upgrade: ", upgrade_method, CRLF "Connection: Upgrade" CRLF CRLF, NULL);
     }
@@ -204,7 +208,7 @@ static int proxy_wstunnel_request(apr_pool_t *p, request_rec *r,
                                                                   c,
                                                                   header_brigade,
                                                                   bb, "sock",
-                                                                  NULL,
+                                                                  &replied,
                                                                   AP_IOBUFSIZE,
                                                                   0)
                                                                  != APR_SUCCESS;
@@ -230,7 +234,7 @@ static int proxy_wstunnel_request(apr_pool_t *p, request_rec *r,
                                                                   backconn, bb,
                                                                   header_brigade,
                                                                   "client",
-                                                                  &replied,
+                                                                  NULL,
                                                                   AP_IOBUFSIZE,
                                                                   0)
                                                                  != APR_SUCCESS;
@@ -302,7 +306,8 @@ static int proxy_wstunnel_handler(request_rec *r, proxy_worker *worker,
     if (ap_cstr_casecmp(upgrade_method, "NONE") != 0) {
         const char *upgrade;
         upgrade = apr_table_get(r->headers_in, "Upgrade");
-        if (!upgrade || ap_cstr_casecmp(upgrade, upgrade_method) != 0) {
+        if (!upgrade || (ap_cstr_casecmp(upgrade, upgrade_method) != 0 &&
+            ap_cstr_casecmp(upgrade_method, "ANY") !=0)) {
             ap_log_rerror(APLOG_MARK, APLOG_DEBUG, 0, r, APLOGNO(02900)
                           "declining URL %s  (not %s, Upgrade: header is %s)", 
                           url, upgrade_method, upgrade ? upgrade : "missing");
diff --git a/modules/proxy/proxy_util.c b/modules/proxy/proxy_util.c
index 663c3af..b61d56f 100644
--- a/modules/proxy/proxy_util.c
+++ b/modules/proxy/proxy_util.c
@@ -1699,7 +1699,7 @@ PROXY_DECLARE(char *) ap_proxy_define_worker(apr_pool_t *p,
     wshared->flush_packets = flush_off;
     wshared->flush_wait = PROXY_FLUSH_WAIT;
     wshared->is_address_reusable = 1;
-    wshared->lbfactor = 1;
+    wshared->lbfactor = 100;
     wshared->passes = 1;
     wshared->fails = 1;
     wshared->interval = apr_time_from_sec(HCHECK_WATHCHDOG_DEFAULT_INTERVAL);
diff --git a/modules/ssl/mod_ssl.c b/modules/ssl/mod_ssl.c
index 131ec7e..a23f2f5 100644
--- a/modules/ssl/mod_ssl.c
+++ b/modules/ssl/mod_ssl.c
@@ -338,11 +338,13 @@ static apr_status_t ssl_cleanup_pre_config(void *data)
     ENGINE_cleanup();
 #endif
 #if OPENSSL_VERSION_NUMBER >= 0x1000200fL
+#ifndef OPENSSL_NO_COMP
     SSL_COMP_free_compression_methods();
 #endif
+#endif
 
     /* Usually needed per thread, but this parent process is single-threaded */
-#if OPENSSL_VERSION_NUMBER < 0x10100000L
+#if MODSSL_USE_OPENSSL_PRE_1_1_API
 #if OPENSSL_VERSION_NUMBER >= 0x1000000fL
     ERR_remove_thread_state(NULL);
 #else
@@ -383,15 +385,15 @@ static int ssl_hook_pre_config(apr_pool_t *pconf,
     /* Some OpenSSL internals are allocated per-thread, make sure they
      * are associated to the/our same thread-id until cleaned up.
      */
-#if APR_HAS_THREADS && OPENSSL_VERSION_NUMBER < 0x10100000L
+#if APR_HAS_THREADS && MODSSL_USE_OPENSSL_PRE_1_1_API
     ssl_util_thread_id_setup(pconf);
 #endif
 
     /* We must register the library in full, to ensure our configuration
      * code can successfully test the SSL environment.
      */
-#if OPENSSL_VERSION_NUMBER < 0x10100000L
-    CRYPTO_malloc_init();
+#if MODSSL_USE_OPENSSL_PRE_1_1_API
+    (void)CRYPTO_malloc_init();
 #else
     OPENSSL_malloc_init();
 #endif
diff --git a/modules/ssl/ssl_engine_init.c b/modules/ssl/ssl_engine_init.c
index 3e11d56..e5dee0f 100644
--- a/modules/ssl/ssl_engine_init.c
+++ b/modules/ssl/ssl_engine_init.c
@@ -47,7 +47,7 @@ APR_IMPLEMENT_OPTIONAL_HOOK_RUN_ALL(ssl, SSL, int, init_server,
 #define KEYTYPES "RSA or DSA"
 #endif
 
-#if OPENSSL_VERSION_NUMBER < 0x10100000L
+#if MODSSL_USE_OPENSSL_PRE_1_1_API
 /* OpenSSL Pre-1.1.0 compatibility */
 /* Taken from OpenSSL 1.1.0 snapshot 20160410 */
 static int DH_set0_pqg(DH *dh, BIGNUM *p, BIGNUM *q, BIGNUM *g)
@@ -257,7 +257,7 @@ apr_status_t ssl_init_Module(apr_pool_t *p, apr_pool_t *plog,
 #endif
     }
 
-#if APR_HAS_THREADS && OPENSSL_VERSION_NUMBER < 0x10100000L
+#if APR_HAS_THREADS && MODSSL_USE_OPENSSL_PRE_1_1_API
     ssl_util_thread_setup(p);
 #endif
 
@@ -380,7 +380,7 @@ apr_status_t ssl_init_Module(apr_pool_t *p, apr_pool_t *plog,
     modssl_init_app_data2_idx(); /* for modssl_get_app_data2() at request time */
 
     init_dh_params();
-#if OPENSSL_VERSION_NUMBER >= 0x10100000L
+#if !MODSSL_USE_OPENSSL_PRE_1_1_API
     init_bio_methods();
 #endif
 
@@ -1301,7 +1301,7 @@ static apr_status_t ssl_init_server_certs(server_rec *s,
      * or configure NIST P-256 (required to enable ECDHE for earlier versions)
      * ECDH is always enabled in 1.1.0 unless excluded from SSLCipherList
      */
-#if (OPENSSL_VERSION_NUMBER < 0x10100000L)
+#if MODSSL_USE_OPENSSL_PRE_1_1_API
     else {
 #if defined(SSL_CTX_set_ecdh_auto)
         SSL_CTX_set_ecdh_auto(mctx->ssl_ctx, 1);
@@ -2011,7 +2011,7 @@ apr_status_t ssl_init_ModuleKill(void *data)
 
     }
 
-#if OPENSSL_VERSION_NUMBER >= 0x10100000L
+#if !MODSSL_USE_OPENSSL_PRE_1_1_API
     free_bio_methods();
 #endif
     free_dh_params();
diff --git a/modules/ssl/ssl_engine_io.c b/modules/ssl/ssl_engine_io.c
index d1f44e9..d5ebac9 100644
--- a/modules/ssl/ssl_engine_io.c
+++ b/modules/ssl/ssl_engine_io.c
@@ -164,7 +164,7 @@ static int bio_filter_create(BIO *bio)
 {
     BIO_set_shutdown(bio, 1);
     BIO_set_init(bio, 1);
-#if OPENSSL_VERSION_NUMBER < 0x10100000L
+#if MODSSL_USE_OPENSSL_PRE_1_1_API
     /* No setter method for OpenSSL 1.1.0 available,
      * but I can't find any functional use of the
      * "num" field there either.
@@ -549,7 +549,7 @@ static long bio_filter_in_ctrl(BIO *bio, int cmd, long num, void *ptr)
     return -1;
 }
 
-#if OPENSSL_VERSION_NUMBER < 0x10100000L
+#if MODSSL_USE_OPENSSL_PRE_1_1_API
         
 static BIO_METHOD bio_filter_out_method = {
     BIO_TYPE_MEM,
@@ -2024,7 +2024,7 @@ static void ssl_io_input_add_filter(ssl_filter_ctx_t *filter_ctx, conn_rec *c,
 
     filter_ctx->pInputFilter = ap_add_input_filter(ssl_io_filter, inctx, r, c);
 
-#if OPENSSL_VERSION_NUMBER < 0x10100000L
+#if MODSSL_USE_OPENSSL_PRE_1_1_API
     filter_ctx->pbioRead = BIO_new(&bio_filter_in_method);
 #else
     filter_ctx->pbioRead = BIO_new(bio_filter_in_method);
@@ -2059,7 +2059,7 @@ void ssl_io_filter_init(conn_rec *c, request_rec *r, SSL *ssl)
     filter_ctx->pOutputFilter   = ap_add_output_filter(ssl_io_filter,
                                                        filter_ctx, r, c);
 
-#if OPENSSL_VERSION_NUMBER < 0x10100000L
+#if MODSSL_USE_OPENSSL_PRE_1_1_API
     filter_ctx->pbioWrite       = BIO_new(&bio_filter_out_method);
 #else
     filter_ctx->pbioWrite       = BIO_new(bio_filter_out_method);
diff --git a/modules/ssl/ssl_engine_kernel.c b/modules/ssl/ssl_engine_kernel.c
index e8484ed..7c00123 100644
--- a/modules/ssl/ssl_engine_kernel.c
+++ b/modules/ssl/ssl_engine_kernel.c
@@ -1733,7 +1733,7 @@ static void modssl_proxy_info_log(conn_rec *c,
  * so we need to increment here to prevent them from
  * being freed.
  */
-#if OPENSSL_VERSION_NUMBER < 0x10100000L
+#if MODSSL_USE_OPENSSL_PRE_1_1_API
 #define modssl_set_cert_info(info, cert, pkey) \
     *cert = info->x509; \
     CRYPTO_add(&(*cert)->references, +1, CRYPTO_LOCK_X509); \
@@ -2301,7 +2301,7 @@ int ssl_callback_SessionTicket(SSL *ssl,
                       "TLS session ticket key for %s successfully set, "
                       "creating new session ticket", sc->vhost_id);
 
-        return 0;
+        return 1;
     }
     else if (mode == 0) {
         /* 
diff --git a/modules/ssl/ssl_engine_vars.c b/modules/ssl/ssl_engine_vars.c
index 04b0879..8ce40ef 100644
--- a/modules/ssl/ssl_engine_vars.c
+++ b/modules/ssl/ssl_engine_vars.c
@@ -529,7 +529,7 @@ static char *ssl_var_lookup_ssl_cert(apr_pool_t *p, request_rec *r, X509 *xs,
         resdup = FALSE;
     }
     else if (strcEQ(var, "A_SIG")) {
-#if OPENSSL_VERSION_NUMBER < 0x10100000L
+#if MODSSL_USE_OPENSSL_PRE_1_1_API
         nid = OBJ_obj2nid((ASN1_OBJECT *)(xs->cert_info->signature->algorithm));
 #else
         const ASN1_OBJECT *paobj;
diff --git a/modules/ssl/ssl_private.h b/modules/ssl/ssl_private.h
index 3e9602c..0ab60a0 100644
--- a/modules/ssl/ssl_private.h
+++ b/modules/ssl/ssl_private.h
@@ -123,6 +123,25 @@
 #define MODSSL_SSL_METHOD_CONST
 #endif
 
+#if defined(LIBRESSL_VERSION_NUMBER)
+/* Missing from LibreSSL */
+#if LIBRESSL_VERSION_NUMBER < 0x2060000f
+#define SSL_CTRL_SET_MIN_PROTO_VERSION          123
+#define SSL_CTRL_SET_MAX_PROTO_VERSION          124
+#define SSL_CTX_set_min_proto_version(ctx, version) \
+        SSL_CTX_ctrl(ctx, SSL_CTRL_SET_MIN_PROTO_VERSION, version, NULL)
+#define SSL_CTX_set_max_proto_version(ctx, version) \
+        SSL_CTX_ctrl(ctx, SSL_CTRL_SET_MAX_PROTO_VERSION, version, NULL)
+#endif
+/* LibreSSL declares OPENSSL_VERSION_NUMBER == 2.0 but does not include most
+ * changes from OpenSSL >= 1.1 (new functions, macros, deprecations, ...), so
+ * we have to work around this...
+ */
+#define MODSSL_USE_OPENSSL_PRE_1_1_API (1)
+#else
+#define MODSSL_USE_OPENSSL_PRE_1_1_API (OPENSSL_VERSION_NUMBER < 0x10100000L)
+#endif
+
 #if defined(OPENSSL_FIPS)
 #define HAVE_FIPS
 #endif
@@ -136,7 +155,7 @@
 #endif
 
 /* session id constness */
-#if OPENSSL_VERSION_NUMBER < 0x10100000L
+#if MODSSL_USE_OPENSSL_PRE_1_1_API
 #define IDCONST
 #else
 #define IDCONST const
@@ -199,7 +218,7 @@
 
 #endif /* !defined(OPENSSL_NO_TLSEXT) && defined(SSL_set_tlsext_host_name) */
 
-#if OPENSSL_VERSION_NUMBER < 0x10100000L
+#if MODSSL_USE_OPENSSL_PRE_1_1_API
 #define BN_get_rfc2409_prime_768   get_rfc2409_prime_768
 #define BN_get_rfc2409_prime_1024  get_rfc2409_prime_1024
 #define BN_get_rfc3526_prime_1536  get_rfc3526_prime_1536
@@ -219,7 +238,7 @@ void init_bio_methods(void);
 void free_bio_methods(void);
 #endif
 
-#if OPENSSL_VERSION_NUMBER < 0x10002000L
+#if OPENSSL_VERSION_NUMBER < 0x10002000L || defined(LIBRESSL_VERSION_NUMBER)
 #define X509_STORE_CTX_get0_store(x) (x->ctx)
 #endif
 
@@ -933,10 +952,8 @@ void         ssl_util_ppclose(server_rec *, apr_pool_t *, apr_file_t *);
 char        *ssl_util_readfilter(server_rec *, apr_pool_t *, const char *,
                                  const char * const *);
 BOOL         ssl_util_path_check(ssl_pathcheck_t, const char *, apr_pool_t *);
-#if APR_HAS_THREADS
-#if OPENSSL_VERSION_NUMBER < 0x10100000L
+#if APR_HAS_THREADS && MODSSL_USE_OPENSSL_PRE_1_1_API
 void         ssl_util_thread_setup(apr_pool_t *);
-#endif
 void         ssl_util_thread_id_setup(apr_pool_t *);
 #endif
 int          ssl_init_ssl_connection(conn_rec *c, request_rec *r);
diff --git a/modules/ssl/ssl_util.c b/modules/ssl/ssl_util.c
index 9e4e719..afc64a3 100644
--- a/modules/ssl/ssl_util.c
+++ b/modules/ssl/ssl_util.c
@@ -246,8 +246,8 @@ void ssl_asn1_table_unset(apr_hash_t *table,
     apr_hash_set(table, key, klen, NULL);
 }
 
-#if APR_HAS_THREADS
-#if OPENSSL_VERSION_NUMBER < 0x10100000L
+#if APR_HAS_THREADS && MODSSL_USE_OPENSSL_PRE_1_1_API
+
 /*
  * To ensure thread-safetyness in OpenSSL - work in progress
  */
@@ -467,5 +467,5 @@ void ssl_util_thread_id_setup(apr_pool_t *p)
     apr_pool_cleanup_register(p, NULL, ssl_util_thr_id_cleanup,
                                        apr_pool_cleanup_null);
 }
-#endif /* #if OPENSSL_VERSION_NUMBER < 0x10100000L */
-#endif /* #if APR_HAS_THREADS */
+
+#endif /* #if APR_HAS_THREADS && MODSSL_USE_OPENSSL_PRE_1_1_API */
diff --git a/modules/ssl/ssl_util_ssl.h b/modules/ssl/ssl_util_ssl.h
index 4f18f91..04b138d 100644
--- a/modules/ssl/ssl_util_ssl.h
+++ b/modules/ssl/ssl_util_ssl.h
@@ -41,7 +41,7 @@
 #define MODSSL_LIBRARY_VERSION OPENSSL_VERSION_NUMBER
 #define MODSSL_LIBRARY_NAME    "OpenSSL"
 #define MODSSL_LIBRARY_TEXT    OPENSSL_VERSION_TEXT
-#if OPENSSL_VERSION_NUMBER < 0x10100000L
+#if MODSSL_USE_OPENSSL_PRE_1_1_API
 #define MODSSL_LIBRARY_DYNTEXT SSLeay_version(SSLEAY_VERSION)
 #else
 #define MODSSL_LIBRARY_DYNTEXT OpenSSL_version(OPENSSL_VERSION)
diff --git a/server/config.c b/server/config.c
index 61daeaf..983c7df 100644
--- a/server/config.c
+++ b/server/config.c
@@ -1715,14 +1715,14 @@ typedef struct {
 static apr_status_t arr_elts_getstr(void *buf, apr_size_t bufsiz, void *param)
 {
     arr_elts_param_t *arr_param = (arr_elts_param_t *)param;
-    char *elt;
+    const char *elt;
 
     /* End of array reached? */
     if (++arr_param->curr_idx > arr_param->array->nelts)
         return APR_EOF;
 
     /* return the line */
-    elt = ((char **)arr_param->array->elts)[arr_param->curr_idx - 1];
+    elt = ((const char **)arr_param->array->elts)[arr_param->curr_idx - 1];
     if (apr_cpystrn(buf, elt, bufsiz) - (char *)buf >= bufsiz - 1)
         return APR_ENOSPC;
     return APR_SUCCESS;
diff --git a/server/core.c b/server/core.c
index 20fa583..6516b09 100644
--- a/server/core.c
+++ b/server/core.c
@@ -1435,18 +1435,20 @@ static const char *set_define(cmd_parms *cmd, void *dummy,
     const char *err = ap_check_cmd_context(cmd, NOT_IN_HTACCESS);
     if (err)
         return err;
-    if (ap_strchr_c(name, ':') != NULL)
+    if (ap_strchr_c(name, ':') != NULL) {
         return "Variable name must not contain ':'";
+    }
 
-    if (!saved_server_config_defines)
+    if (!saved_server_config_defines) {
         init_config_defines(cmd->pool);
+    }
     if (!ap_exists_config_define(name)) {
-        char **newv = (char **)apr_array_push(ap_server_config_defines);
-        *newv = apr_pstrdup(cmd->pool, name);
+        *(const char **)apr_array_push(ap_server_config_defines) = name;
     }
     if (value) {
-        if (!server_config_defined_vars)
+        if (!server_config_defined_vars) {
             server_config_defined_vars = apr_table_make(cmd->pool, 5);
+        }
         apr_table_setn(server_config_defined_vars, name, value);
     }
 
@@ -1457,20 +1459,22 @@ static const char *unset_define(cmd_parms *cmd, void *dummy,
                                 const char *name)
 {
     int i;
-    char **defines;
+    const char **defines;
     const char *err = ap_check_cmd_context(cmd, NOT_IN_HTACCESS);
     if (err)
         return err;
-    if (ap_strchr_c(name, ':') != NULL)
+    if (ap_strchr_c(name, ':') != NULL) {
         return "Variable name must not contain ':'";
+    }
 
-    if (!saved_server_config_defines)
+    if (!saved_server_config_defines) {
         init_config_defines(cmd->pool);
+    }
 
-    defines = (char **)ap_server_config_defines->elts;
+    defines = (const char **)ap_server_config_defines->elts;
     for (i = 0; i < ap_server_config_defines->nelts; i++) {
         if (strcmp(defines[i], name) == 0) {
-            defines[i] = *(char **)apr_array_pop(ap_server_config_defines);
+            defines[i] = *(const char **)apr_array_pop(ap_server_config_defines);
             break;
         }
     }
@@ -2262,6 +2266,12 @@ AP_CORE_DECLARE_NONSTD(const char *) ap_limit_section(cmd_parms *cmd,
             /* method has not been registered yet, but resource restriction
              * is always checked before method handling, so register it.
              */
+            if (cmd->pool == cmd->temp_pool) {
+                /* In .htaccess, we can't globally register new methods. */
+                return apr_psprintf(cmd->pool, "Could not register method '%s' "
+                                   "for %s from .htaccess configuration",
+                                    method, cmd->cmd->name);
+            }
             methnum = ap_method_register(cmd->pool,
                                          apr_pstrdup(cmd->pool, method));
         }
diff --git a/server/listen.c b/server/listen.c
index d44c7c9..a8e9e6f 100644
--- a/server/listen.c
+++ b/server/listen.c
@@ -277,18 +277,14 @@ static apr_status_t close_listeners_on_exec(void *v)
     return APR_SUCCESS;
 }
 
-static const char *alloc_listener(process_rec *process, char *addr,
-                                  apr_port_t port, const char* proto,
-                                  void *slave)
+static int find_listeners(ap_listen_rec **from, ap_listen_rec **to,
+                          const char *addr, apr_port_t port)
 {
-    ap_listen_rec **walk, *last;
-    apr_status_t status;
-    apr_sockaddr_t *sa;
-    int found_listener = 0;
+    int found = 0;
+
+    while (*from) {
+        apr_sockaddr_t *sa = (*from)->bind_addr;
 
-    /* see if we've got an old listener for this address:port */
-    for (walk = &old_listeners; *walk;) {
-        sa = (*walk)->bind_addr;
         /* Some listeners are not real so they will not have a bind_addr. */
         if (sa) {
             ap_listen_rec *new;
@@ -301,19 +297,39 @@ static const char *alloc_listener(process_rec *process, char *addr,
             if (port == oldport &&
                 ((!addr && !sa->hostname) ||
                  ((addr && sa->hostname) && !strcmp(sa->hostname, addr)))) {
-                new = *walk;
-                *walk = new->next;
-                new->next = ap_listeners;
-                ap_listeners = new;
-                found_listener = 1;
+                found = 1;
+                if (!to) {
+                    break;
+                }
+                new = *from;
+                *from = new->next;
+                new->next = *to;
+                *to = new;
                 continue;
             }
         }
 
-        walk = &(*walk)->next;
+        from = &(*from)->next;
+    }
+
+    return found;
+}
+
+static const char *alloc_listener(process_rec *process, const char *addr,
+                                  apr_port_t port, const char* proto,
+                                  void *slave)
+{
+    ap_listen_rec *last;
+    apr_status_t status;
+    apr_sockaddr_t *sa;
+
+    /* see if we've got a listener for this address:port, which is an error */
+    if (find_listeners(&ap_listeners, NULL, addr, port)) {
+        return "Cannot define multiple Listeners on the same IP:port";
     }
 
-    if (found_listener) {
+    /* see if we've got an old listener for this address:port */
+    if (find_listeners(&old_listeners, &ap_listeners, addr, port)) {
         if (ap_listeners->slave != slave) {
             return "Cannot define a slave on the same IP:port as a Listener";
         }
diff --git a/server/log.c b/server/log.c
index bfec379..22567a4 100644
--- a/server/log.c
+++ b/server/log.c
@@ -398,16 +398,40 @@ static int open_error_log(server_rec *s, int is_main, apr_pool_t *p)
 #ifdef HAVE_SYSLOG
     else if (!strncasecmp(s->error_fname, "syslog", 6)) {
         if ((fname = strchr(s->error_fname, ':'))) {
+            /* s->error_fname could be [level]:[tag] (see #60525) */
+            const char *tag;
+            apr_size_t flen;
             const TRANS *fac;
 
             fname++;
-            for (fac = facilities; fac->t_name; fac++) {
-                if (!strcasecmp(fname, fac->t_name)) {
-                    openlog(ap_server_argv0, LOG_NDELAY|LOG_CONS|LOG_PID,
-                            fac->t_val);
-                    s->error_log = NULL;
-                    return OK;
+            tag = ap_strchr_c(fname, ':');
+            if (tag) {
+                flen = tag - fname;
+                tag++;
+                if (*tag == '\0') {
+                    tag = ap_server_argv0;
                 }
+            } else {
+                flen = strlen(fname);
+                tag = ap_server_argv0;
+            }
+            if (flen == 0) {
+                /* Was something like syslog::foobar */
+                openlog(tag, LOG_NDELAY|LOG_CONS|LOG_PID, LOG_LOCAL7);
+            } else {
+                for (fac = facilities; fac->t_name; fac++) {
+                    if (!strncasecmp(fname, fac->t_name, flen)) {
+                        openlog(tag, LOG_NDELAY|LOG_CONS|LOG_PID,
+                                fac->t_val);
+                        s->error_log = NULL;
+                        return OK;
+                    }
+                }
+                /* Huh? Invalid level name? */
+                ap_log_error(APLOG_MARK, APLOG_STARTUP, APR_EBADPATH, NULL, APLOGNO(10036)
+                             "%s: could not open syslog error log %s.",
+                              ap_server_argv0, fname);
+                return DONE;
             }
         }
         else {
diff --git a/server/main.c b/server/main.c
index ba9d91c..ec0ea68 100644
--- a/server/main.c
+++ b/server/main.c
@@ -477,9 +477,12 @@ int main(int argc, const char * const argv[])
 
     apr_pool_create(&pcommands, ap_pglobal);
     apr_pool_tag(pcommands, "pcommands");
-    ap_server_pre_read_config  = apr_array_make(pcommands, 1, sizeof(char *));
-    ap_server_post_read_config = apr_array_make(pcommands, 1, sizeof(char *));
-    ap_server_config_defines   = apr_array_make(pcommands, 1, sizeof(char *));
+    ap_server_pre_read_config  = apr_array_make(pcommands, 1,
+                                                sizeof(const char *));
+    ap_server_post_read_config = apr_array_make(pcommands, 1,
+                                                sizeof(const char *));
+    ap_server_config_defines   = apr_array_make(pcommands, 1,
+                                                sizeof(const char *));
 
     error = ap_setup_prelinked_modules(process);
     if (error) {
@@ -497,16 +500,16 @@ int main(int argc, const char * const argv[])
 
     while ((rv = apr_getopt(opt, AP_SERVER_BASEARGS, &c, &opt_arg))
             == APR_SUCCESS) {
-        char **new;
+        const char **new;
 
         switch (c) {
         case 'c':
-            new = (char **)apr_array_push(ap_server_post_read_config);
+            new = (const char **)apr_array_push(ap_server_post_read_config);
             *new = apr_pstrdup(pcommands, opt_arg);
             break;
 
         case 'C':
-            new = (char **)apr_array_push(ap_server_pre_read_config);
+            new = (const char **)apr_array_push(ap_server_pre_read_config);
             *new = apr_pstrdup(pcommands, opt_arg);
             break;
 
@@ -515,7 +518,7 @@ int main(int argc, const char * const argv[])
             break;
 
         case 'D':
-            new = (char **)apr_array_push(ap_server_config_defines);
+            new = (const char **)apr_array_push(ap_server_config_defines);
             *new = apr_pstrdup(pcommands, opt_arg);
             /* Setting -D DUMP_VHOSTS should work like setting -S */
             if (strcmp(opt_arg, "DUMP_VHOSTS") == 0)
@@ -541,7 +544,7 @@ int main(int argc, const char * const argv[])
             break;
 
         case 'X':
-            new = (char **)apr_array_push(ap_server_config_defines);
+            new = (const char **)apr_array_push(ap_server_config_defines);
             *new = "DEBUG";
             break;
 
@@ -574,15 +577,15 @@ int main(int argc, const char * const argv[])
 
         case 'S':
             ap_run_mode = AP_SQ_RM_CONFIG_DUMP;
-            new = (char **)apr_array_push(ap_server_config_defines);
+            new = (const char **)apr_array_push(ap_server_config_defines);
             *new = "DUMP_VHOSTS";
-            new = (char **)apr_array_push(ap_server_config_defines);
+            new = (const char **)apr_array_push(ap_server_config_defines);
             *new = "DUMP_RUN_CFG";
             break;
 
         case 'M':
             ap_run_mode = AP_SQ_RM_CONFIG_DUMP;
-            new = (char **)apr_array_push(ap_server_config_defines);
+            new = (const char **)apr_array_push(ap_server_config_defines);
             *new = "DUMP_MODULES";
             break;
 
diff --git a/server/mpm/event/event.c b/server/mpm/event/event.c
index 6bbc8e5..891ed3b 100644
--- a/server/mpm/event/event.c
+++ b/server/mpm/event/event.c
@@ -177,6 +177,7 @@ static int dying = 0;
 static int workers_may_exit = 0;
 static int start_thread_may_exit = 0;
 static int listener_may_exit = 0;
+static int listener_is_wakeable = 0;        /* Pollset supports APR_POLLSET_WAKEABLE */
 static int num_listensocks = 0;
 static apr_int32_t conns_this_child;        /* MaxConnectionsPerChild, only access
                                                in listener thread */
@@ -198,6 +199,25 @@ module AP_MODULE_DECLARE_DATA mpm_event_module;
 struct event_srv_cfg_s;
 typedef struct event_srv_cfg_s event_srv_cfg;
 
+static apr_pollfd_t *listener_pollfd;
+
+/*
+ * The pollset for sockets that are in any of the timeout queues. Currently
+ * we use the timeout_mutex to make sure that connections are added/removed
+ * atomically to/from both event_pollset and a timeout queue. Otherwise
+ * some confusion can happen under high load if timeout queues and pollset
+ * get out of sync.
+ * XXX: It should be possible to make the lock unnecessary in many or even all
+ * XXX: cases.
+ */
+static apr_pollset_t *event_pollset;
+
+/*
+ * The chain of connections to be shutdown by a worker thread (deferred),
+ * linked list updated atomically.
+ */
+static event_conn_state_t *volatile defer_linger_chain;
+
 struct event_conn_state_t {
     /** APR_RING of expiration timeouts */
     APR_RING_ENTRY(event_conn_state_t) timeout_list;
@@ -222,14 +242,18 @@ struct event_conn_state_t {
     apr_pollfd_t pfd;
     /** public parts of the connection state */
     conn_state_t pub;
+    /** chaining in defer_linger_chain */
+    struct event_conn_state_t *chain;
 };
+
 APR_RING_HEAD(timeout_head_t, event_conn_state_t);
 
 struct timeout_queue {
     struct timeout_head_t head;
-    int count, *total;
     apr_interval_time_t timeout;
-    struct timeout_queue *next;
+    apr_uint32_t count;         /* for this queue */
+    apr_uint32_t *total;        /* for all chained/related queues */
+    struct timeout_queue *next; /* chaining */
 };
 /*
  * Several timeout queues that use different timeouts, so that we always can
@@ -243,51 +267,64 @@ static struct timeout_queue *write_completion_q,
                             *keepalive_q,
                             *linger_q,
                             *short_linger_q;
+static volatile apr_time_t  queues_next_expiry;
 
-static apr_pollfd_t *listener_pollfd;
+/* Prevent extra poll/wakeup calls for timeouts close in the future (queues
+ * have the granularity of a second anyway).
+ * XXX: Wouldn't 0.5s (instead of 0.1s) be "enough"?
+ */
+#define TIMEOUT_FUDGE_FACTOR apr_time_from_msec(100)
 
 /*
  * Macros for accessing struct timeout_queue.
  * For TO_QUEUE_APPEND and TO_QUEUE_REMOVE, timeout_mutex must be held.
  */
-#define TO_QUEUE_APPEND(q, el)                                                \
-    do {                                                                      \
-        APR_RING_INSERT_TAIL(&(q)->head, el, event_conn_state_t,              \
-                             timeout_list);                                   \
-        ++*(q)->total;                                                        \
-        ++(q)->count;                                                         \
-    } while (0)
-
-#define TO_QUEUE_REMOVE(q, el)                                                \
-    do {                                                                      \
-        APR_RING_REMOVE(el, timeout_list);                                    \
-        --*(q)->total;                                                        \
-        --(q)->count;                                                         \
-    } while (0)
-
-#define TO_QUEUE_INIT(q, p, t, v)                                             \
-    do {                                                                      \
-        struct timeout_queue *b = (v);                                        \
-        (q) = apr_palloc((p), sizeof *(q));                                   \
-        APR_RING_INIT(&(q)->head, event_conn_state_t, timeout_list);          \
-        (q)->total = (b) ? (b)->total : apr_pcalloc((p), sizeof *(q)->total); \
-        (q)->count = 0;                                                       \
-        (q)->timeout = (t);                                                   \
-        (q)->next = NULL;                                                     \
-    } while (0)
-
-#define TO_QUEUE_ELEM_INIT(el) APR_RING_ELEM_INIT(el, timeout_list)
+static void TO_QUEUE_APPEND(struct timeout_queue *q, event_conn_state_t *el)
+{
+    apr_time_t q_expiry;
+    apr_time_t next_expiry;
 
-/*
- * The pollset for sockets that are in any of the timeout queues. Currently
- * we use the timeout_mutex to make sure that connections are added/removed
- * atomically to/from both event_pollset and a timeout queue. Otherwise
- * some confusion can happen under high load if timeout queues and pollset
- * get out of sync.
- * XXX: It should be possible to make the lock unnecessary in many or even all
- * XXX: cases.
- */
-static apr_pollset_t *event_pollset;
+    APR_RING_INSERT_TAIL(&q->head, el, event_conn_state_t, timeout_list);
+    apr_atomic_inc32(q->total);
+    ++q->count;
+
+    /* Cheaply update the overall queues' next expiry according to the
+     * first entry of this queue (oldest), if necessary.
+     */
+    el = APR_RING_FIRST(&q->head);
+    q_expiry = el->queue_timestamp + q->timeout;
+    next_expiry = queues_next_expiry;
+    if (!next_expiry || next_expiry > q_expiry + TIMEOUT_FUDGE_FACTOR) {
+        queues_next_expiry = q_expiry;
+        /* Unblock the poll()ing listener for it to update its timeout. */
+        if (listener_is_wakeable) {
+            apr_pollset_wakeup(event_pollset);
+        }
+    }
+}
+
+static void TO_QUEUE_REMOVE(struct timeout_queue *q, event_conn_state_t *el)
+{
+    APR_RING_REMOVE(el, timeout_list);
+    apr_atomic_dec32(q->total);
+    --q->count;
+}
+
+static struct timeout_queue *TO_QUEUE_MAKE(apr_pool_t *p, apr_time_t t,
+                                           struct timeout_queue *ref)
+{
+    struct timeout_queue *q;
+                                           
+    q = apr_pcalloc(p, sizeof *q);
+    APR_RING_INIT(&q->head, event_conn_state_t, timeout_list);
+    q->total = (ref) ? ref->total : apr_pcalloc(p, sizeof *q->total);
+    q->timeout = t;
+
+    return q;
+}
+
+#define TO_QUEUE_ELEM_INIT(el) \
+    APR_RING_ELEM_INIT((el), timeout_list)
 
 /* The structure used to pass unique initialization info to each thread */
 typedef struct
@@ -446,14 +483,55 @@ static void enable_listensocks(int process_slot)
     ap_scoreboard_image->parent[process_slot].not_accepting = 0;
 }
 
+static void abort_socket_nonblocking(apr_socket_t *csd)
+{
+    apr_status_t rv;
+    apr_socket_timeout_set(csd, 0);
+#if defined(SOL_SOCKET) && defined(SO_LINGER)
+    /* This socket is over now, and we don't want to block nor linger
+     * anymore, so reset it. A normal close could still linger in the
+     * system, while RST is fast, nonblocking, and what the peer will
+     * get if it sends us further data anyway.
+     */
+    {
+        apr_os_sock_t osd = -1;
+        struct linger opt;
+        opt.l_onoff = 1;
+        opt.l_linger = 0; /* zero timeout is RST */
+        apr_os_sock_get(&osd, csd);
+        setsockopt(osd, SOL_SOCKET, SO_LINGER, (void *)&opt, sizeof opt);
+    }
+#endif
+    rv = apr_socket_close(csd);
+    if (rv != APR_SUCCESS) {
+        ap_log_error(APLOG_MARK, APLOG_ERR, rv, ap_server_conf, APLOGNO(00468)
+                     "error closing socket");
+        AP_DEBUG_ASSERT(0);
+    }
+}
+
 static void close_worker_sockets(void)
 {
     int i;
     for (i = 0; i < threads_per_child; i++) {
-        if (worker_sockets[i]) {
-            apr_socket_close(worker_sockets[i]);
+        apr_socket_t *csd = worker_sockets[i];
+        if (csd) {
             worker_sockets[i] = NULL;
+            abort_socket_nonblocking(csd);
+        }
+    }
+    for (;;) {
+        event_conn_state_t *cs = defer_linger_chain;
+        if (!cs) {
+            break;
+        }
+        if (apr_atomic_casptr((void *)&defer_linger_chain, cs->chain,
+                              cs) != cs) {
+            /* Race lost, try again */
+            continue;
         }
+        cs->chain = NULL;
+        abort_socket_nonblocking(cs->pfd.desc.s);
     }
 }
 
@@ -469,6 +547,11 @@ static void wakeup_listener(void)
         return;
     }
 
+    /* Unblock the listener if it's poll()ing */
+    if (listener_is_wakeable) {
+        apr_pollset_wakeup(event_pollset);
+    }
+
     /* unblock the listener if it's waiting for a worker */
     ap_queue_info_term(worker_queue_info);
 
@@ -638,7 +721,11 @@ static apr_status_t decrement_connection_count(void *cs_)
         default:
             break;
     }
-    apr_atomic_dec32(&connection_count);
+    /* Unblock the listener if it's waiting for connection_count = 0 */
+    if (!apr_atomic_dec32(&connection_count)
+             && listener_is_wakeable && listener_may_exit) {
+        apr_pollset_wakeup(event_pollset);
+    }
     return APR_SUCCESS;
 }
 
@@ -656,11 +743,27 @@ static void notify_resume(event_conn_state_t *cs, ap_sb_handle_t *sbh)
     ap_run_resume_connection(cs->c, cs->r);
 }
 
-static int start_lingering_close_common(event_conn_state_t *cs, int in_worker)
+/*
+ * Close our side of the connection, flushing data to the client first.
+ * Pre-condition: cs is not in any timeout queue and not in the pollset,
+ *                timeout_mutex is not locked
+ * return: 0 if connection is fully closed,
+ *         1 if connection is lingering
+ * May only be called by worker thread.
+ */
+static int start_lingering_close_blocking(event_conn_state_t *cs)
 {
     apr_status_t rv;
     struct timeout_queue *q;
     apr_socket_t *csd = cs->pfd.desc.s;
+
+    if (ap_start_lingering_close(cs->c)) {
+        notify_suspend(cs);
+        apr_socket_close(csd);
+        ap_push_pool(worker_queue_info, cs->p);
+        return 0;
+    }
+
 #ifdef AP_DEBUG
     {
         rv = apr_socket_timeout_set(csd, 0);
@@ -669,6 +772,7 @@ static int start_lingering_close_common(event_conn_state_t *cs, int in_worker)
 #else
     apr_socket_timeout_set(csd, 0);
 #endif
+
     cs->queue_timestamp = apr_time_now();
     /*
      * If some module requested a shortened waiting period, only wait for
@@ -684,18 +788,14 @@ static int start_lingering_close_common(event_conn_state_t *cs, int in_worker)
         cs->pub.state = CONN_STATE_LINGER_NORMAL;
     }
     apr_atomic_inc32(&lingering_count);
-    if (in_worker) { 
-        notify_suspend(cs);
-    }
-    else {
-        cs->c->sbh = NULL;
-    }
-    apr_thread_mutex_lock(timeout_mutex);
-    TO_QUEUE_APPEND(q, cs);
+    notify_suspend(cs);
+
     cs->pfd.reqevents = (
             cs->pub.sense == CONN_SENSE_WANT_WRITE ? APR_POLLOUT :
                     APR_POLLIN) | APR_POLLHUP | APR_POLLERR;
     cs->pub.sense = CONN_SENSE_DEFAULT;
+    apr_thread_mutex_lock(timeout_mutex);
+    TO_QUEUE_APPEND(q, cs);
     rv = apr_pollset_add(event_pollset, &cs->pfd);
     apr_thread_mutex_unlock(timeout_mutex);
     if (rv != APR_SUCCESS && !APR_STATUS_IS_EEXIST(rv)) {
@@ -712,49 +812,25 @@ static int start_lingering_close_common(event_conn_state_t *cs, int in_worker)
 }
 
 /*
- * Close our side of the connection, flushing data to the client first.
+ * Defer flush and close of the connection by adding it to defer_linger_chain,
+ * for a worker to grab it and do the job (should that be blocking).
  * Pre-condition: cs is not in any timeout queue and not in the pollset,
  *                timeout_mutex is not locked
- * return: 0 if connection is fully closed,
- *         1 if connection is lingering
- * May only be called by worker thread.
- */
-static int start_lingering_close_blocking(event_conn_state_t *cs)
-{
-    if (ap_start_lingering_close(cs->c)) {
-        notify_suspend(cs);
-        ap_push_pool(worker_queue_info, cs->p);
-        return 0;
-    }
-    return start_lingering_close_common(cs, 1);
-}
-
-/*
- * Close our side of the connection, NOT flushing data to the client.
- * This should only be called if there has been an error or if we know
- * that our send buffers are empty.
- * Pre-condition: cs is not in any timeout queue and not in the pollset,
- *                timeout_mutex is not locked
- * return: 0 if connection is fully closed,
- *         1 if connection is lingering
- * may be called by listener thread
+ * return: 1 connection is alive (but aside and about to linger)
+ * May be called by listener thread.
  */
 static int start_lingering_close_nonblocking(event_conn_state_t *cs)
 {
-    conn_rec *c = cs->c;
-    apr_socket_t *csd = cs->pfd.desc.s;
-
-    if (ap_prep_lingering_close(c)
-        || c->aborted
-        || ap_shutdown_conn(c, 0) != APR_SUCCESS || c->aborted
-        || apr_socket_shutdown(csd, APR_SHUTDOWN_WRITE) != APR_SUCCESS) {
-        apr_socket_close(csd);
-        ap_push_pool(worker_queue_info, cs->p);
-        if (dying)
-            ap_queue_interrupt_one(worker_queue);
-        return 0;
+    event_conn_state_t *chain;
+    for (;;) {
+        cs->chain = chain = defer_linger_chain;
+        if (apr_atomic_casptr((void *)&defer_linger_chain, cs,
+                              chain) != chain) {
+            /* Race lost, try again */
+            continue;
+        }
+        return 1;
     }
-    return start_lingering_close_common(cs, 0);
 }
 
 /*
@@ -765,15 +841,10 @@ static int start_lingering_close_nonblocking(event_conn_state_t *cs)
  */
 static int stop_lingering_close(event_conn_state_t *cs)
 {
-    apr_status_t rv;
     apr_socket_t *csd = ap_get_conn_socket(cs->c);
     ap_log_error(APLOG_MARK, APLOG_TRACE4, 0, ap_server_conf,
                  "socket reached timeout in lingering-close state");
-    rv = apr_socket_close(csd);
-    if (rv != APR_SUCCESS) {
-        ap_log_error(APLOG_MARK, APLOG_ERR, rv, ap_server_conf, APLOGNO(00468) "error closing socket");
-        AP_DEBUG_ASSERT(0);
-    }
+    abort_socket_nonblocking(csd);
     ap_push_pool(worker_queue_info, cs->p);
     if (dying)
         ap_queue_interrupt_one(worker_queue);
@@ -922,9 +993,16 @@ static void process_socket(apr_thread_t *thd, apr_pool_t * p, apr_socket_t * soc
         c->current_thread = thd;
         /* Subsequent request on a conn, and thread number is part of ID */
         c->id = conn_id;
+
+        if (c->aborted) {
+            cs->pub.state = CONN_STATE_LINGER;
+        }
     }
 
-    if (c->clogging_input_filters && !c->aborted) {
+    if (cs->pub.state == CONN_STATE_LINGER) {
+        /* do lingering close below */
+    }
+    else if (c->clogging_input_filters) {
         /* Since we have an input filter which 'clogs' the input stream,
          * like mod_ssl used to, lets just do the normal read from input
          * filters, like the Worker MPM does. Filters that need to write
@@ -938,20 +1016,14 @@ static void process_socket(apr_thread_t *thd, apr_pool_t * p, apr_socket_t * soc
         }
         apr_atomic_dec32(&clogged_count);
     }
-
+    else if (cs->pub.state == CONN_STATE_READ_REQUEST_LINE) {
 read_request:
-    if (cs->pub.state == CONN_STATE_READ_REQUEST_LINE) {
-        if (!c->aborted) {
-            ap_run_process_connection(c);
+        ap_run_process_connection(c);
 
-            /* state will be updated upon return
-             * fall thru to either wait for readability/timeout or
-             * do lingering close
-             */
-        }
-        else {
-            cs->pub.state = CONN_STATE_LINGER;
-        }
+        /* state will be updated upon return
+         * fall thru to either wait for readability/timeout or
+         * do lingering close
+         */
     }
 
     if (cs->pub.state == CONN_STATE_WRITE_COMPLETION) {
@@ -974,18 +1046,28 @@ read_request:
              */
             cs->queue_timestamp = apr_time_now();
             notify_suspend(cs);
-            apr_thread_mutex_lock(timeout_mutex);
-            TO_QUEUE_APPEND(cs->sc->wc_q, cs);
             cs->pfd.reqevents = (
                     cs->pub.sense == CONN_SENSE_WANT_READ ? APR_POLLIN :
                             APR_POLLOUT) | APR_POLLHUP | APR_POLLERR;
             cs->pub.sense = CONN_SENSE_DEFAULT;
+            apr_thread_mutex_lock(timeout_mutex);
+            TO_QUEUE_APPEND(cs->sc->wc_q, cs);
             rc = apr_pollset_add(event_pollset, &cs->pfd);
             apr_thread_mutex_unlock(timeout_mutex);
+            if (rc != APR_SUCCESS && !APR_STATUS_IS_EEXIST(rc)) {
+                ap_log_error(APLOG_MARK, APLOG_ERR, rc, ap_server_conf, APLOGNO(03465)
+                             "process_socket: apr_pollset_add failure for "
+                             "write completion");
+                apr_thread_mutex_lock(timeout_mutex);
+                TO_QUEUE_REMOVE(cs->sc->wc_q, cs);
+                apr_thread_mutex_unlock(timeout_mutex);
+                apr_socket_close(cs->pfd.desc.s);
+                ap_push_pool(worker_queue_info, cs->p);
+            }
             return;
         }
         else if (c->keepalive != AP_CONN_KEEPALIVE || c->aborted ||
-            listener_may_exit) {
+                 listener_may_exit) {
             cs->pub.state = CONN_STATE_LINGER;
         }
         else if (c->data_in_input_filters) {
@@ -1011,18 +1093,23 @@ read_request:
          */
         cs->queue_timestamp = apr_time_now();
         notify_suspend(cs);
-        apr_thread_mutex_lock(timeout_mutex);
-        TO_QUEUE_APPEND(cs->sc->ka_q, cs);
 
         /* Add work to pollset. */
         cs->pfd.reqevents = APR_POLLIN;
+        apr_thread_mutex_lock(timeout_mutex);
+        TO_QUEUE_APPEND(cs->sc->ka_q, cs);
         rc = apr_pollset_add(event_pollset, &cs->pfd);
         apr_thread_mutex_unlock(timeout_mutex);
-
-        if (rc != APR_SUCCESS) {
+        if (rc != APR_SUCCESS && !APR_STATUS_IS_EEXIST(rc)) {
             ap_log_error(APLOG_MARK, APLOG_ERR, rc, ap_server_conf, APLOGNO(03093)
-                         "process_socket: apr_pollset_add failure");
-            AP_DEBUG_ASSERT(rc == APR_SUCCESS);
+                         "process_socket: apr_pollset_add failure for "
+                         "keep alive");
+            apr_thread_mutex_lock(timeout_mutex);
+            TO_QUEUE_REMOVE(cs->sc->ka_q, cs);
+            apr_thread_mutex_unlock(timeout_mutex);
+            apr_socket_close(cs->pfd.desc.s);
+            ap_push_pool(worker_queue_info, cs->p);
+            return;
         }
     }
     else if (cs->pub.state == CONN_STATE_SUSPENDED) {
@@ -1125,26 +1212,32 @@ static apr_status_t push_timer2worker(timer_event_t* te)
 }
 
 /*
- * Pre-condition: pfd->cs is neither in pollset nor timeout queue
+ * Pre-condition: cs is neither in event_pollset nor a timeout queue
  * this function may only be called by the listener
  */
-static apr_status_t push2worker(const apr_pollfd_t * pfd,
-                                apr_pollset_t * pollset)
+static apr_status_t push2worker(event_conn_state_t *cs, apr_socket_t *csd,
+                                apr_pool_t *ptrans)
 {
-    listener_poll_type *pt = (listener_poll_type *) pfd->client_data;
-    event_conn_state_t *cs = (event_conn_state_t *) pt->baton;
     apr_status_t rc;
 
-    rc = ap_queue_push(worker_queue, cs->pfd.desc.s, cs, cs->p);
+    if (cs) {
+        csd = cs->pfd.desc.s;
+        ptrans = cs->p;
+    }
+    rc = ap_queue_push(worker_queue, csd, cs, ptrans);
     if (rc != APR_SUCCESS) {
+        ap_log_error(APLOG_MARK, APLOG_CRIT, rc, ap_server_conf, APLOGNO(00471)
+                     "push2worker: ap_queue_push failed");
         /* trash the connection; we couldn't queue the connected
          * socket to a worker
          */
-        apr_bucket_alloc_destroy(cs->bucket_alloc);
-        apr_socket_close(cs->pfd.desc.s);
-        ap_log_error(APLOG_MARK, APLOG_CRIT, rc,
-                     ap_server_conf, APLOGNO(00471) "push2worker: ap_queue_push failed");
-        ap_push_pool(worker_queue_info, cs->p);
+        if (csd) {
+            abort_socket_nonblocking(csd);
+        }
+        if (ptrans) {
+            ap_push_pool(worker_queue_info, ptrans);
+        }
+        signal_threads(ST_GRACEFUL);
     }
 
     return rc;
@@ -1193,6 +1286,13 @@ static void get_worker(int *have_idle_worker_p, int blocking, int *all_busy)
 static APR_RING_HEAD(timer_free_ring_t, timer_event_t) timer_free_ring;
 
 static apr_skiplist *timer_skiplist;
+static volatile apr_time_t timers_next_expiry;
+
+/* Same goal as for TIMEOUT_FUDGE_FACTOR (avoid extra poll calls), but applied
+ * to timers. Since their timeouts are custom (user defined), we can't be too
+ * approximative here (hence using 0.01s).
+ */
+#define EVENT_FUDGE_FACTOR apr_time_from_msec(10)
 
 /* The following compare function is used by apr_skiplist_insert() to keep the
  * elements (timers) sorted and provide O(log n) complexity (this is also true
@@ -1239,8 +1339,24 @@ static apr_status_t event_register_timed_callback(apr_time_t t,
     /* XXXXX: optimize */
     te->when = t + apr_time_now();
 
-    /* Okay, add sorted by when.. */
-    apr_skiplist_insert(timer_skiplist, te);
+    { 
+        apr_time_t next_expiry;
+
+        /* Okay, add sorted by when.. */
+        apr_skiplist_insert(timer_skiplist, te);
+
+        /* Cheaply update the overall timers' next expiry according to
+         * this event, if necessary.
+         */
+        next_expiry = timers_next_expiry;
+        if (!next_expiry || next_expiry > te->when + EVENT_FUDGE_FACTOR) {
+            timers_next_expiry = te->when;
+            /* Unblock the poll()ing listener for it to update its timeout. */
+            if (listener_is_wakeable) {
+                apr_pollset_wakeup(event_pollset);
+            }
+        }
+    }
 
     apr_thread_mutex_unlock(g_timer_skiplist_mtx);
 
@@ -1274,16 +1390,15 @@ static void process_lingering_close(event_conn_state_t *cs, const apr_pollfd_t *
     }
 
     apr_thread_mutex_lock(timeout_mutex);
+    TO_QUEUE_REMOVE(q, cs);
     rv = apr_pollset_remove(event_pollset, pfd);
-    AP_DEBUG_ASSERT(rv == APR_SUCCESS);
+    apr_thread_mutex_unlock(timeout_mutex);
+    AP_DEBUG_ASSERT(rv == APR_SUCCESS ||  APR_STATUS_IS_NOTFOUND(rv));
+    TO_QUEUE_ELEM_INIT(cs);
 
     rv = apr_socket_close(csd);
     AP_DEBUG_ASSERT(rv == APR_SUCCESS);
 
-    TO_QUEUE_REMOVE(q, cs);
-    apr_thread_mutex_unlock(timeout_mutex);
-    TO_QUEUE_ELEM_INIT(cs);
-
     ap_push_pool(worker_queue_info, cs->p);
     if (dying)
         ap_queue_interrupt_one(worker_queue);
@@ -1297,13 +1412,13 @@ static void process_timeout_queue(struct timeout_queue *q,
                                   apr_time_t timeout_time,
                                   int (*func)(event_conn_state_t *))
 {
-    int total = 0, count;
+    apr_uint32_t total = 0, count;
     event_conn_state_t *first, *cs, *last;
     struct timeout_head_t trash;
     struct timeout_queue *qp;
     apr_status_t rv;
 
-    if (!*q->total) {
+    if (!apr_atomic_read32(q->total)) {
         return;
     }
 
@@ -1312,20 +1427,32 @@ static void process_timeout_queue(struct timeout_queue *q,
         count = 0;
         cs = first = last = APR_RING_FIRST(&qp->head);
         while (cs != APR_RING_SENTINEL(&qp->head, event_conn_state_t,
-                                       timeout_list)
-               /* Trash the entry if:
-                * - no timeout_time was given (asked for all), or
-                * - it expired (according to the queue timeout), or
-                * - the system clock skewed in the past: no entry should be
-                *   registered above the given timeout_time (~now) + the queue
-                *   timeout, we won't keep any here (eg. for centuries).
-                * Stop otherwise, no following entry will match thanks to the
-                * single timeout per queue (entries are added to the end!).
-                * This allows maintenance in O(1).
-                */
-               && (!timeout_time
-                   || cs->queue_timestamp + qp->timeout < timeout_time
-                   || cs->queue_timestamp > timeout_time + qp->timeout)) {
+                                       timeout_list)) {
+            /* Trash the entry if:
+             * - no timeout_time was given (asked for all), or
+             * - it expired (according to the queue timeout), or
+             * - the system clock skewed in the past: no entry should be
+             *   registered above the given timeout_time (~now) + the queue
+             *   timeout, we won't keep any here (eg. for centuries).
+             *
+             * Otherwise stop, no following entry will match thanks to the
+             * single timeout per queue (entries are added to the end!).
+             * This allows maintenance in O(1).
+             */
+            if (timeout_time
+                    && cs->queue_timestamp + qp->timeout > timeout_time
+                    && cs->queue_timestamp < timeout_time + qp->timeout) {
+                /* Since this is the next expiring of this queue, update the
+                 * overall queues' next expiry if it's later than this one.
+                 */
+                apr_time_t q_expiry = cs->queue_timestamp + qp->timeout;
+                apr_time_t next_expiry = queues_next_expiry;
+                if (!next_expiry || next_expiry > q_expiry) {
+                    queues_next_expiry = q_expiry;
+                }
+                break;
+            }
+
             last = cs;
             rv = apr_pollset_remove(event_pollset, &cs->pfd);
             if (rv != APR_SUCCESS && !APR_STATUS_IS_NOTFOUND(rv)) {
@@ -1341,14 +1468,14 @@ static void process_timeout_queue(struct timeout_queue *q,
         APR_RING_UNSPLICE(first, last, timeout_list);
         APR_RING_SPLICE_TAIL(&trash, first, last, event_conn_state_t,
                              timeout_list);
+        AP_DEBUG_ASSERT(apr_atomic_read32(q->total) >= count);
+        apr_atomic_sub32(q->total, count);
         qp->count -= count;
         total += count;
     }
     if (!total)
         return;
 
-    AP_DEBUG_ASSERT(*q->total >= total);
-    *q->total -= total;
     apr_thread_mutex_unlock(timeout_mutex);
     first = APR_RING_FIRST(&trash);
     do {
@@ -1360,13 +1487,28 @@ static void process_timeout_queue(struct timeout_queue *q,
     apr_thread_mutex_lock(timeout_mutex);
 }
 
+static void process_keepalive_queue(apr_time_t timeout_time)
+{
+    /* If all workers are busy, we kill older keep-alive connections so
+     * that they may connect to another process.
+     */
+    if (!timeout_time) {
+        ap_log_error(APLOG_MARK, APLOG_TRACE1, 0, ap_server_conf,
+                     "All workers are busy or dying, will close %u "
+                     "keep-alive connections",
+                     apr_atomic_read32(keepalive_q->total));
+    }
+    process_timeout_queue(keepalive_q, timeout_time,
+                          start_lingering_close_nonblocking);
+}
+
 static void * APR_THREAD_FUNC listener_thread(apr_thread_t * thd, void *dummy)
 {
-    timer_event_t *ep;
     timer_event_t *te;
     apr_status_t rc;
     proc_info *ti = dummy;
     int process_slot = ti->pslot;
+    struct process_score *ps = ap_get_scoreboard_process(process_slot);
     apr_pool_t *tpool = apr_thread_pool_get(thd);
     void *csd = NULL;
     apr_pool_t *ptrans;         /* Pool for per-transaction stuff */
@@ -1382,14 +1524,6 @@ static void * APR_THREAD_FUNC listener_thread(apr_thread_t * thd, void *dummy)
     last_log = apr_time_now();
     free(ti);
 
-    /* the following times out events that are really close in the future
-     *   to prevent extra poll calls
-     *
-     * current value is .1 second
-     */
-#define TIMEOUT_FUDGE_FACTOR 100000
-#define EVENT_FUDGE_FACTOR 10000
-
     rc = init_pollset(tpool);
     if (rc != APR_SUCCESS) {
         ap_log_error(APLOG_MARK, APLOG_ERR, rc, ap_server_conf,
@@ -1407,6 +1541,7 @@ static void * APR_THREAD_FUNC listener_thread(apr_thread_t * thd, void *dummy)
 
     for (;;) {
         int workers_were_busy = 0;
+
         if (listener_may_exit) {
             close_listeners(process_slot, &closed);
             if (terminate_mode == ST_UNGRACEFUL
@@ -1420,7 +1555,7 @@ static void * APR_THREAD_FUNC listener_thread(apr_thread_t * thd, void *dummy)
         now = apr_time_now();
         if (APLOGtrace6(ap_server_conf)) {
             /* trace log status every second */
-            if (now - last_log > apr_time_from_msec(1000)) {
+            if (now - last_log > apr_time_from_sec(1)) {
                 last_log = now;
                 apr_thread_mutex_lock(timeout_mutex);
                 ap_log_error(APLOG_MARK, APLOG_TRACE6, 0, ap_server_conf,
@@ -1428,8 +1563,8 @@ static void * APR_THREAD_FUNC listener_thread(apr_thread_t * thd, void *dummy)
                              "keep-alive: %d lingering: %d suspended: %u)",
                              apr_atomic_read32(&connection_count),
                              apr_atomic_read32(&clogged_count),
-                             *write_completion_q->total,
-                             *keepalive_q->total,
+                             apr_atomic_read32(write_completion_q->total),
+                             apr_atomic_read32(keepalive_q->total),
                              apr_atomic_read32(&lingering_count),
                              apr_atomic_read32(&suspended_count));
                 if (dying) {
@@ -1442,32 +1577,71 @@ static void * APR_THREAD_FUNC listener_thread(apr_thread_t * thd, void *dummy)
             }
         }
 
-        apr_thread_mutex_lock(g_timer_skiplist_mtx);
-        te = apr_skiplist_peek(timer_skiplist);
-        if (te) {
-            if (te->when > now) {
-                timeout_interval = te->when - now;
+        /* Start with an infinite poll() timeout and update it according to
+         * the next expiring timer or queue entry. If there are none, either
+         * the listener is wakeable and it can poll() indefinitely until a wake
+         * up occurs, otherwise periodic checks (maintenance, shutdown, ...)
+         * must be performed.
+         */
+        timeout_interval = -1;
+
+        /* Push expired timers to a worker, the first remaining one determines
+         * the maximum time to poll() below, if any.
+         */
+        timeout_time = timers_next_expiry;
+        if (timeout_time && timeout_time < now + EVENT_FUDGE_FACTOR) {
+            apr_thread_mutex_lock(g_timer_skiplist_mtx);
+            while ((te = apr_skiplist_peek(timer_skiplist))) {
+                if (te->when > now + EVENT_FUDGE_FACTOR) {
+                    timers_next_expiry = te->when;
+                    timeout_interval = te->when - now;
+                    break;
+                }
+                apr_skiplist_pop(timer_skiplist, NULL);
+                push_timer2worker(te);
             }
-            else {
-                timeout_interval = 1;
+            if (!te) {
+                timers_next_expiry = 0;
             }
+            apr_thread_mutex_unlock(g_timer_skiplist_mtx);
         }
-        else {
-            timeout_interval = apr_time_from_msec(100);
+
+        /* Same for queues, use their next expiry, if any. */
+        timeout_time = queues_next_expiry;
+        if (timeout_time
+                && (timeout_interval < 0
+                    || timeout_time <= now
+                    || timeout_interval > timeout_time - now)) {
+            timeout_interval = timeout_time > now ? timeout_time - now : 1;
+        }
+
+        /* When non-wakeable, don't wait more than 100 ms, in any case. */
+#define NON_WAKEABLE_POLL_TIMEOUT apr_time_from_msec(100)
+        if (!listener_is_wakeable
+                && (timeout_interval < 0
+                    || timeout_interval > NON_WAKEABLE_POLL_TIMEOUT)) {
+            timeout_interval = NON_WAKEABLE_POLL_TIMEOUT;
         }
-        apr_thread_mutex_unlock(g_timer_skiplist_mtx);
 
         rc = apr_pollset_poll(event_pollset, timeout_interval, &num, &out_pfd);
         if (rc != APR_SUCCESS) {
             if (APR_STATUS_IS_EINTR(rc)) {
-                continue;
+                /* Woken up, if we are exiting we must fall through to kill
+                 * kept-alive connections, otherwise we only need to update
+                 * timeouts (logic is above, so restart the loop).
+                 */
+                if (!listener_may_exit) {
+                    continue;
+                }
+                timeout_time = 0;
             }
-            if (!APR_STATUS_IS_TIMEUP(rc)) {
+            else if (!APR_STATUS_IS_TIMEUP(rc)) {
                 ap_log_error(APLOG_MARK, APLOG_CRIT, rc, ap_server_conf,
                              "apr_pollset_poll failed.  Attempting to "
                              "shutdown process gracefully");
                 signal_threads(ST_GRACEFUL);
             }
+            num = 0;
         }
 
         if (listener_may_exit) {
@@ -1477,21 +1651,6 @@ static void * APR_THREAD_FUNC listener_thread(apr_thread_t * thd, void *dummy)
                 break;
         }
 
-        now = apr_time_now();
-        apr_thread_mutex_lock(g_timer_skiplist_mtx);
-        ep = apr_skiplist_peek(timer_skiplist);
-        while (ep) {
-            if (ep->when < now + EVENT_FUDGE_FACTOR) {
-                apr_skiplist_pop(timer_skiplist, NULL);
-                push_timer2worker(ep);
-            }
-            else {
-                break;
-            }
-            ep = apr_skiplist_peek(timer_skiplist);
-        }
-        apr_thread_mutex_unlock(g_timer_skiplist_mtx);
-
         while (num) {
             pt = (listener_poll_type *) out_pfd->client_data;
             if (pt->type == PT_CSD) {
@@ -1514,6 +1673,7 @@ static void * APR_THREAD_FUNC listener_thread(apr_thread_t * thd, void *dummy)
                     TO_QUEUE_REMOVE(remove_from_q, cs);
                     rc = apr_pollset_remove(event_pollset, &cs->pfd);
                     apr_thread_mutex_unlock(timeout_mutex);
+                    TO_QUEUE_ELEM_INIT(cs);
 
                     /*
                      * Some of the pollset backends, like KQueue or Epoll
@@ -1528,29 +1688,23 @@ static void * APR_THREAD_FUNC listener_thread(apr_thread_t * thd, void *dummy)
                         break;
                     }
 
-                    TO_QUEUE_ELEM_INIT(cs);
                     /* If we didn't get a worker immediately for a keep-alive
                      * request, we close the connection, so that the client can
                      * re-connect to a different process.
                      */
                     if (!have_idle_worker) {
                         start_lingering_close_nonblocking(cs);
-                        break;
-                    }
-                    rc = push2worker(out_pfd, event_pollset);
-                    if (rc != APR_SUCCESS) {
-                        ap_log_error(APLOG_MARK, APLOG_CRIT, rc,
-                                     ap_server_conf, APLOGNO(03095)
-                                     "push2worker failed");
                     }
-                    else {
+                    else if (push2worker(cs, NULL, NULL) == APR_SUCCESS) {
                         have_idle_worker = 0;
                     }
                     break;
+
                 case CONN_STATE_LINGER_NORMAL:
                 case CONN_STATE_LINGER_SHORT:
                     process_lingering_close(cs, out_pfd);
                     break;
+
                 default:
                     ap_log_error(APLOG_MARK, APLOG_CRIT, rc,
                                  ap_server_conf, APLOGNO(03096)
@@ -1629,18 +1783,7 @@ static void * APR_THREAD_FUNC listener_thread(apr_thread_t * thd, void *dummy)
 
                     if (csd != NULL) {
                         conns_this_child--;
-                        rc = ap_queue_push(worker_queue, csd, NULL, ptrans);
-                        if (rc != APR_SUCCESS) {
-                            /* trash the connection; we couldn't queue the connected
-                             * socket to a worker
-                             */
-                            apr_socket_close(csd);
-                            ap_log_error(APLOG_MARK, APLOG_CRIT, rc,
-                                         ap_server_conf, APLOGNO(03098)
-                                         "ap_queue_push failed");
-                            ap_push_pool(worker_queue_info, ptrans);
-                        }
-                        else {
+                        if (push2worker(NULL, csd, ptrans) == APR_SUCCESS) {
                             have_idle_worker = 0;
                         }
                     }
@@ -1656,52 +1799,73 @@ static void * APR_THREAD_FUNC listener_thread(apr_thread_t * thd, void *dummy)
         /* XXX possible optimization: stash the current time for use as
          * r->request_time for new requests
          */
-        now = apr_time_now();
-        /* We only do this once per 0.1s (TIMEOUT_FUDGE_FACTOR), or on a clock
-         * skew (if the system time is set back in the meantime, timeout_time
-         * will exceed now + TIMEOUT_FUDGE_FACTOR, can't happen otherwise).
+        /* We process the timeout queues here only when their overall next
+         * expiry (read once above) is over. This happens accurately since
+         * adding to the queues (in workers) can only decrease this expiry,
+         * while latest ones are only taken into account here (in listener)
+         * during queues' processing, with the lock held. This works both
+         * with and without wake-ability.
          */
-        if (now > timeout_time || now + TIMEOUT_FUDGE_FACTOR < timeout_time ) {
-            struct process_score *ps;
+        if (timeout_time && timeout_time < (now = apr_time_now())) {
             timeout_time = now + TIMEOUT_FUDGE_FACTOR;
 
             /* handle timed out sockets */
             apr_thread_mutex_lock(timeout_mutex);
 
+            /* Processing all the queues below will recompute this. */
+            queues_next_expiry = 0;
+
             /* Step 1: keepalive timeouts */
-            /* If all workers are busy, we kill older keep-alive connections so that they
-             * may connect to another process.
-             */
-            if ((workers_were_busy || dying) && *keepalive_q->total) {
-                if (!dying)
-                    ap_log_error(APLOG_MARK, APLOG_TRACE1, 0, ap_server_conf,
-                                 "All workers are busy, will close %d keep-alive "
-                                 "connections",
-                                 *keepalive_q->total);
-                process_timeout_queue(keepalive_q, 0,
-                                      start_lingering_close_nonblocking);
+            if (workers_were_busy || dying) {
+                process_keepalive_queue(0); /* kill'em all \m/ */
             }
             else {
-                process_timeout_queue(keepalive_q, timeout_time,
-                                      start_lingering_close_nonblocking);
+                process_keepalive_queue(timeout_time);
             }
             /* Step 2: write completion timeouts */
             process_timeout_queue(write_completion_q, timeout_time,
                                   start_lingering_close_nonblocking);
             /* Step 3: (normal) lingering close completion timeouts */
-            process_timeout_queue(linger_q, timeout_time, stop_lingering_close);
+            process_timeout_queue(linger_q, timeout_time,
+                                  stop_lingering_close);
             /* Step 4: (short) lingering close completion timeouts */
-            process_timeout_queue(short_linger_q, timeout_time, stop_lingering_close);
+            process_timeout_queue(short_linger_q, timeout_time,
+                                  stop_lingering_close);
 
-            ps = ap_get_scoreboard_process(process_slot);
-            ps->write_completion = *write_completion_q->total;
-            ps->keep_alive = *keepalive_q->total;
             apr_thread_mutex_unlock(timeout_mutex);
 
+            ps->keep_alive = apr_atomic_read32(keepalive_q->total);
+            ps->write_completion = apr_atomic_read32(write_completion_q->total);
             ps->connections = apr_atomic_read32(&connection_count);
             ps->suspended = apr_atomic_read32(&suspended_count);
             ps->lingering_close = apr_atomic_read32(&lingering_count);
         }
+        else if ((workers_were_busy || dying)
+                 && apr_atomic_read32(keepalive_q->total)) {
+            apr_thread_mutex_lock(timeout_mutex);
+            process_keepalive_queue(0); /* kill'em all \m/ */
+            apr_thread_mutex_unlock(timeout_mutex);
+            ps->keep_alive = 0;
+        }
+
+        /* If there are some lingering closes to defer (to a worker), schedule
+         * them now. We might wakeup a worker spuriously if another one empties
+         * defer_linger_chain in the meantime, but there also may be no active
+         * or all busy workers for an undefined time.  In any case a deferred
+         * lingering close can't starve if we do that here since the chain is
+         * filled only above in the listener and it's emptied only in the
+         * worker(s); thus a NULL here means it will stay so while the listener
+         * waits (possibly indefinitely) in poll().
+         */
+        if (defer_linger_chain) {
+            get_worker(&have_idle_worker, 0, &workers_were_busy);
+            if (have_idle_worker
+                    && defer_linger_chain /* re-test */
+                    && push2worker(NULL, NULL, NULL) == APR_SUCCESS) {
+                have_idle_worker = 0;
+            }
+        }
+
         if (listeners_disabled && !workers_were_busy
             && (int)apr_atomic_read32(&connection_count)
                - (int)apr_atomic_read32(&lingering_count)
@@ -1845,8 +2009,35 @@ static void *APR_THREAD_FUNC worker_thread(apr_thread_t * thd, void *dummy)
         }
         else {
             is_idle = 0;
-            worker_sockets[thread_slot] = csd;
-            process_socket(thd, ptrans, csd, cs, process_slot, thread_slot);
+            if (csd != NULL) {
+                worker_sockets[thread_slot] = csd;
+                process_socket(thd, ptrans, csd, cs, process_slot, thread_slot);
+                worker_sockets[thread_slot] = NULL;
+            }
+        }
+
+        /* If there are deferred lingering closes, handle them now. */
+        while (!workers_may_exit) {
+            cs = defer_linger_chain;
+            if (!cs) {
+                break;
+            }
+            if (apr_atomic_casptr((void *)&defer_linger_chain, cs->chain,
+                                  cs) != cs) {
+                /* Race lost, try again */
+                continue;
+            }
+            cs->chain = NULL;
+
+            worker_sockets[thread_slot] = csd = cs->pfd.desc.s;
+#ifdef AP_DEBUG
+            rv = apr_socket_timeout_set(csd, SECONDS_TO_LINGER);
+            AP_DEBUG_ASSERT(rv == APR_SUCCESS);
+#else
+            apr_socket_timeout_set(csd, SECONDS_TO_LINGER);
+#endif
+            cs->pub.state = CONN_STATE_LINGER;
+            process_socket(thd, cs->p, csd, cs, process_slot, thread_slot);
             worker_sockets[thread_slot] = NULL;
         }
     }
@@ -1912,6 +2103,8 @@ static void *APR_THREAD_FUNC start_threads(apr_thread_t * thd, void *dummy)
     int prev_threads_created;
     int max_recycled_pools = -1;
     int good_methods[] = {APR_POLLSET_KQUEUE, APR_POLLSET_PORT, APR_POLLSET_EPOLL};
+    /* XXX don't we need more to handle K-A or lingering close? */
+    const apr_uint32_t pollset_size = threads_per_child * 2;
 
     /* We must create the fd queues before we start up the listener
      * and worker threads. */
@@ -1951,24 +2144,24 @@ static void *APR_THREAD_FUNC start_threads(apr_thread_t * thd, void *dummy)
 
     /* Create the main pollset */
     for (i = 0; i < sizeof(good_methods) / sizeof(good_methods[0]); i++) {
-        rv = apr_pollset_create_ex(&event_pollset,
-                            threads_per_child*2, /* XXX don't we need more, to handle
-                                                * connections in K-A or lingering
-                                                * close?
-                                                */
-                            pchild, APR_POLLSET_THREADSAFE | APR_POLLSET_NOCOPY | APR_POLLSET_NODEFAULT,
-                            good_methods[i]);
+        apr_uint32_t flags = APR_POLLSET_THREADSAFE | APR_POLLSET_NOCOPY |
+                             APR_POLLSET_NODEFAULT | APR_POLLSET_WAKEABLE;
+        rv = apr_pollset_create_ex(&event_pollset, pollset_size, pchild, flags,
+                                   good_methods[i]);
+        if (rv == APR_SUCCESS) {
+            listener_is_wakeable = 1;
+            break;
+        }
+        flags &= ~APR_POLLSET_WAKEABLE;
+        rv = apr_pollset_create_ex(&event_pollset, pollset_size, pchild, flags,
+                                   good_methods[i]);
         if (rv == APR_SUCCESS) {
             break;
         }
     }
     if (rv != APR_SUCCESS) {
-        rv = apr_pollset_create(&event_pollset,
-                               threads_per_child*2, /* XXX don't we need more, to handle
-                                                     * connections in K-A or lingering
-                                                     * close?
-                                                     */
-                               pchild, APR_POLLSET_THREADSAFE | APR_POLLSET_NOCOPY);
+        rv = apr_pollset_create(&event_pollset, pollset_size, pchild,
+                                APR_POLLSET_THREADSAFE | APR_POLLSET_NOCOPY);
     }
     if (rv != APR_SUCCESS) {
         ap_log_error(APLOG_MARK, APLOG_ERR, rv, ap_server_conf, APLOGNO(03103)
@@ -1977,7 +2170,9 @@ static void *APR_THREAD_FUNC start_threads(apr_thread_t * thd, void *dummy)
     }
 
     ap_log_error(APLOG_MARK, APLOG_DEBUG, 0, ap_server_conf, APLOGNO(02471)
-                 "start_threads: Using %s", apr_pollset_method_name(event_pollset));
+                 "start_threads: Using %s (%swakeable)",
+                 apr_pollset_method_name(event_pollset),
+                 listener_is_wakeable ? "" : "not ");
     worker_sockets = apr_pcalloc(pchild, threads_per_child
                                  * sizeof(apr_socket_t *));
 
@@ -3100,6 +3295,7 @@ static int event_pre_config(apr_pool_t * pconf, apr_pool_t * plog,
     active_daemons_limit = server_limit;
     threads_per_child = DEFAULT_THREADS_PER_CHILD;
     max_workers = active_daemons_limit * threads_per_child;
+    defer_linger_chain = NULL;
     had_healthy_child = 0;
     ap_extended_status = 0;
 
@@ -3123,10 +3319,10 @@ static int event_post_config(apr_pool_t *pconf, apr_pool_t *plog,
     wc.hash = apr_hash_make(ptemp);
     ka.hash = apr_hash_make(ptemp);
 
-    TO_QUEUE_INIT(linger_q, pconf,
-                  apr_time_from_sec(MAX_SECS_TO_LINGER), NULL);
-    TO_QUEUE_INIT(short_linger_q, pconf,
-                  apr_time_from_sec(SECONDS_TO_LINGER), NULL);
+    linger_q = TO_QUEUE_MAKE(pconf, apr_time_from_sec(MAX_SECS_TO_LINGER),
+                             NULL);
+    short_linger_q = TO_QUEUE_MAKE(pconf, apr_time_from_sec(SECONDS_TO_LINGER),
+                                   NULL);
 
     for (; s; s = s->next) {
         event_srv_cfg *sc = apr_pcalloc(pconf, sizeof *sc);
@@ -3134,11 +3330,11 @@ static int event_post_config(apr_pool_t *pconf, apr_pool_t *plog,
         ap_set_module_config(s->module_config, &mpm_event_module, sc);
         if (!wc.tail) {
             /* The main server uses the global queues */
-            TO_QUEUE_INIT(wc.q, pconf, s->timeout, NULL);
+            wc.q = TO_QUEUE_MAKE(pconf, s->timeout, NULL);
             apr_hash_set(wc.hash, &s->timeout, sizeof s->timeout, wc.q);
             wc.tail = write_completion_q = wc.q;
 
-            TO_QUEUE_INIT(ka.q, pconf, s->keep_alive_timeout, NULL);
+            ka.q = TO_QUEUE_MAKE(pconf, s->keep_alive_timeout, NULL);
             apr_hash_set(ka.hash, &s->keep_alive_timeout,
                          sizeof s->keep_alive_timeout, ka.q);
             ka.tail = keepalive_q = ka.q;
@@ -3148,7 +3344,7 @@ static int event_post_config(apr_pool_t *pconf, apr_pool_t *plog,
              * or their own queue(s) if there isn't */
             wc.q = apr_hash_get(wc.hash, &s->timeout, sizeof s->timeout);
             if (!wc.q) {
-                TO_QUEUE_INIT(wc.q, pconf, s->timeout, wc.tail);
+                wc.q = TO_QUEUE_MAKE(pconf, s->timeout, wc.tail);
                 apr_hash_set(wc.hash, &s->timeout, sizeof s->timeout, wc.q);
                 wc.tail = wc.tail->next = wc.q;
             }
@@ -3156,7 +3352,7 @@ static int event_post_config(apr_pool_t *pconf, apr_pool_t *plog,
             ka.q = apr_hash_get(ka.hash, &s->keep_alive_timeout,
                                 sizeof s->keep_alive_timeout);
             if (!ka.q) {
-                TO_QUEUE_INIT(ka.q, pconf, s->keep_alive_timeout, ka.tail);
+                ka.q = TO_QUEUE_MAKE(pconf, s->keep_alive_timeout, ka.tail);
                 apr_hash_set(ka.hash, &s->keep_alive_timeout,
                              sizeof s->keep_alive_timeout, ka.q);
                 ka.tail = ka.tail->next = ka.q;
diff --git a/server/mpm/prefork/prefork.c b/server/mpm/prefork/prefork.c
index 559f90a..a386a75 100644
--- a/server/mpm/prefork/prefork.c
+++ b/server/mpm/prefork/prefork.c
@@ -220,6 +220,9 @@ static void clean_child_exit(int code)
 {
     retained->mpm->mpm_state = AP_MPMQ_STOPPING;
 
+    apr_signal(SIGHUP, SIG_IGN);
+    apr_signal(SIGTERM, SIG_IGN);
+
     if (pchild) {
         apr_pool_destroy(pchild);
     }
@@ -699,6 +702,13 @@ static int make_child(server_rec *s, int slot, int bucket)
          */
         apr_signal(SIGHUP, just_die);
         apr_signal(SIGTERM, just_die);
+        /* Ignore SIGINT in child. This fixes race-condition in signals
+         * handling when httpd is runnning on foreground and user hits ctrl+c.
+         * In this case, SIGINT is sent to all children followed by SIGTERM
+         * from the main process, which interrupts the SIGINT handler and
+         * leads to inconsistency.
+         */
+        apr_signal(SIGINT, SIG_IGN);
         /* The child process just closes listeners on AP_SIG_GRACEFUL.
          * The pod is used for signalling the graceful restart.
          */
diff --git a/server/protocol.c b/server/protocol.c
index edf3ed9..a89e2fe 100644
--- a/server/protocol.c
+++ b/server/protocol.c
@@ -1674,62 +1674,88 @@ AP_CORE_DECLARE_NONSTD(apr_status_t) ap_content_length_filter(
         ctx->tmpbb = apr_brigade_create(r->pool, r->connection->bucket_alloc);
     }
 
-    /* Loop through this set of buckets to compute their length
-     */
+    /* Loop through the brigade to count the length. To avoid
+     * arbitrary memory consumption with morphing bucket types, this
+     * loop will stop and pass on the brigade when necessary. */
     e = APR_BRIGADE_FIRST(b);
     while (e != APR_BRIGADE_SENTINEL(b)) {
+        apr_status_t rv;
+
         if (APR_BUCKET_IS_EOS(e)) {
             eos = 1;
             break;
         }
-        if (e->length == (apr_size_t)-1) {
+        /* For a flush bucket, fall through to pass the brigade and
+         * flush now. */
+        else if (APR_BUCKET_IS_FLUSH(e)) {
+            e = APR_BUCKET_NEXT(e);
+        }
+        /* For metadata bucket types other than FLUSH, loop. */
+        else if (APR_BUCKET_IS_METADATA(e)) {
+            e = APR_BUCKET_NEXT(e);
+            continue;
+        }
+        /* For determinate length data buckets, count the length and
+         * continue. */
+        else if (e->length != (apr_size_t)-1) {
+            r->bytes_sent += e->length;
+            e = APR_BUCKET_NEXT(e);
+            continue;
+        }
+        /* For indeterminate length data buckets, perform one read. */
+        else /* e->length == (apr_size_t)-1 */ {
             apr_size_t len;
             const char *ignored;
-            apr_status_t rv;
-
-            /* This is probably a pipe bucket.  Send everything
-             * prior to this, and then read the data for this bucket.
-             */
+        
             rv = apr_bucket_read(e, &ignored, &len, eblock);
+            if ((rv != APR_SUCCESS) && !APR_STATUS_IS_EAGAIN(rv)) {
+                ap_log_rerror(APLOG_MARK, APLOG_ERR, rv, r, APLOGNO(00574)
+                              "ap_content_length_filter: "
+                              "apr_bucket_read() failed");
+                return rv;
+            }
             if (rv == APR_SUCCESS) {
-                /* Attempt a nonblocking read next time through */
                 eblock = APR_NONBLOCK_READ;
+                e = APR_BUCKET_NEXT(e);
                 r->bytes_sent += len;
             }
             else if (APR_STATUS_IS_EAGAIN(rv)) {
-                /* Output everything prior to this bucket, and then
-                 * do a blocking read on the next batch.
-                 */
-                if (e != APR_BRIGADE_FIRST(b)) {
-                    apr_bucket *flush;
-                    apr_brigade_split_ex(b, e, ctx->tmpbb);
-                    flush = apr_bucket_flush_create(r->connection->bucket_alloc);
-
-                    APR_BRIGADE_INSERT_TAIL(b, flush);
-                    rv = ap_pass_brigade(f->next, b);
-                    if (rv != APR_SUCCESS || f->c->aborted) {
-                        return rv;
-                    }
-                    apr_brigade_cleanup(b);
-                    APR_BRIGADE_CONCAT(b, ctx->tmpbb);
-                    e = APR_BRIGADE_FIRST(b);
+                apr_bucket *flush;
 
-                    ctx->data_sent = 1;
-                }
+                /* Next read must block. */
                 eblock = APR_BLOCK_READ;
-                continue;
-            }
-            else {
-                ap_log_rerror(APLOG_MARK, APLOG_ERR, rv, r, APLOGNO(00574)
-                              "ap_content_length_filter: "
-                              "apr_bucket_read() failed");
-                return rv;
+
+                /* Ensure the last bucket to pass down is a flush if
+                 * the next read will block. */
+                flush = apr_bucket_flush_create(f->c->bucket_alloc);
+                APR_BUCKET_INSERT_BEFORE(e, flush);
             }
         }
-        else {
-            r->bytes_sent += e->length;
+
+        /* Optimization: if the next bucket is EOS (directly after a
+         * bucket morphed to the heap, or a flush), short-cut to
+         * handle EOS straight away - allowing C-L to be determined
+         * for content which is already entirely in memory. */
+        if (e != APR_BRIGADE_SENTINEL(b) && APR_BUCKET_IS_EOS(e)) {
+            continue;
+        }
+
+        /* On reaching here, pass on everything in the brigade up to
+         * this point. */
+        apr_brigade_split_ex(b, e, ctx->tmpbb);
+        
+        rv = ap_pass_brigade(f->next, b);
+        if (rv != APR_SUCCESS) {
+            return rv;
+        }
+        else if (f->c->aborted) {
+            return APR_ECONNABORTED;
         }
-        e = APR_BUCKET_NEXT(e);
+        apr_brigade_cleanup(b);
+        APR_BRIGADE_CONCAT(b, ctx->tmpbb);
+        e = APR_BRIGADE_FIRST(b);
+        
+        ctx->data_sent = 1;
     }
 
     /* If we've now seen the entire response and it's otherwise
diff --git a/server/util.c b/server/util.c
index 830ce5b..8df1a4c 100644
--- a/server/util.c
+++ b/server/util.c
@@ -2663,8 +2663,7 @@ AP_DECLARE(int) ap_parse_form_data(request_rec *r, ap_filter_t *f,
     ap_form_type_t state = FORM_NAME, percent = FORM_NORMAL;
     ap_form_pair_t *pair = NULL;
     apr_array_header_t *pairs = apr_array_make(r->pool, 4, sizeof(ap_form_pair_t));
-
-    char escaped_char[2];
+    char escaped_char[2] = { 0 };
 
     *ptr = pairs;
 
diff --git a/server/util_expr_eval.c b/server/util_expr_eval.c
index b1cb923..91f5c35 100644
--- a/server/util_expr_eval.c
+++ b/server/util_expr_eval.c
@@ -189,8 +189,8 @@ static const char *ap_expr_eval_re_backref(ap_expr_eval_ctx_t *ctx, unsigned int
 {
     int len;
 
-    if (!ctx->re_pmatch || !ctx->re_source || *ctx->re_source == '\0' ||
-        ctx->re_nmatch < n + 1)
+    if (!ctx->re_pmatch || !ctx->re_source || !*ctx->re_source
+        || **ctx->re_source == '\0' || ctx->re_nmatch < n + 1)
         return "";
 
     len = ctx->re_pmatch[n].rm_eo - ctx->re_pmatch[n].rm_so;
@@ -1001,7 +1001,12 @@ static const char *req_table_func(ap_expr_eval_ctx_t *ctx, const void *data,
         t = ctx->r->headers_in;
     else {                          /* req, http */
         t = ctx->r->headers_in;
-        add_vary(ctx, arg);
+        /* Skip the 'Vary: Host' header combination
+         * as indicated in rfc7231 section-7.1.4
+         */
+        if (strcasecmp(arg, "Host")){
+            add_vary(ctx, arg);
+        }
     }
     return apr_table_get(t, arg);
 }
@@ -1467,7 +1472,12 @@ static const char *req_header_var_fn(ap_expr_eval_ctx_t *ctx, const void *data)
         return "";
 
     name = req_header_header_names[index];
-    add_vary(ctx, name);
+    /* Skip the 'Vary: Host' header combination
+     * as indicated in rfc7231 section-7.1.4
+     */
+    if (strcasecmp(name, "Host")){
+        add_vary(ctx, name);
+    }
     return apr_table_get(ctx->r->headers_in, name);
 }
 
diff --git a/support/ab.c b/support/ab.c
index 8429878..ac594c5 100644
--- a/support/ab.c
+++ b/support/ab.c
@@ -197,6 +197,14 @@ typedef STACK_OF(X509) X509_STACK_TYPE;
 #if !defined(OPENSSL_NO_TLSEXT) && defined(SSL_set_tlsext_host_name)
 #define HAVE_TLSEXT
 #endif
+#if defined(LIBRESSL_VERSION_NUMBER) && LIBRESSL_VERSION_NUMBER < 0x2060000f
+#define SSL_CTRL_SET_MIN_PROTO_VERSION 123
+#define SSL_CTRL_SET_MAX_PROTO_VERSION 124
+#define SSL_CTX_set_min_proto_version(ctx, version) \
+   SSL_CTX_ctrl(ctx, SSL_CTRL_SET_MIN_PROTO_VERSION, version, NULL)
+#define SSL_CTX_set_max_proto_version(ctx, version) \
+   SSL_CTX_ctrl(ctx, SSL_CTRL_SET_MAX_PROTO_VERSION, version, NULL)
+#endif
 #endif
 
 #include <math.h>
@@ -1955,14 +1963,14 @@ static void test(void)
 static void copyright(void)
 {
     if (!use_html) {
-        printf("This is ApacheBench, Version %s\n", AP_AB_BASEREVISION " <$Revision: 1796539 $>");
+        printf("This is ApacheBench, Version %s\n", AP_AB_BASEREVISION " <$Revision: 1807734 $>");
         printf("Copyright 1996 Adam Twiss, Zeus Technology Ltd, http://www.zeustech.net/\n");
         printf("Licensed to The Apache Software Foundation, http://www.apache.org/\n");
         printf("\n");
     }
     else {
         printf("<p>\n");
-        printf(" This is ApacheBench, Version %s <i><%s></i><br>\n", AP_AB_BASEREVISION, "$Revision: 1796539 $");
+        printf(" This is ApacheBench, Version %s <i><%s></i><br>\n", AP_AB_BASEREVISION, "$Revision: 1807734 $");
         printf(" Copyright 1996 Adam Twiss, Zeus Technology Ltd, http://www.zeustech.net/<br>\n");
         printf(" Licensed to The Apache Software Foundation, http://www.apache.org/<br>\n");
         printf("</p>\n<p>\n");
diff --git a/support/htdigest.c b/support/htdigest.c
index 018c0ea..43f7054 100644
--- a/support/htdigest.c
+++ b/support/htdigest.c
@@ -59,6 +59,7 @@
 #endif /* APR_CHARSET_EBCDIC */
 
 #define MAX_STRING_LEN 256
+#define MAX_LINE_LEN 768
 
 apr_file_t *tfp = NULL;
 apr_file_t *errfile;
@@ -75,12 +76,16 @@ static void cleanup_tempfile_and_exit(int rc)
     exit(rc);
 }
 
-static void getword(char *word, char *line, char stop)
+static int getword(char *word, char *line, char stop)
 {
     int x = 0, y;
 
-    for (x = 0; ((line[x]) && (line[x] != stop)); x++)
+    for (x = 0; ((line[x]) && (line[x] != stop)); x++) {
+        if (x == (MAX_STRING_LEN - 1)) {
+            return 1;
+        }
         word[x] = line[x];
+    }
 
     word[x] = '\0';
     if (line[x])
@@ -88,6 +93,8 @@ static void getword(char *word, char *line, char stop)
     y = 0;
 
     while ((line[y++] = line[x++]));
+
+    return 0;
 }
 
 static int get_line(char *s, int n, apr_file_t *f)
@@ -127,7 +134,7 @@ static void add_password(const char *user, const char *realm, apr_file_t *f)
     char *pw;
     apr_md5_ctx_t context;
     unsigned char digest[16];
-    char string[3 * MAX_STRING_LEN]; /* this includes room for 2 * ':' + '\0' */
+    char string[MAX_LINE_LEN]; /* this includes room for 2 * ':' + '\0' */
     char pwin[MAX_STRING_LEN];
     char pwv[MAX_STRING_LEN];
     unsigned int i;
@@ -191,8 +198,8 @@ int main(int argc, const char * const argv[])
     char *dirname;
     char user[MAX_STRING_LEN];
     char realm[MAX_STRING_LEN];
-    char line[3 * MAX_STRING_LEN];
-    char l[3 * MAX_STRING_LEN];
+    char line[MAX_LINE_LEN];
+    char l[MAX_LINE_LEN];
     char w[MAX_STRING_LEN];
     char x[MAX_STRING_LEN];
     int found;
@@ -261,8 +268,11 @@ int main(int argc, const char * const argv[])
             continue;
         }
         strcpy(l, line);
-        getword(w, l, ':');
-        getword(x, l, ':');
+        if (getword(w, l, ':') || getword(x, l, ':')) {
+            apr_file_printf(errfile, "The following line contains a string longer than the "
+                                     "allowed maximum size (%i): %s\n", MAX_STRING_LEN - 1, line);
+            cleanup_tempfile_and_exit(1);
+        }
         if (strcmp(user, w) || strcmp(realm, x)) {
             putline(tfp, line);
             continue;

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-apache/apache2.git



More information about the Pkg-apache-commits mailing list