]> git.ipfire.org Git - thirdparty/apache/httpd.git/commit
mod_proxy: Fix potential tunneling infinite loop and spurious timeout.
authorYann Ylavic <ylavic@apache.org>
Mon, 30 Aug 2021 18:04:20 +0000 (18:04 +0000)
committerYann Ylavic <ylavic@apache.org>
Mon, 30 Aug 2021 18:04:20 +0000 (18:04 +0000)
commite8228ba4e6f22f2445fdce4f916c622ea41b025b
treef632fa6e1592fc533fa6c6974685c3db3f0be17e
parentc1619c68432edb1a722b037245344045c339de55
mod_proxy: Fix potential tunneling infinite loop and spurious timeout.
           PRs 65521 and 65519.

* modules/proxy/proxy_util.c(ap_proxy_tunnel_run):
  Avoid an infinite loop by shutting down the connection for write when poll()
  returns POLLHUP and read is already down.  PR 65521.

* modules/proxy/proxy_util.c(ap_proxy_tunnel_run):
  When write completion is finished don't check for ap_filter_input_pending()
  before proxy_tunnel_forward() to flush input data, this is a nonblocking read
  already which will do the same thing implicitely. ap_filter_input_pending()
  is broken in 2.4.x without the whole pending data mechanism (not backported
  yet), so let's align here.  PR 65519.

git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1892740 13f79535-47bb-0310-9956-ffa450edef68
changes-entries/ap_proxy_tunnel_run.txt [new file with mode: 0644]
modules/proxy/proxy_util.c