[Bro] redef script variable from bro command line
robin at icir.org
Tue Mar 22 10:26:13 PDT 2016
On Tue, Mar 22, 2016 at 16:57 +0100, Frank Meier wrote:
> # bro -r 2009-m57.00.pcap -e "redef Log::default_rotation_interval = 20min"
> # bro test.bro -r 2009-m57.00.pcap rotation=20min
Well, you're setting different things. If I change the 2nd case to
bro test.bro "Log::default_rotation_interval=20min"
... then it works as well.
In your version, when you set "rotation" it changes that global value,
but at a time when it's old value has already been assigned to
Log::default_rotation_interval. The change will not carry over, as the
assignment doesn't take place again.
Robin Sommer * ICSI/LBNL * robin at icir.org * www.icir.org/robin
More information about the Bro