You are viewing a plain text version of this content. The canonical link for it is here.
Posted to cvs@httpd.apache.org by rp...@apache.org on 2022/04/27 06:35:02 UTC
svn commit: r1900306 - in /httpd/httpd/trunk: changes-entries/pr66033.txt server/util.c
Author: rpluem
Date: Wed Apr 27 06:35:02 2022
New Revision: 1900306
URL: http://svn.apache.org/viewvc?rev=1900306&view=rev
Log:
* Avoid an overflow on large inputs
PR: 66033
Added:
httpd/httpd/trunk/changes-entries/pr66033.txt (with props)
Modified:
httpd/httpd/trunk/server/util.c
Added: httpd/httpd/trunk/changes-entries/pr66033.txt
URL: http://svn.apache.org/viewvc/httpd/httpd/trunk/changes-entries/pr66033.txt?rev=1900306&view=auto
==============================================================================
--- httpd/httpd/trunk/changes-entries/pr66033.txt (added)
+++ httpd/httpd/trunk/changes-entries/pr66033.txt Wed Apr 27 06:35:02 2022
@@ -0,0 +1,2 @@
+ *) core: Avoid an overflow on large inputs in ap_is_matchexp. PR 66033
+ [Ruediger Pluem]
Propchange: httpd/httpd/trunk/changes-entries/pr66033.txt
------------------------------------------------------------------------------
svn:eol-style = native
Modified: httpd/httpd/trunk/server/util.c
URL: http://svn.apache.org/viewvc/httpd/httpd/trunk/server/util.c?rev=1900306&r1=1900305&r2=1900306&view=diff
==============================================================================
--- httpd/httpd/trunk/server/util.c (original)
+++ httpd/httpd/trunk/server/util.c Wed Apr 27 06:35:02 2022
@@ -251,10 +251,8 @@ AP_DECLARE(int) ap_os_is_path_absolute(a
AP_DECLARE(int) ap_is_matchexp(const char *str)
{
- int x;
-
- for (x = 0; str[x]; x++)
- if ((str[x] == '*') || (str[x] == '?'))
+ for (; *str; str++)
+ if ((*str == '*') || (*str == '?'))
return 1;
return 0;
}