Posted on 2009-09-01 06:54:13-07 by sjaak
Parse multiple files?
I've been able to use the Net::LibNIDS module successfully with libnids-1.23. However, when I want to parse multiple capture files the module will only parse the first file. For subsequent files init() returns OK, but when calling run() the callback function is never called. Code snippet:

use Net::LibNIDS; Net::LibNIDS::param::set_filename('file.cap'); Net::LibNIDS::init(); # returns 1 Net::LibNIDS::tcp_callback(\&collector ); Net::LibNIDS::run(); # runs OK Net::LibNIDS::param::set_filename('file.cap'); Net::LibNIDS::init(); # returns 1 Net::LibNIDS::tcp_callback(\&collector ); Net::LibNIDS::run(); # collector is never called here

Doing the same in C works OK, so it's not a problem in libnids. I can't see anything obvious being wrong in the module source. Any ideas or help on this?
Direct Responses: 11701 | Write a response
Perl Weekly newsletter
A free weekly newsletter for people who are busy to read all the blogs. click here to check it out.