From e9a1dee7011badfeb464c5b10d7721b42389858e Mon Sep 17 00:00:00 2001 From: jim-p Date: Tue, 1 Oct 2013 16:36:05 -0400 Subject: Add e-mail capability to the arpwatch package. Only works on 2.1+ --- config/arpwatch.xml | 26 ++++++++++++++++++++++---- 1 file changed, 22 insertions(+), 4 deletions(-) (limited to 'config/arpwatch.xml') diff --git a/config/arpwatch.xml b/config/arpwatch.xml index e8faa3b0..18c75029 100644 --- a/config/arpwatch.xml +++ b/config/arpwatch.xml @@ -41,11 +41,11 @@ /* ========================================================================== */ ]]> - Describe your package here - Describe your package requirements here + ARP Monitoring Daemon + None Currently there are no FAQ items provided. arpwatch - 2.1.a13 + 2.1.a14 pkg v1.1 arpwatch: Settings pkg_edit.php?xml=arpwatch.xml&id=0 @@ -77,6 +77,11 @@ a+rx http://www.pfsense.com/packages/config/arpwatch_reports.php + + /usr/sbin/ + a+rx + http://www.pfsense.com/packages/config/sm.php + Listening Interface @@ -84,11 +89,18 @@ Choose the desired listening interface here. interfaces_selection + + Enable E-mail Notifications + enable_email + checkbox + Sends an E-mail notification for each new station and ARP change as they are seen.<br/>NOTE: Only works on pfSense 2.1 or later.<br/>Configure SMTP and address settings in System > Advanced on the Notifications tab + 2.0) && (isset($_POST['enable_email']) || ($config['installedpackages']['arpwatch']['config'][0]['enable_email'] == "on"))) { + if (!empty($config['notifications']['smtp']['notifyemailaddress'])) + $mail = " -m {$config['notifications']['smtp']['notifyemailaddress']}"; + } $int = convert_friendly_interface_to_real_interface_name($int); $start = "touch {$log_file}\n"; - $start .= "/usr/local/sbin/arpwatch -d -f {$log_file} -i {$int} > /var/log/arpwatch.reports 2>&1 &"; + $start .= "/usr/local/sbin/arpwatch -d -f {$log_file} -i {$int} {$mail} > /var/log/arpwatch.reports 2>&1 &"; $stop = "/usr/bin/killall arpwatch"; write_rcfile(array( "file" => "arpwatch.sh", @@ -121,6 +138,7 @@ -- cgit v1.2.3