[Snort-devel] [ snort-Bugs-1078081 ] Integer parsing in xatou(), sfthreshold.c

SourceForge.net noreply at ...12...
Fri Dec 3 08:32:08 EST 2004


Bugs item #1078081, was opened at 2004-12-03 02:11
Message generated for change (Tracker Item Submitted) made by Item Submitter
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=103357&aid=1078081&group_id=3357

Category: None
Group: None
Status: Open
Resolution: None
Priority: 5
Submitted By: NN Poster (nnposter)
Assigned to: Nobody/Anonymous (nobody)
Summary: Integer parsing in xatou(), sfthreshold.c

Initial Comment:
Routine xatou() in sfthreshold.c does not seem to handle 
a case where the input integer string is completely 
unparseable, i.e. the first non-white-space character is 
not a digit. In this case errno does not necessarily have 
to be set, which throws off the parsing error test in the 
routine. (One example is Visual C++ 6.0)


Example:

config threshold: memcap zzz
...will cause snort to believe that memcap is 0 and then 
crash later on DIV 0 error when processing thresholding 
rules.


The attached patch against 2.2 should resolve the issue.


----------------------------------------------------------------------

You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=103357&aid=1078081&group_id=3357




More information about the Snort-devel mailing list