base/frameworks/input/readers/config.bro

InputConfig

Interface for the config input reader.

Namespace:InputConfig
Source File:/scripts/base/frameworks/input/readers/config.bro

Summary

Redefinable Options

InputConfig::empty_field: string &redef String to use for empty fields.
InputConfig::fail_on_file_problem: bool &redef Fail on file read problems.
InputConfig::set_separator: string &redef Separator between set and vector elements.

Events

InputConfig::new_value: event Event that is called when a config option is added or changes.

Detailed Interface

Redefinable Options

InputConfig::empty_field
Type:string
Attributes:&redef
Default:""

String to use for empty fields. By default this is the empty string, meaning that an empty input field will result in an empty set.

InputConfig::fail_on_file_problem
Type:bool
Attributes:&redef
Default:F

Fail on file read problems. If set to true, the config input reader will fail when encountering any problems while reading a file different from invalid lines. Examples of such problems are permission problems, or missing files. When set to false, these problems will be ignored. This has an especially big effect for the REREAD mode, which will seamlessly recover from read errors when a file is only temporarily inaccessible. For MANUAL or STREAM files, errors will most likely still be fatal since no automatic re-reading of the file is attempted. Individual readers can use a different value using the $config table.

InputConfig::set_separator
Type:string
Attributes:&redef
Default:","

Separator between set and vector elements. Please note that the separator has to be exactly one character long.

Events

InputConfig::new_value
Type:event (name: string, source: string, id: string, value: any)

Event that is called when a config option is added or changes.

Note - this does not track the reason for a change (new, changed), and also does not track removals. If you need this, combine the event with a table reader.

Name:Name of the input stream.
Source:Source of the input stream.
Id:ID of the configuration option being set.
Value:New value of the configuration option being set.
Copyright 2016, The Bro Project. Last updated on January 10, 2019. Created using Sphinx 1.7.5.