Re: problem with RecvIDMEF (C++ binding)

Jens De Wit <[email protected]> Wed, 18 May 2011 11:33:43 +0200
Newsgroups gmane.comp.security.ids.prelude.user
Message-ID <[email protected]>
Thanks for the reply.

I've taken a look at your code but I can't seem find the keep-alive
mechanism you mentioned. I did however find in Client.cpp both your
initialization code and the method where you actually try to receive the
IDMEF message and I must say my own code is very similar, so at least I'm
pretty sure that isn't the problem.

I forgot to mention though that I'm also getting the following error on
start-up every time: "ERROR: error creating asynchronous thread: Function
not implemented. (prelude-async.c:243 do_init_async)". It doesn't affect my
ability to send IDMEF messages so I assumed it also wouldn't be the cause of
my problem with receiving IDMEF messages, but I might as well mention it
because I'm not sure of anything at the moment.

Regards,
Jens

2011/5/17 Bartek 'BaSz' Szurgot <[email protected]>

> On 05/16/2011 11:11 AM, Jens De Wit wrote:
>
>> Hello everyone,
>>
>> I'm trying to write a simple sensor that reads and processes IDMEF using
>> the
>> C++ easy bindings.
>> The problem is I'm experiencing strange behaviour when calling the
>> RecvIDMEF
>> method: after a few calls I get the following warning "WARNING: Failover
>> enabled: connection error with 127.0.0.1:4690: End of file", after which
>> the
>> sensor doens't receive anything anymore. When I restart the sensor the
>> same
>> happens; it reads a few messages then the warning pops up and it stops
>> working again.
>> Am I doing something stupid or missing something obvious here? I went
>> through the code of the official sensors but I couldn't find any examples
>> of
>> using the RecvIDMEF call, except for the correlator but that's written
>> using
>> the Python bindings.
>>
>> Any help would be greatly appreciated.
>>
>> Regards,
>> Jens
>>
>
>
> hi,
>
> we had similar problem with our implementation (though we used C binding).
> i was not the one who worked with it directly, but AFAIR it was some
> non-obvious trick related to enabling a sort of a keep-alive mechanism in
> libprelude, to prevent connection closing every few seconds.
>
> you can take a look at our C++ implementation of libprelude data handling
> in ACARM-ng system (http://www.acarm.wcss.wroc.pl). the part you're
> interested in is Input::Prelude namespace, namely:
> http://repo.acarm.wcss.wroc.pl/main/src/inputprelude/Input/Prelude/
>
> hope that will help!
>
> --
> pozdrawiam serdecznie / best regards,
> Bartek 'BaSz' Szurgot
>
> Wroclaw Centre for Networking and Supercomputing
> Wroclaw University of Technology,
> PWr, C-3 / 131A
> tel. +48 71 320 2013
> http://www.wcss.wroc.pl
>
>
> _______________________________________________
> Prelude-user site list
> [email protected]
> http://lists.prelude-technologies.com/mailman/listinfo/prelude-user
>
_______________________________________________
Prelude-user site list
[email protected]
http://lists.prelude-technologies.com/mailman/listinfo/prelude-user