base/frameworks/netcontrol/plugins/broker.zeek

NetControl

Broker plugin for the NetControl framework. Sends the raw data structures used in NetControl on to Broker to allow for easy handling, e.g., of command-line scripts.

Namespace

NetControl

Imports

base/frameworks/broker, base/frameworks/netcontrol/main.zeek, base/frameworks/netcontrol/plugin.zeek

Summary

Types

NetControl::BrokerConfig: record

This record specifies the configuration that is passed to NetControl::create_broker.

Redefinitions

NetControl::PluginState: record

New Fields

NetControl::PluginState

broker_config: NetControl::BrokerConfig &optional

OpenFlow controller for NetControl Broker plugin.

broker_id: count &optional

The ID of this broker instance - for the mapping to PluginStates.

Functions

NetControl::create_broker: function

Instantiates the broker plugin.

Detailed Interface

Types

NetControl::BrokerConfig
Type

record

topic: string &optional

The broker topic to send events to.

host: addr &optional

Broker host to connect to.

bport: port &optional

Broker port to connect to.

monitor: bool &default = T &optional

Do we accept rules for the monitor path? Default true.

forward: bool &default = T &optional

Do we accept rules for the forward path? Default true.

check_pred: function (p: NetControl::PluginState, r: NetControl::Rule)bool &optional

Predicate that is called on rule insertion or removal.

p

Current plugin state.

r

The rule to be inserted or removed.

returns

T if the rule can be handled by the current backend, F otherwise.

This record specifies the configuration that is passed to NetControl::create_broker.

Functions

NetControl::create_broker
Type

function (config: NetControl::BrokerConfig, can_expire: bool) : NetControl::PluginState

Instantiates the broker plugin.