From ca6a4b3fb5510b17698deab24ac1059b79f3327b Mon Sep 17 00:00:00 2001 From: robiscool Date: Thu, 1 Oct 2009 12:28:11 -0700 Subject: snort-stable, add misc --- config/snort/snort.inc | 73 +++++++++++++++++++++++++++++++++++------ config/snort/snort_advanced.xml | 32 +++++++++++++----- 2 files changed, 87 insertions(+), 18 deletions(-) diff --git a/config/snort/snort.inc b/config/snort/snort.inc index ebcab85c..107dfb3e 100755 --- a/config/snort/snort.inc +++ b/config/snort/snort.inc @@ -196,7 +196,6 @@ function create_barnyard2_conf() { global $bconfig, $bg; /* write out barnyard2_conf */ $barnyard2_conf_text = generate_barnyard2_conf(); -// conf_mount_rw(); $bconf = fopen("/usr/local/etc/barnyard2.conf", "w"); if(!$bconf) { log_error("Could not open /usr/local/etc/barnyard2.conf for writing."); @@ -204,7 +203,6 @@ function create_barnyard2_conf() { } fwrite($bconf, $barnyard2_conf_text); fclose($bconf); -// conf_mount_ro(); } /* open barnyard2.conf for writing" */ function generate_barnyard2_conf() { @@ -213,28 +211,56 @@ function generate_barnyard2_conf() { conf_mount_rw(); /* define snortbarnyardlog */ +/* TODO add support for the other 5 output plugins */ + $snortbarnyardlog_database_info_chk = $config['installedpackages']['snortadvanced']['config'][0]['snortbarnyardlog_database']; +$snortbarnyardlog_hostname_info_chk = $config['installedpackages']['snortadvanced']['config'][0]['snortbarnyardlog_hostname']; +$snortbarnyardlog_interface_info_chk = $config['installedpackages']['snortadvanced']['config'][0]['snortbarnyardlog_interface']; $barnyard2_conf_text = <<Snort will log packets to a tcpdump-formatted file. The file then can be analyzed by a wireshark type of application. WARNING: File may become large. checkbox - - Enable Barnyard2. - snortbarnyardlog - This will enable barnyard2 in the snort package. You will also have to set the database credentials. - checkbox - + + Enable Barnyard2. + snortbarnyardlog + This will enable barnyard2 in the snort package. You will also have to set the database credentials. + checkbox + Barnyard2 Log Mysql Database. snortbarnyardlog_database @@ -168,9 +168,25 @@ - Log Alerts to a snort unified file. + Barnyard2 Configure Hostname ID. + snortbarnyardlog_hostname + Example: pfsense.local + input + 25 + + + + Barnyard2 Configure Interface ID + snortbarnyardlog_interface + Example: vr0 + input + 25 + + + + Log Alerts to a snort unified2 file. snortunifiedlog - Snort will log Alerts to a file in the UNIFIED2 format. This is a requirement barnyard2. + Snort will log Alerts to a file in the UNIFIED2 format. This is a requirement for barnyard2. checkbox -- cgit v1.2.3