From 63209b621929d77f669af22b2f721320e62184cf Mon Sep 17 00:00:00 2001 From: jim-p Date: Tue, 8 Oct 2013 15:46:57 -0400 Subject: Add small softflowd package --- config/softflowd/softflowd.xml | 136 +++++++++++++++++++++++++++++++++++++++++ 1 file changed, 136 insertions(+) create mode 100644 config/softflowd/softflowd.xml (limited to 'config/softflowd') diff --git a/config/softflowd/softflowd.xml b/config/softflowd/softflowd.xml new file mode 100644 index 00000000..1b45f8bb --- /dev/null +++ b/config/softflowd/softflowd.xml @@ -0,0 +1,136 @@ + + softflowd + 0.9.8 + softflowd: Settings + pkg_edit.php?xml=softflowd.xml&id=0 + + softflowd + Modify softflowd settings. +
Services
+ softflowd.xml + /pkg_edit.php?xml=softflowd.xml&id=0 +
+ + softflowd + softflowd.sh + softflowd + + installedpackages->package->$packagename->configuration->settings + + + Interface + interface + interfaces_selection + Pick an interface from which to collect netflow data. A separate instance of softflowd will be launched for each interface. + + + + Host + host + Specify the host to which datagrams will be sent. + input + + + Port + port + Enter the port to which datagrams will be sent. + input + + + Max Flows + maxflows + Specify the maximum number of flows to concurrently track before older flows are expired. Default: 8192. + input + + + Netflow version + version + Select the desired version of the NetFlow protocol. + select + + + + + + + + + "softflowd.sh", + "start" => $start, + "stop" => "/usr/bin/killall -9 softflowd" + ) + ); + restart_service("softflowd"); + } + conf_mount_ro(); + config_unlock(); + } + + function validate_form_softflowd($post, $input_errors) { + if (($post['host'] == "") || !is_ipaddr($post['host'])) + $input_errors[] = 'You must specify a valid ip address in the \'Host\' field'; + if (($post['port'] == "") || !is_port($post['port'])) + $input_errors[] = 'You must specify a valid port number in the \'Port\' field'; + } + + function cleanup_config_softflowd() { + global $a_pkg; + $pffconf = array(); + if (is_array($a_pkg)) { + foreach($a_pkg as $cf) { + if ($cf['host'] != "") { + $pffconf = $cf; + } + } + } + $a_pkg = array(); + $a_pkg[0] = $pffconf; + } + ]]> + + + sync_package_softflowd(); + + + validate_form_softflowd($_POST, &$input_errors); + + + cleanup_config_softflowd(); + +
-- cgit v1.2.3