aboutsummaryrefslogtreecommitdiffstats
path: root/config/arpwatch.xml
diff options
context:
space:
mode:
authorjim-p <jimp@pfsense.org>2013-10-01 17:01:07 -0400
committerjim-p <jimp@pfsense.org>2013-10-01 17:01:07 -0400
commitee3039e1f65a745c857c1c5bb9a4f93d419b29f8 (patch)
tree3f509059cac80dde70501304b991f7f2be068879 /config/arpwatch.xml
parentbc62d8f94ff492595dfad5e6152998fe12153645 (diff)
downloadpfsense-packages-ee3039e1f65a745c857c1c5bb9a4f93d419b29f8.tar.gz
pfsense-packages-ee3039e1f65a745c857c1c5bb9a4f93d419b29f8.tar.bz2
pfsense-packages-ee3039e1f65a745c857c1c5bb9a4f93d419b29f8.zip
Refinements/fixes for arpwatch e-mail
Diffstat (limited to 'config/arpwatch.xml')
-rw-r--r--config/arpwatch.xml7
1 files changed, 5 insertions, 2 deletions
diff --git a/config/arpwatch.xml b/config/arpwatch.xml
index 18c75029..64aadcea 100644
--- a/config/arpwatch.xml
+++ b/config/arpwatch.xml
@@ -93,7 +93,7 @@
<fielddescr>Enable E-mail Notifications</fielddescr>
<fieldname>enable_email</fieldname>
<type>checkbox</type>
- <description>Sends an E-mail notification for each new station and ARP change as they are seen.&lt;br/&gt;NOTE: Only works on pfSense 2.1 or later.&lt;br/&gt;Configure SMTP and address settings in System &gt; Advanced on the Notifications tab</description>
+ <description>Sends an E-mail notification for each new station and ARP change as they are seen &lt;strong&gt;instead of&lt;/strong&gt; local reports.&lt;br/&gt;NOTE: Only works on pfSense 2.1 or later. &lt;br/&gt;NOTE 2: Disables local reports which rely on arpwatch debug mode, which does not work with e-mail notifications.&lt;br/&gt;Configure SMTP and address settings in System &gt; Advanced on the Notifications tab</description>
</field>
</fields>
<custom_php_global_functions>
@@ -110,13 +110,16 @@
$int = $config['installedpackages']['arpwatch']['config'][0]['interface'];
}
$mail = "";
+ $debug = "";
if(($pf_version > 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']}";
+ } else {
+ $debug = "-d";
}
$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} {$mail} > /var/log/arpwatch.reports 2>&amp;1 &amp;";
+ $start .= "/usr/local/sbin/arpwatch {$debug} -f {$log_file} {$mail} -i {$int} > /var/log/arpwatch.reports 2>&amp;1 &amp;";
$stop = "/usr/bin/killall arpwatch";
write_rcfile(array(
"file" => "arpwatch.sh",