]> git.ipfire.org Git - thirdparty/freeradius-server.git/commitdiff
invalid control characters are errors
authorAlan T. DeKok <aland@freeradius.org>
Mon, 25 May 2026 16:22:52 +0000 (12:22 -0400)
committerAlan T. DeKok <aland@freeradius.org>
Mon, 25 May 2026 16:23:37 +0000 (12:23 -0400)
src/lib/util/skip.c

index e73757fd0d7fae6562481e954242869b2053e42c..bbc208c9634734c435147b40e7e0c40f60fb8ea8 100644 (file)
@@ -428,7 +428,10 @@ ssize_t fr_skip_condition(char const *start, char const *end, bool const termina
                /*
                 *      Any control characters (other than \t) cause an error.
                 */
-               if (*p < ' ') break;
+               if (*p < ' ') {
+                       fr_strerror_const("Invalid escape in condition");
+                       return -(p - start);
+               }
 
                was_regex = false;