/[Apache-SVN]
ViewVC logotype

Revision 1891206


Jump to revision: Previous Next
Author: ylavic
Date: Fri Jul 2 14:58:46 2021 UTC (2 years, 10 months ago)
Changed paths: 2
Log Message:
mod_proxy: Fix possible reuse/merging of Proxy(Pass)Match workers.  PR 65419.

We can't truncate ProxyMatch's worker name/url to the first '$' substitution
without possibly colliding with other workers. This also makes the matching
done at runtime by ap_proxy_strcmp_ematch() completely pointless.

To fix this and still address r1878467 (i.e. make http://host:port$1 a "valid"
URL), we need to remove '$' substitutions from the :port part of the URL only
since it's allowed anywhere else by apr_uri_parse().

So let's strip them before apr_uri_parse() and prepend them back in the path
before apr_uri_unparse() to restore the original URL. Non-matchable workers are
not concerned so ap_proxy_define_worker() is made a local helper (w/o the ap_
prefix) which takes "matchable" as argument and can then be called by both
ap_proxy_define_[match_]worker() functions.


Changed paths

Path Details
Directoryhttpd/httpd/trunk/changes-entries/proxy_define_matchable_worker.txt added
Directoryhttpd/httpd/trunk/modules/proxy/proxy_util.c modified , text changed

infrastructure at apache.org
ViewVC Help
Powered by ViewVC 1.1.26