[Bro] broccoli and enum

Sandro Reichert sanreich at gmx.de
Tue Jul 31 17:39:21 PDT 2007


hi all,

i'm playing around with broccoli and i have problems with events that 
contain enum type. the event is defined in a policy and i can use it for 
inter-bro-comunication, but broccoli ignores it. calling the event 
without the enum type argument works well.
where is my mistake?

thanks!!
sandro


example:
c code (modified 'broping'):

bro_mytest(BroConn *conn, void *data, uint32 *num, BroRecord *status)
{
  /*just print a simple message....*/
  printf("event mytest received!\n");
}

bro_event_registry_add(bc, "mytest", (BroEventFunc) bro_mytest, NULL) ;


policy code:

type testtype : enum
{
   first_type,
   second_type,
};

# 1) does'nt work with broccoli!
event mytest(123, first_type);

# 2) this works!
event mytest(123);







More information about the Bro mailing list