From 05390e7bd7be3c22a6c51deb8fc087c5727b2c3b Mon Sep 17 00:00:00 2001 From: Ramon Novoa Date: Fri, 5 Dec 2014 11:07:07 +0100 Subject: [PATCH] Added support for fping. --- pandora_server/FreeBSD/pandora_server.conf.new | 3 +++ pandora_server/NetBSD/pandora_server.conf.new | 3 +++ pandora_server/conf/pandora_server.conf.new | 3 +++ pandora_server/conf/pandora_server.conf.windows | 3 +++ pandora_server/lib/PandoraFMS/Config.pm | 5 +++++ 5 files changed, 17 insertions(+) diff --git a/pandora_server/FreeBSD/pandora_server.conf.new b/pandora_server/FreeBSD/pandora_server.conf.new index c5c15b4b4c..1eb334bff2 100644 --- a/pandora_server/FreeBSD/pandora_server.conf.new +++ b/pandora_server/FreeBSD/pandora_server.conf.new @@ -247,6 +247,9 @@ xprobe2 /usr/local/bin/xprobe2 nmap /usr/local/bin/nmap +# Path to the fping binary. Used by the Enterprise ICMP Server. +fping /usr/bin/fping + # A value that specifies how aggressive nmap should be from 1 to 5. 1 means slower but more reliable, 5 means faster but less reliable. 2 by default. nmap_timing_template 2 diff --git a/pandora_server/NetBSD/pandora_server.conf.new b/pandora_server/NetBSD/pandora_server.conf.new index 4d4834b1b0..83488a0d33 100644 --- a/pandora_server/NetBSD/pandora_server.conf.new +++ b/pandora_server/NetBSD/pandora_server.conf.new @@ -248,6 +248,9 @@ xprobe2 /usr/local/bin/xprobe2 nmap /usr/pkg/bin/nmap +# Path to the fping binary. Used by the Enterprise ICMP Server. +fping /usr/bin/fping + # A value that specifies how aggressive nmap should be from 1 to 5. 1 means slower but more reliable, 5 means faster but less reliable. 2 by default. nmap_timing_template 2 diff --git a/pandora_server/conf/pandora_server.conf.new b/pandora_server/conf/pandora_server.conf.new index 3d5a3e3056..9673646fcd 100644 --- a/pandora_server/conf/pandora_server.conf.new +++ b/pandora_server/conf/pandora_server.conf.new @@ -248,6 +248,9 @@ xprobe2 /usr/bin/xprobe2 nmap /usr/bin/nmap +# Path to the fping binary. Used by the Enterprise ICMP Server. +fping /usr/bin/fping + # A value that specifies how aggressive nmap should be from 1 to 5. 1 means slower but more reliable, 5 means faster but less reliable. 2 by default. nmap_timing_template 2 diff --git a/pandora_server/conf/pandora_server.conf.windows b/pandora_server/conf/pandora_server.conf.windows index 5009a6060f..2c1023ab8c 100644 --- a/pandora_server/conf/pandora_server.conf.windows +++ b/pandora_server/conf/pandora_server.conf.windows @@ -209,6 +209,9 @@ dataserver_threads 2 #nmap c:\pandora_server\bin\nmap.exe +# Path to the fping binary. Used by the Enterprise ICMP Server. +#fping c:\pandora_server\bin\Fping.exe + # snmpget: Needed to do SNMP checks. #snmpget c:\pandora_server\bin\snmpget.exe diff --git a/pandora_server/lib/PandoraFMS/Config.pm b/pandora_server/lib/PandoraFMS/Config.pm index 99535d1270..0271311d46 100644 --- a/pandora_server/lib/PandoraFMS/Config.pm +++ b/pandora_server/lib/PandoraFMS/Config.pm @@ -267,6 +267,8 @@ sub pandora_load_config { $pa_config->{"nmap_timing_template"} = 2; # > 5.1 $pa_config->{"recon_timing_template"} = 3; # > 5.1 + $pa_config->{"fping"} = "/usr/bin/fping"; # > 5.1SP2 + # braa for enterprise snmp server $pa_config->{"braa"} = "/usr/bin/braa"; @@ -618,6 +620,9 @@ sub pandora_load_config { elsif ($parametro =~ m/^nmap\s(.*)/i) { $pa_config->{'nmap'}= clean_blank($1); } + elsif ($parametro =~ m/^fping\s(.*)/i) { + $pa_config->{'fping'}= clean_blank($1); + } elsif ($parametro =~ m/^nmap_timing_template\s([0-9]*)/i) { $pa_config->{'nmap_timing_template'}= clean_blank($1); }