]> git.ipfire.org Git - thirdparty/apache/httpd.git/commitdiff
ap_timeout_parameter_parse: axe unsigned < 0 check
authorEric Covener <covener@apache.org>
Sat, 7 Aug 2021 10:43:06 +0000 (10:43 +0000)
committerEric Covener <covener@apache.org>
Sat, 7 Aug 2021 10:43:06 +0000 (10:43 +0000)
add check to see if the result was smaller than what we started with.
But the operative part is avoiding the UBI

git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1892063 13f79535-47bb-0310-9956-ffa450edef68

server/util.c

index 6f9dbd4d6573123f6107476b3d5e46f39fd73f34..4a35eac6b0c60f88480bfabfce2e11926fb645a7 100644 (file)
@@ -2724,7 +2724,7 @@ AP_DECLARE(apr_status_t) ap_timeout_parameter_parse(
     default:
         return APR_EGENERAL;
     }
-    if (check > APR_INT64_MAX || check < 0) { 
+    if (check > APR_INT64_MAX || check < tout) { 
         return APR_ERANGE;
     }
     *timeout = (apr_interval_time_t) check;