[Snort-devel] perfmonitor fmt string bug

Christo Butcher christo at ...1546...
Sun Aug 18 15:06:06 EDT 2002


Hello,

The perfmonitor preprocessor code in snort-1.9.0beta5 contains
a format string bug in a FatalError call during argument
parsing. This bug causes a segfault when an undefined argument
is passed to the preprocessor. Looks a lot like somebody's cat
jumped on the keyboard right before a commit.  :)

A patch follows.

Christo

--- snort-1.9.0beta5/src/preprocessors/spp_perfmonitor.c.orig	Thu Aug 15
16:34:59 2002
+++ snort-1.9.0beta5/src/preprocessors/spp_perfmonitor.c	Thu Aug 15
16:35:58 2002
@@ -204,8 +204,8 @@
         }
         else
         {
-            FatalError("y%s(%d)=> Invalid parameter '%s' to preprocessor"
-                       " PerfMonitor.\n", Tokens[i], file_name, file_line);
+            FatalError("%s(%d)=> Invalid parameter '%s' to preprocessor"
+                       " PerfMonitor.\n", file_name, file_line, Tokens[i]);
         }
     }

--
Christo Butcher
Fox-IT - Experts in IT Security
http://www.fox-it.com
christo at ...1546...





More information about the Snort-devel mailing list