You are viewing a plain text version of this content. The canonical link for it is here.
Posted to cvs@httpd.apache.org by yl...@apache.org on 2018/05/02 11:32:22 UTC
svn commit: r1830746 - in /httpd/httpd/trunk: CHANGES
modules/filters/mod_proxy_html.c
Author: ylavic
Date: Wed May 2 11:32:22 2018
New Revision: 1830746
URL: http://svn.apache.org/viewvc?rev=1830746&view=rev
Log:
mod_proxy_html: Fix variable interpolation and memory allocation failure in ProxyHTMLURLMap.
Proposed by: Ewald Dieterich <ewald mailbox.org>
Reviewed by: ylavic
Modified:
httpd/httpd/trunk/CHANGES
httpd/httpd/trunk/modules/filters/mod_proxy_html.c
Modified: httpd/httpd/trunk/CHANGES
URL: http://svn.apache.org/viewvc/httpd/httpd/trunk/CHANGES?rev=1830746&r1=1830745&r2=1830746&view=diff
==============================================================================
--- httpd/httpd/trunk/CHANGES [utf-8] (original)
+++ httpd/httpd/trunk/CHANGES [utf-8] Wed May 2 11:32:22 2018
@@ -1,6 +1,9 @@
-*- coding: utf-8 -*-
Changes with Apache 2.5.1
+ *) mod_proxy_html: Fix variable interpolation and memory allocation failure
+ in ProxyHTMLURLMap. [Ewald Dieterich <ewald mailbox.org>]
+
*) core: In ONE_PROCESS/debug mode, cleanup everything when exiting.
[Yann Ylavic]
Modified: httpd/httpd/trunk/modules/filters/mod_proxy_html.c
URL: http://svn.apache.org/viewvc/httpd/httpd/trunk/modules/filters/mod_proxy_html.c?rev=1830746&r1=1830745&r2=1830746&view=diff
==============================================================================
--- httpd/httpd/trunk/modules/filters/mod_proxy_html.c (original)
+++ httpd/httpd/trunk/modules/filters/mod_proxy_html.c Wed May 2 11:32:22 2018
@@ -752,6 +752,12 @@ static const char *interpolate_vars(requ
break;
delim = ap_strchr_c(start, '|');
+
+ /* Restrict delim to ${...} */
+ if (delim && delim >= end) {
+ delim = NULL;
+ }
+
before = apr_pstrndup(r->pool, str, start-str);
after = end+1;
if (delim) {