From d9ad4977fa523a3689108fc47a4fbf4f55d055aa Mon Sep 17 00:00:00 2001 From: alejandro Date: Wed, 1 Jun 2022 13:01:40 +0200 Subject: [PATCH 01/10] make open cisco ipsla plugin compatible with snmp v3 --- pandora_plugins/cisco_ipsla/pandora_ipsla.sh | 685 +++++++++++++++++++ 1 file changed, 685 insertions(+) create mode 100644 pandora_plugins/cisco_ipsla/pandora_ipsla.sh diff --git a/pandora_plugins/cisco_ipsla/pandora_ipsla.sh b/pandora_plugins/cisco_ipsla/pandora_ipsla.sh new file mode 100644 index 0000000000..976548f40b --- /dev/null +++ b/pandora_plugins/cisco_ipsla/pandora_ipsla.sh @@ -0,0 +1,685 @@ +#!/bin/bash +# IPSLA remote Plugin for Pandora FMS +# (c) ArticaST 2014 + + +# Default values +COMMUNITY="public" +TAG_TABLE_CACHE="/tmp/ipsla_cache" + +function help { + echo -e "Cisco IP SLA Server Plugin for Pandora FMS. http://pandorafms.com" + echo -e "Syntax:\n\n-c -t -v [other options]\n" + echo -e "\t\t-c community" + echo -e "\t\t-t target" + echo -e "\t\t-v version" + echo -e "Other options\n"; + echo -e "\t\t-s show defined tags and indexes" + echo -e "\t\t-l " + echo -e "\t\t-u " + echo -e "\t\t-a " + echo -e "\t\t-A " + echo -e "\t\t-x " + echo -e "\t\t-X " + echo -e "\t\t-g " + echo -e "\t\t-m \n" + echo -e "Modules can be: \n" + echo -e "\tICPIF - Calculated Planning Impairment Factor for specified tag" + echo -e "\tMOS - Mean Opinion Score" + echo -e "\tPacket_Out_of_Sequence - Packets arriving out of sequence " + echo -e "\tPacket_Late_Arrival - Packets arriving late" + echo -e "\tvAerage_Jitter - Average jitter is the estimated average jitter observed in the last XX RTP packets" + echo -e "\tPacketLossSD - Packet loss from source to destination" + echo -e "\tPacketLossDS - Packet loss from destination to source" + echo -e "\tPacketLost - The number of packets that are lost for which we cannot determine the direction " + echo -e "\tNegativesSD - The sum of number of all negative jitter values from packets sent from source to destination " + echo -e "\tNegativesDS - The sum of number of all negative jitter values from packets sent from destination to source" + echo -e "\tPositivesSD - The sum of number of all positive jitter values from packets sent from source to destination" + echo -e "\tPositivesDS - The sum of number of all positive jitter values from packets sent from source to destination" + echo -e "\tRTTMax - Max Round Trip Time" + echo -e "\tRTTMin - Min Round Trip Time" + echo -e "\tOperNumOfRTT - The number of successful round trips" + echo -e "\tOperPacketLossSD - Packet loss from source to destination for jitter tests" + echo -e "\tOperPacketLossDS - Packet loss from destination to source for jitter tests" + echo -e "\tRttOperSense - A sense code for the completion status of the latest RTT operation." + echo -e "\tRttOperCompletionTime - The completion time of the latest RTT operation successfully completed." + echo -e "\tRttOperTime - The value of the agent system time at the time of the latest RTT operation." + echo -e "\tRttOperAddress - A string which specifies the address of the target." + echo -e "\tHTTPOperRTT - Round Trip Time taken to perform HTTP operation. This value is the sum of DNSRTT, TCPConnectRTT and TransactionRTT." + echo -e "\tHTTPOperDNSRTT Round Trip Time taken to perform DNS query within the HTTP operation." + echo -e "\tHTTPOperTCPConnectRTT - Round Trip Time taken to connect to the HTTP server." + echo -e "\tIcmpJitterAvgJitter The average of positive and negative jitter values in Source-to-Destionation and Destination-to-Source direction." + echo -e "\tHTTPOperTransactionRTT - Round Trip Time taken to download the object specified by the URL." + + echo "" + exit +} + +function show_tags { + TAG_TABLE_CACHE=$TAG_TABLE_CACHE.$TARGET + + # If not exist the cache, then create it + if [ ! -f "$TAG_TABLE_CACHE" ] + then + snmpwalk -v 1 -Onq -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.2.1.1.3 > $TAG_TABLE_CACHE + fi + cat $TAG_TABLE_CACHE | awk '{ print $2 }' | tr -d "\"" | grep -ve '^$' + exit +} + +function get_index { + cat $TAG_TABLE_CACHE.$TARGET | grep $1 | grep -o "[0-9]*\s" +} + +# This function requires two arguments. MODULE_TYPE TAG +function get_module { + MODULE_TYPE=$1 + TAG=$2 + INDICE=`get_index $TAG` + + if [ $version != "v3" ] + + then + + if [ "$MODULE_TYPE" == "ICPIF" ] + then + VALOR=`snmpget -$version -Oqv -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.43.$INDICE` + fi + if [ "$MODULE_TYPE" == "MOS" ] + then + VALOR=`snmpget -$version -Oqv -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.42.$INDICE` + fi + if [ "$MODULE_TYPE" == "Packet_Out_of_Sequence" ] + then + VALOR=`snmpget -$version -Oqv -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.28.$INDICE` + fi + + if [ "$MODULE_TYPE" == "Packet_Late_Arrival" ] + then + VALOR=`snmpget -$version -Oqv -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.30.$INDICE` + fi + + if [ "$MODULE_TYPE" == "Average_Jitter" ] + then + VALOR=`snmpget -$version -Oqv -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.46.$INDICE` + fi + + if [ "$MODULE_TYPE" == "PacketLossSD" ] + then + VALOR=`snmpget -$version -Oqv -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.26.$INDICE` + fi + + if [ "$MODULE_TYPE" == "PacketLossDS" ] + then + VALOR=`snmpget -$version -Oqv -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.27.$INDICE` + fi + + if [ "$MODULE_TYPE" == "PacketLost" ] + then + VALOR=`snmpget -$version -Oqv -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.29.$INDICE` + fi + + if [ "$MODULE_TYPE" == "NegativesSD" ] + then + VALOR=`snmpget -$version -Oqv -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.12.$INDICE` + fi + + if [ "$MODULE_TYPE" == "NegativesDS" ] + then + VALOR=`snmpget -$version -Oqv -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.22.$INDICE` + fi + + if [ "$MODULE_TYPE" == "PositivesSD" ] + then + VALOR=`snmpget -$version -Oqv -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.7.$INDICE` + fi + + if [ "$MODULE_TYPE" == "PositivesDS" ] + then + VALOR=`snmpget -$version -Oqv -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.17.$INDICE` + fi + + if [ "$MODULE_TYPE" == "RTTMax" ] + then + VALOR=`snmpget -$version -Oqv -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.5.$INDICE` + fi + + if [ "$MODULE_TYPE" == "RTTMin" ] + then + VALOR=`snmpget -$version -Oqv -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.4.$INDICE` + fi + + if [ "$MODULE_TYPE" == "OperNumOfRTT" ] + then + VALOR=`snmpget -$version -Oqv -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.1.$INDICE` + fi + + if [ "$MODULE_TYPE" == "OperPacketLossSD" ] + then + VALOR=`snmpget -$version -Oqv -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.26.$INDICE` + fi + + if [ "$MODULE_TYPE" == "OperPacketLossDS" ] + then + VALOR=`snmpget -$version -Oqv -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.27.$INDICE` + fi + + if [ "$MODULE_TYPE" == "RttOperSense" ] + then + VALOR=`snmpget -$version -Oqv -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.2.10.1.1.$INDICE` + fi + + if [ "$MODULE_TYPE" == "RttOperCompletionTime" ] + then + VALOR=`snmpget -$version -Oqv -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.2.10.1.2.$INDICE` + fi + + if [ "$MODULE_TYPE" == "RttOperTime" ] + then + VALOR=`snmpget -$version -Oqv -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.2.10.1.5.$INDICE` + fi + + if [ "$MODULE_TYPE" == "RttOperAddress" ] + then + VALOR=`snmpget -$version -Oqv -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.2.10.1.6.$INDICE` + fi + + if [ "$MODULE_TYPE" == "HTTPOperRTT" ] + then + VALOR=`snmpget -$version -Oqv -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.1.1.1.$INDICE` + fi + + if [ "$MODULE_TYPE" == "HTTPOperDNSRTT" ] + then + VALOR=`snmpget -$version -Oqv -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.1.1.2.$INDICE` + fi + + if [ "$MODULE_TYPE" == "HTTPOperTCPConnectRTT" ] + then + VALOR=`snmpget -$version -Oqv -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.1.1.3.$INDICE` + fi + + if [ "$MODULE_TYPE" == "IcmpJitterAvgJitter" ] + then + VALOR=`snmpget -$version -Oqv -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.4.1.44.$INDICE` + fi + + if [ "$MODULE_TYPE" == "HTTPOperTransactionRTT" ] + then + VALOR=`snmpget -$version -Oqv -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.1.1.4.$INDICE` + fi + fi + + if [ $version == "v3" ] + + #if snmp v3 snmpget with v3 + then + if [ $auth == "authPriv" ] + # if authpriv snmpget with all parameters + then + if [ "$MODULE_TYPE" == "ICPIF" ] + then + VALOR=`snmpget -v 3 -l $auth -u $user -a $hash1 -A $hash1pass -x $hash2 -X $hash2pass -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.43.$INDICE` + fi + if [ "$MODULE_TYPE" == "MOS" ] + then + VALOR=`snmpget -v 3 -l $auth -u $user -a $hash1 -A $hash1pass -x $hash2 -X $hash2pass -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.42.$INDICE` + fi + if [ "$MODULE_TYPE" == "Packet_Out_of_Sequence" ] + then + VALOR=`snmpget -v 3 -l $auth -u $user -a $hash1 -A $hash1pass -x $hash2 -X $hash2pass -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.28.$INDICE` + fi + + if [ "$MODULE_TYPE" == "Packet_Late_Arrival" ] + then + VALOR=`snmpget -v 3 -l $auth -u $user -a $hash1 -A $hash1pass -x $hash2 -X $hash2pass -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.30.$INDICE` + fi + + if [ "$MODULE_TYPE" == "Average_Jitter" ] + then + VALOR=`snmpget -v 3 -l $auth -u $user -a $hash1 -A $hash1pass -x $hash2 -X $hash2pass -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.46.$INDICE` + fi + + if [ "$MODULE_TYPE" == "PacketLossSD" ] + then + VALOR=`snmpget -v 3 -l $auth -u $user -a $hash1 -A $hash1pass -x $hash2 -X $hash2pass -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.26.$INDICE` + fi + + if [ "$MODULE_TYPE" == "PacketLossDS" ] + then + VALOR=`snmpget -v 3 -l $auth -u $user -a $hash1 -A $hash1pass -x $hash2 -X $hash2pass -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.27.$INDICE` + fi + + if [ "$MODULE_TYPE" == "PacketLost" ] + then + VALOR=`snmpget -v 3 -l $auth -u $user -a $hash1 -A $hash1pass -x $hash2 -X $hash2pass -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.29.$INDICE` + fi + + if [ "$MODULE_TYPE" == "NegativesSD" ] + then + VALOR=`snmpget -v 3 -l $auth -u $user -a $hash1 -A $hash1pass -x $hash2 -X $hash2pass -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.12.$INDICE` + fi + + if [ "$MODULE_TYPE" == "NegativesDS" ] + then + VALOR=`snmpget -v 3 -l $auth -u $user -a $hash1 -A $hash1pass -x $hash2 -X $hash2pass -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.22.$INDICE` + fi + + if [ "$MODULE_TYPE" == "PositivesSD" ] + then + VALOR=`snmpget -v 3 -l $auth -u $user -a $hash1 -A $hash1pass -x $hash2 -X $hash2pass -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.7.$INDICE` + fi + + if [ "$MODULE_TYPE" == "PositivesDS" ] + then + VALOR=`snmpget -v 3 -l $auth -u $user -a $hash1 -A $hash1pass -x $hash2 -X $hash2pass -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.17.$INDICE` + fi + + if [ "$MODULE_TYPE" == "RTTMax" ] + then + VALOR=`snmpget -v 3 -l $auth -u $user -a $hash1 -A $hash1pass -x $hash2 -X $hash2pass -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.5.$INDICE` + fi + + if [ "$MODULE_TYPE" == "RTTMin" ] + then + VALOR=`snmpget -v 3 -l $auth -u $user -a $hash1 -A $hash1pass -x $hash2 -X $hash2pass -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.4.$INDICE` + fi + + if [ "$MODULE_TYPE" == "OperNumOfRTT" ] + then + VALOR=`snmpget -v 3 -l $auth -u $user -a $hash1 -A $hash1pass -x $hash2 -X $hash2pass -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.1.$INDICE` + fi + + if [ "$MODULE_TYPE" == "OperPacketLossSD" ] + then + VALOR=`snmpget -v 3 -l $auth -u $user -a $hash1 -A $hash1pass -x $hash2 -X $hash2pass -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.26.$INDICE` + fi + + if [ "$MODULE_TYPE" == "OperPacketLossDS" ] + then + VALOR=`snmpget -v 3 -l $auth -u $user -a $hash1 -A $hash1pass -x $hash2 -X $hash2pass -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.27.$INDICE` + fi + + if [ "$MODULE_TYPE" == "RttOperSense" ] + then + VALOR=`snmpget -v 3 -l $auth -u $user -a $hash1 -A $hash1pass -x $hash2 -X $hash2pass -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.2.10.1.1.$INDICE` + fi + + if [ "$MODULE_TYPE" == "RttOperCompletionTime" ] + then + VALOR=`snmpget -v 3 -l $auth -u $user -a $hash1 -A $hash1pass -x $hash2 -X $hash2pass -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.2.10.1.2.$INDICE` + fi + + if [ "$MODULE_TYPE" == "RttOperTime" ] + then + VALOR=`snmpget -v 3 -l $auth -u $user -a $hash1 -A $hash1pass -x $hash2 -X $hash2pass -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.2.10.1.5.$INDICE` + fi + + if [ "$MODULE_TYPE" == "RttOperAddress" ] + then + VALOR=`snmpget -v 3 -l $auth -u $user -a $hash1 -A $hash1pass -x $hash2 -X $hash2pass -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.2.10.1.6.$INDICE` + fi + + if [ "$MODULE_TYPE" == "HTTPOperRTT" ] + then + VALOR=`snmpget -v 3 -l $auth -u $user -a $hash1 -A $hash1pass -x $hash2 -X $hash2pass -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.1.1.1.$INDICE` + fi + + if [ "$MODULE_TYPE" == "HTTPOperDNSRTT" ] + then + VALOR=`snmpget -v 3 -l $auth -u $user -a $hash1 -A $hash1pass -x $hash2 -X $hash2pass -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.1.1.2.$INDICE` + fi + + if [ "$MODULE_TYPE" == "HTTPOperTCPConnectRTT" ] + then + VALOR=`snmpget -v 3 -l $auth -u $user -a $hash1 -A $hash1pass -x $hash2 -X $hash2pass -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.1.1.3.$INDICE` + fi + + if [ "$MODULE_TYPE" == "IcmpJitterAvgJitter" ] + then + VALOR=`snmpget -v 3 -l $auth -u $user -a $hash1 -A $hash1pass -x $hash2 -X $hash2pass -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.4.1.44.$INDICE` + fi + + if [ "$MODULE_TYPE" == "HTTPOperTransactionRTT" ] + then + VALOR=`snmpget -v 3 -l $auth -u $user -a $hash1 -A $hash1pass -x $hash2 -X $hash2pass -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.1.1.4.$INDICE` + fi + fi + if [ $auth == "authNoPriv" ] + then + if [ "$hash1" ] + then + if [ "$MODULE_TYPE" == "ICPIF" ] + then + VALOR=`snmpget -v 3 -l $auth -u $user -a $hash1 -A $hash1pass -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.43.$INDICE` + fi + if [ "$MODULE_TYPE" == "MOS" ] + then + VALOR=`snmpget -v 3 -l $auth -u $user -a $hash1 -A $hash1pass -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.42.$INDICE` + fi + if [ "$MODULE_TYPE" == "Packet_Out_of_Sequence" ] + then + VALOR=`snmpget -v 3 -l $auth -u $user -a $hash1 -A $hash1pass -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.28.$INDICE` + fi + + if [ "$MODULE_TYPE" == "Packet_Late_Arrival" ] + then + VALOR=`snmpget -v 3 -l $auth -u $user -a $hash1 -A $hash1pass -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.30.$INDICE` + fi + + if [ "$MODULE_TYPE" == "Average_Jitter" ] + then + VALOR=`snmpget -v 3 -l $auth -u $user -a $hash1 -A $hash1pass -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.46.$INDICE` + fi + + if [ "$MODULE_TYPE" == "PacketLossSD" ] + then + VALOR=`snmpget -v 3 -l $auth -u $user -a $hash1 -A $hash1pass -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.26.$INDICE` + fi + + if [ "$MODULE_TYPE" == "PacketLossDS" ] + then + VALOR=`snmpget -v 3 -l $auth -u $user -a $hash1 -A $hash1pass -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.27.$INDICE` + fi + + if [ "$MODULE_TYPE" == "PacketLost" ] + then + VALOR=`snmpget -v 3 -l $auth -u $user -a $hash1 -A $hash1pass -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.29.$INDICE` + fi + + if [ "$MODULE_TYPE" == "NegativesSD" ] + then + VALOR=`snmpget -v 3 -l $auth -u $user -a $hash1 -A $hash1pass -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.12.$INDICE` + fi + + if [ "$MODULE_TYPE" == "NegativesDS" ] + then + VALOR=`snmpget -v 3 -l $auth -u $user -a $hash1 -A $hash1pass -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.22.$INDICE` + fi + + if [ "$MODULE_TYPE" == "PositivesSD" ] + then + VALOR=`snmpget -v 3 -l $auth -u $user -a $hash1 -A $hash1pass -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.7.$INDICE` + fi + + if [ "$MODULE_TYPE" == "PositivesDS" ] + then + VALOR=`snmpget -v 3 -l $auth -u $user -a $hash1 -A $hash1pass -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.17.$INDICE` + fi + + if [ "$MODULE_TYPE" == "RTTMax" ] + then + VALOR=`snmpget -v 3 -l $auth -u $user -a $hash1 -A $hash1pass -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.5.$INDICE` + fi + + if [ "$MODULE_TYPE" == "RTTMin" ] + then + VALOR=`snmpget -v 3 -l $auth -u $user -a $hash1 -A $hash1pass -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.4.$INDICE` + fi + + if [ "$MODULE_TYPE" == "OperNumOfRTT" ] + then + VALOR=`snmpget -v 3 -l $auth -u $user -a $hash1 -A $hash1pass -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.1.$INDICE` + fi + + if [ "$MODULE_TYPE" == "OperPacketLossSD" ] + then + VALOR=`snmpget -v 3 -l $auth -u $user -a $hash1 -A $hash1pass -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.26.$INDICE` + fi + + if [ "$MODULE_TYPE" == "OperPacketLossDS" ] + then + VALOR=`snmpget -v 3 -l $auth -u $user -a $hash1 -A $hash1pass -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.27.$INDICE` + fi + + if [ "$MODULE_TYPE" == "RttOperSense" ] + then + VALOR=`snmpget -v 3 -l $auth -u $user -a $hash1 -A $hash1pass -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.2.10.1.1.$INDICE` + fi + + if [ "$MODULE_TYPE" == "RttOperCompletionTime" ] + then + VALOR=`snmpget -v 3 -l $auth -u $user -a $hash1 -A $hash1pass -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.2.10.1.2.$INDICE` + fi + + if [ "$MODULE_TYPE" == "RttOperTime" ] + then + VALOR=`snmpget -v 3 -l $auth -u $user -a $hash1 -A $hash1pass -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.2.10.1.5.$INDICE` + fi + + if [ "$MODULE_TYPE" == "RttOperAddress" ] + then + VALOR=`snmpget -v 3 -l $auth -u $user -a $hash1 -A $hash1pass -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.2.10.1.6.$INDICE` + fi + + if [ "$MODULE_TYPE" == "HTTPOperRTT" ] + then + VALOR=`snmpget -v 3 -l $auth -u $user -a $hash1 -A $hash1pass -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.1.1.1.$INDICE` + fi + + if [ "$MODULE_TYPE" == "HTTPOperDNSRTT" ] + then + VALOR=`snmpget -v 3 -l $auth -u $user -a $hash1 -A $hash1pass -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.1.1.2.$INDICE` + fi + + if [ "$MODULE_TYPE" == "HTTPOperTCPConnectRTT" ] + then + VALOR=`snmpget -v 3 -l $auth -u $user -a $hash1 -A $hash1pass -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.1.1.3.$INDICE` + fi + + if [ "$MODULE_TYPE" == "IcmpJitterAvgJitter" ] + then + VALOR=`snmpget -v 3 -l $auth -u $user -a $hash1 -A $hash1pass -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.4.1.44.$INDICE` + fi + + if [ "$MODULE_TYPE" == "HTTPOperTransactionRTT" ] + then + VALOR=`snmpget -v 3 -l $auth -u $user -a $hash1 -A $hash1pass -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.1.1.4.$INDICE` + fi + else + if [ "$MODULE_TYPE" == "ICPIF" ] + then + VALOR=`snmpget -v 3 -l $auth -u $user -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.43.$INDICE` + fi + if [ "$MODULE_TYPE" == "MOS" ] + then + VALOR=`snmpget -v 3 -l $auth -u $user -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.42.$INDICE` + fi + if [ "$MODULE_TYPE" == "Packet_Out_of_Sequence" ] + then + VALOR=`snmpget -v 3 -l $auth -u $user -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.28.$INDICE` + fi + + if [ "$MODULE_TYPE" == "Packet_Late_Arrival" ] + then + VALOR=`snmpget -v 3 -l $auth -u $user -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.30.$INDICE` + fi + + if [ "$MODULE_TYPE" == "Average_Jitter" ] + then + VALOR=`snmpget -v 3 -l $auth -u $user -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.46.$INDICE` + fi + + if [ "$MODULE_TYPE" == "PacketLossSD" ] + then + VALOR=`snmpget -v 3 -l $auth -u $user -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.26.$INDICE` + fi + + if [ "$MODULE_TYPE" == "PacketLossDS" ] + then + VALOR=`snmpget -v 3 -l $auth -u $user -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.27.$INDICE` + fi + + if [ "$MODULE_TYPE" == "PacketLost" ] + then + VALOR=`snmpget -v 3 -l $auth -u $user -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.29.$INDICE` + fi + + if [ "$MODULE_TYPE" == "NegativesSD" ] + then + VALOR=`snmpget -v 3 -l $auth -u $user -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.12.$INDICE` + fi + + if [ "$MODULE_TYPE" == "NegativesDS" ] + then + VALOR=`snmpget -v 3 -l $auth -u $user -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.22.$INDICE` + fi + + if [ "$MODULE_TYPE" == "PositivesSD" ] + then + VALOR=`snmpget -v 3 -l $auth -u $user -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.7.$INDICE` + fi + + if [ "$MODULE_TYPE" == "PositivesDS" ] + then + VALOR=`snmpget -v 3 -l $auth -u $user -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.17.$INDICE` + fi + + if [ "$MODULE_TYPE" == "RTTMax" ] + then + VALOR=`snmpget -v 3 -l $auth -u $user -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.5.$INDICE` + fi + + if [ "$MODULE_TYPE" == "RTTMin" ] + then + VALOR=`snmpget -v 3 -l $auth -u $user -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.4.$INDICE` + fi + + if [ "$MODULE_TYPE" == "OperNumOfRTT" ] + then + VALOR=`snmpget -v 3 -l $auth -u $user -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.1.$INDICE` + fi + + if [ "$MODULE_TYPE" == "OperPacketLossSD" ] + then + VALOR=`snmpget -v 3 -l $auth -u $user -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.26.$INDICE` + fi + + if [ "$MODULE_TYPE" == "OperPacketLossDS" ] + then + VALOR=`snmpget -v 3 -l $auth -u $user -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.27.$INDICE` + fi + + if [ "$MODULE_TYPE" == "RttOperSense" ] + then + VALOR=`snmpget -v 3 -l $auth -u $user -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.2.10.1.1.$INDICE` + fi + + if [ "$MODULE_TYPE" == "RttOperCompletionTime" ] + then + VALOR=`snmpget -v 3 -l $auth -u $user -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.2.10.1.2.$INDICE` + fi + + if [ "$MODULE_TYPE" == "RttOperTime" ] + then + VALOR=`snmpget -v 3 -l $auth -u $user -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.2.10.1.5.$INDICE` + fi + + if [ "$MODULE_TYPE" == "RttOperAddress" ] + then + VALOR=`snmpget -v 3 -l $auth -u $user -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.2.10.1.6.$INDICE` + fi + + if [ "$MODULE_TYPE" == "HTTPOperRTT" ] + then + VALOR=`snmpget -v 3 -l $auth -u $user -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.1.1.1.$INDICE` + fi + + if [ "$MODULE_TYPE" == "HTTPOperDNSRTT" ] + then + VALOR=`snmpget -v 3 -l $auth -u $user -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.1.1.2.$INDICE` + fi + + if [ "$MODULE_TYPE" == "HTTPOperTCPConnectRTT" ] + then + VALOR=`snmpget -v 3 -l $auth -u $user -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.1.1.3.$INDICE` + fi + + if [ "$MODULE_TYPE" == "IcmpJitterAvgJitter" ] + then + VALOR=`snmpget -v 3 -l $auth -u $user -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.4.1.44.$INDICE` + fi + + if [ "$MODULE_TYPE" == "HTTPOperTransactionRTT" ] + then + VALOR=`snmpget -v 3 -l $auth -u $user -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.1.1.4.$INDICE` + fi + + fi + + fi + fi + + echo -n $VALOR + exit 0 +} + +if [ -z "`which snmpwalk`" ] +then + echo "ERROR: snmpwalk is not in the path. Exiting..." + exit -1 +fi + +if [ $# -eq 0 ] +then + help +fi + +# Main parsing code + +while getopts ":hc:t:v:l:u:a:A:x:X:sm:g:" optname + do + case "$optname" in + "h") + help + ;; + "c") + COMMUNITY=$OPTARG + ;; + "t") + TARGET=$OPTARG + ;; + "v") + version=$OPTARG + ;; + "l") + auth=$OPTARG + ;; + "u") + user=$OPTARG + ;; + "a") + hash1=$OPTARG + ;; + "A") + hash1pass=$OPTARG + ;; + "x") + hash2=$OPTARG + ;; + "X") + hash2pass=$OPTARG + ;; + "g") + TAG=$OPTARG + ;; + "s") + show_tags + ;; + "m") + get_module $OPTARG $TAG + ;; + ?) + help + ;; + default) + help + ;; + + esac +done + +# Execution +echo "DEBUG" + +exit 0 From dc8c073f83424b70016b2578557d0f4e83c981c6 Mon Sep 17 00:00:00 2001 From: rafael Date: Mon, 20 Jun 2022 08:56:53 +0200 Subject: [PATCH 02/10] adding full snmpv3 support for cisco ipsla open plugin --- pandora_plugins/cisco_ipsla/pandora_ipsla.sh | 197 ++++++++++++++----- 1 file changed, 146 insertions(+), 51 deletions(-) mode change 100644 => 100755 pandora_plugins/cisco_ipsla/pandora_ipsla.sh diff --git a/pandora_plugins/cisco_ipsla/pandora_ipsla.sh b/pandora_plugins/cisco_ipsla/pandora_ipsla.sh old mode 100644 new mode 100755 index 976548f40b..729bf40828 --- a/pandora_plugins/cisco_ipsla/pandora_ipsla.sh +++ b/pandora_plugins/cisco_ipsla/pandora_ipsla.sh @@ -14,7 +14,7 @@ function help { echo -e "\t\t-t target" echo -e "\t\t-v version" echo -e "Other options\n"; - echo -e "\t\t-s show defined tags and indexes" + echo -e "\t\t-s show defined tags for cisco ipsla device and exit" echo -e "\t\t-l " echo -e "\t\t-u " echo -e "\t\t-a " @@ -23,12 +23,12 @@ function help { echo -e "\t\t-X " echo -e "\t\t-g " echo -e "\t\t-m \n" - echo -e "Modules can be: \n" + echo -e "Available Modules list: \n" echo -e "\tICPIF - Calculated Planning Impairment Factor for specified tag" echo -e "\tMOS - Mean Opinion Score" echo -e "\tPacket_Out_of_Sequence - Packets arriving out of sequence " echo -e "\tPacket_Late_Arrival - Packets arriving late" - echo -e "\tvAerage_Jitter - Average jitter is the estimated average jitter observed in the last XX RTP packets" + echo -e "\tAverage_Jitter - Average jitter is the estimated average jitter observed in the last XX RTP packets" echo -e "\tPacketLossSD - Packet loss from source to destination" echo -e "\tPacketLossDS - Packet loss from destination to source" echo -e "\tPacketLost - The number of packets that are lost for which we cannot determine the direction " @@ -50,167 +50,212 @@ function help { echo -e "\tHTTPOperTCPConnectRTT - Round Trip Time taken to connect to the HTTP server." echo -e "\tIcmpJitterAvgJitter The average of positive and negative jitter values in Source-to-Destionation and Destination-to-Source direction." echo -e "\tHTTPOperTransactionRTT - Round Trip Time taken to download the object specified by the URL." + echo -e "" + echo -e " Example execution" + echo -e " snmp version 3: ./pandora_ipsla.sh -t -v 3 -l authPriv -u pandorafms -a MD5 -A pandorafms -x AES -X pandorafms -g jitter -m Average_Jitter" + echo -e " snmp version 2c: ./pandora_ipsla.sh -t -v 2c -c public -g jitter -m Average_Jitter" + echo "" exit } function show_tags { - TAG_TABLE_CACHE=$TAG_TABLE_CACHE.$TARGET + local TAG_TABLE_CACHE=$TAG_TABLE_CACHE.$TARGET + + if [ $version != "3" ] + then + snmpwalk -v 1 -Onq -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.2.1.1.3 > $TAG_TABLE_CACHE + fi + if [ $version == "3" ] + #if snmp v3 snmpget with v3 + then + if [ $auth == "authPriv" ] + # if authpriv snmpget with all parameters + then + snmpwalk -v 3 -Onq -l $auth -u $user -a $hash1 -A $hash1pass -x $hash2 -X $hash2pass $TARGET 1.3.6.1.4.1.9.9.42.1.2.1.1.3 > $TAG_TABLE_CACHE + fi + if [ $auth == "authNoPriv" ] + then - # If not exist the cache, then create it - if [ ! -f "$TAG_TABLE_CACHE" ] - then - snmpwalk -v 1 -Onq -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.2.1.1.3 > $TAG_TABLE_CACHE - fi + snmpget -v 3 -Onq -l $auth -u $user -a $hash1 -A $hash1pass -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.2.1.1.3 > $TAG_TABLE_CACHE + fi + fi + cat $TAG_TABLE_CACHE | awk '{ print $2 }' | tr -d "\"" | grep -ve '^$' exit } +function update_tags { + local TAG_TABLE_CACHE=$TAG_TABLE_CACHE.$TARGET + + if [ $version != "3" ] + then + snmpwalk -v 1 -Onq -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.2.1.1.3 > $TAG_TABLE_CACHE + fi + if [ $version == "3" ] + #if snmp v3 snmpget with v3 + then + if [ $auth == "authPriv" ] + # if authpriv snmpget with all parameters + then + snmpwalk -v 3 -Onq -l $auth -u $user -a $hash1 -A $hash1pass -x $hash2 -X $hash2pass $TARGET 1.3.6.1.4.1.9.9.42.1.2.1.1.3 > $TAG_TABLE_CACHE + fi + if [ $auth == "authNoPriv" ] + then + + snmpget -v 3 -Onq -l $auth -u $user -a $hash1 -A $hash1pass -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.2.1.1.3 > $TAG_TABLE_CACHE + fi + fi + + +} + function get_index { - cat $TAG_TABLE_CACHE.$TARGET | grep $1 | grep -o "[0-9]*\s" + cat $TAG_TABLE_CACHE.$TARGET | grep "\"$1\"" | grep -o "[0-9]*\s" } # This function requires two arguments. MODULE_TYPE TAG function get_module { MODULE_TYPE=$1 TAG=$2 + update_tags INDICE=`get_index $TAG` - if [ $version != "v3" ] + if [ $version != "3" ] then if [ "$MODULE_TYPE" == "ICPIF" ] then - VALOR=`snmpget -$version -Oqv -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.43.$INDICE` + VALOR=`snmpget -v $version -Oqv -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.43.$INDICE` fi if [ "$MODULE_TYPE" == "MOS" ] then - VALOR=`snmpget -$version -Oqv -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.42.$INDICE` + VALOR=`snmpget -v $version -Oqv -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.42.$INDICE` fi if [ "$MODULE_TYPE" == "Packet_Out_of_Sequence" ] then - VALOR=`snmpget -$version -Oqv -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.28.$INDICE` + VALOR=`snmpget -v $version -Oqv -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.28.$INDICE` fi if [ "$MODULE_TYPE" == "Packet_Late_Arrival" ] then - VALOR=`snmpget -$version -Oqv -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.30.$INDICE` + VALOR=`snmpget -v $version -Oqv -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.30.$INDICE` fi if [ "$MODULE_TYPE" == "Average_Jitter" ] then - VALOR=`snmpget -$version -Oqv -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.46.$INDICE` + VALOR=`snmpget -v $version -Oqv -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.46.$INDICE` fi if [ "$MODULE_TYPE" == "PacketLossSD" ] then - VALOR=`snmpget -$version -Oqv -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.26.$INDICE` + VALOR=`snmpget -v $version -Oqv -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.26.$INDICE` fi if [ "$MODULE_TYPE" == "PacketLossDS" ] then - VALOR=`snmpget -$version -Oqv -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.27.$INDICE` + VALOR=`snmpget -v $version -Oqv -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.27.$INDICE` fi if [ "$MODULE_TYPE" == "PacketLost" ] then - VALOR=`snmpget -$version -Oqv -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.29.$INDICE` + VALOR=`snmpget -v $version -Oqv -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.29.$INDICE` fi if [ "$MODULE_TYPE" == "NegativesSD" ] then - VALOR=`snmpget -$version -Oqv -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.12.$INDICE` + VALOR=`snmpget -v $version -Oqv -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.12.$INDICE` fi if [ "$MODULE_TYPE" == "NegativesDS" ] then - VALOR=`snmpget -$version -Oqv -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.22.$INDICE` + VALOR=`snmpget -v $version -Oqv -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.22.$INDICE` fi if [ "$MODULE_TYPE" == "PositivesSD" ] then - VALOR=`snmpget -$version -Oqv -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.7.$INDICE` + VALOR=`snmpget -v $version -Oqv -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.7.$INDICE` fi if [ "$MODULE_TYPE" == "PositivesDS" ] then - VALOR=`snmpget -$version -Oqv -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.17.$INDICE` + VALOR=`snmpget -v $version -Oqv -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.17.$INDICE` fi if [ "$MODULE_TYPE" == "RTTMax" ] then - VALOR=`snmpget -$version -Oqv -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.5.$INDICE` + VALOR=`snmpget -v $version -Oqv -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.5.$INDICE` fi if [ "$MODULE_TYPE" == "RTTMin" ] then - VALOR=`snmpget -$version -Oqv -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.4.$INDICE` + VALOR=`snmpget -v $version -Oqv -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.4.$INDICE` fi if [ "$MODULE_TYPE" == "OperNumOfRTT" ] then - VALOR=`snmpget -$version -Oqv -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.1.$INDICE` + VALOR=`snmpget -v $version -Oqv -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.1.$INDICE` fi if [ "$MODULE_TYPE" == "OperPacketLossSD" ] then - VALOR=`snmpget -$version -Oqv -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.26.$INDICE` + VALOR=`snmpget -v $version -Oqv -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.26.$INDICE` fi if [ "$MODULE_TYPE" == "OperPacketLossDS" ] then - VALOR=`snmpget -$version -Oqv -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.27.$INDICE` - fi - - if [ "$MODULE_TYPE" == "RttOperSense" ] - then - VALOR=`snmpget -$version -Oqv -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.2.10.1.1.$INDICE` + VALOR=`snmpget -v $version -Oqv -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.27.$INDICE` fi if [ "$MODULE_TYPE" == "RttOperCompletionTime" ] then - VALOR=`snmpget -$version -Oqv -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.2.10.1.2.$INDICE` + VALOR=`snmpget -v $version -Oqv -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.2.10.1.1.$INDICE` + fi + + if [ "$MODULE_TYPE" == "RttOperSense" ] + then + VALOR=`snmpget -v $version -Oqv -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.2.10.1.2.$INDICE` fi if [ "$MODULE_TYPE" == "RttOperTime" ] then - VALOR=`snmpget -$version -Oqv -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.2.10.1.5.$INDICE` + VALOR=`snmpget -v $version -Oqv -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.2.10.1.5.$INDICE` fi if [ "$MODULE_TYPE" == "RttOperAddress" ] then - VALOR=`snmpget -$version -Oqv -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.2.10.1.6.$INDICE` + VALOR=`snmpget -v $version -Oqv -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.2.10.1.6.$INDICE` fi if [ "$MODULE_TYPE" == "HTTPOperRTT" ] then - VALOR=`snmpget -$version -Oqv -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.1.1.1.$INDICE` + VALOR=`snmpget -v $version -Oqv -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.1.1.1.$INDICE` fi if [ "$MODULE_TYPE" == "HTTPOperDNSRTT" ] then - VALOR=`snmpget -$version -Oqv -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.1.1.2.$INDICE` + VALOR=`snmpget -v $version -Oqv -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.1.1.2.$INDICE` fi if [ "$MODULE_TYPE" == "HTTPOperTCPConnectRTT" ] then - VALOR=`snmpget -$version -Oqv -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.1.1.3.$INDICE` + VALOR=`snmpget -v $version -Oqv -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.1.1.3.$INDICE` fi if [ "$MODULE_TYPE" == "IcmpJitterAvgJitter" ] then - VALOR=`snmpget -$version -Oqv -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.4.1.44.$INDICE` + VALOR=`snmpget -v $version -Oqv -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.4.1.44.$INDICE` fi if [ "$MODULE_TYPE" == "HTTPOperTransactionRTT" ] then - VALOR=`snmpget -$version -Oqv -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.1.1.4.$INDICE` + VALOR=`snmpget -v $version -Oqv -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.1.1.4.$INDICE` fi fi - if [ $version == "v3" ] + if [ $version == "3" ] #if snmp v3 snmpget with v3 then @@ -300,12 +345,12 @@ function get_module { VALOR=`snmpget -v 3 -l $auth -u $user -a $hash1 -A $hash1pass -x $hash2 -X $hash2pass -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.27.$INDICE` fi - if [ "$MODULE_TYPE" == "RttOperSense" ] + if [ "$MODULE_TYPE" == "RttOperCompletionTime" ] then VALOR=`snmpget -v 3 -l $auth -u $user -a $hash1 -A $hash1pass -x $hash2 -X $hash2pass -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.2.10.1.1.$INDICE` fi - if [ "$MODULE_TYPE" == "RttOperCompletionTime" ] + if [ "$MODULE_TYPE" == "RttOperSense" ] then VALOR=`snmpget -v 3 -l $auth -u $user -a $hash1 -A $hash1pass -x $hash2 -X $hash2pass -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.2.10.1.2.$INDICE` fi @@ -432,12 +477,12 @@ function get_module { VALOR=`snmpget -v 3 -l $auth -u $user -a $hash1 -A $hash1pass -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.27.$INDICE` fi - if [ "$MODULE_TYPE" == "RttOperSense" ] + if [ "$MODULE_TYPE" == "RttOperCompletionTime" ] then VALOR=`snmpget -v 3 -l $auth -u $user -a $hash1 -A $hash1pass -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.2.10.1.1.$INDICE` fi - if [ "$MODULE_TYPE" == "RttOperCompletionTime" ] + if [ "$MODULE_TYPE" == "RttOperSense" ] then VALOR=`snmpget -v 3 -l $auth -u $user -a $hash1 -A $hash1pass -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.2.10.1.2.$INDICE` fi @@ -560,12 +605,12 @@ function get_module { VALOR=`snmpget -v 3 -l $auth -u $user -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.5.2.1.27.$INDICE` fi - if [ "$MODULE_TYPE" == "RttOperSense" ] + if [ "$MODULE_TYPE" == "RttOperCompletionTime" ] then VALOR=`snmpget -v 3 -l $auth -u $user -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.2.10.1.1.$INDICE` fi - if [ "$MODULE_TYPE" == "RttOperCompletionTime" ] + if [ "$MODULE_TYPE" == "RttOperSense" ] then VALOR=`snmpget -v 3 -l $auth -u $user -c $COMMUNITY $TARGET 1.3.6.1.4.1.9.9.42.1.2.10.1.2.$INDICE` fi @@ -610,7 +655,7 @@ function get_module { fi fi - echo -n $VALOR + echo -n $VALOR | awk '{print $NF}' exit 0 } @@ -664,10 +709,10 @@ while getopts ":hc:t:v:l:u:a:A:x:X:sm:g:" optname TAG=$OPTARG ;; "s") - show_tags + SHOWTAGS=1 ;; "m") - get_module $OPTARG $TAG + MODULE=$OPTARG ;; ?) help @@ -680,6 +725,56 @@ while getopts ":hc:t:v:l:u:a:A:x:X:sm:g:" optname done # Execution +[ "$SHOWTAGS" ] && echo "Showing avaliables ipsla tags for the device $TARGET" && show_tags + +[ -z "$TARGET" ] && echo "Error missing target ip definition please use -t to difine it or -h to see help" && exit 1 +[ -z "$MODULE" ] && echo "Error missing module definition please use -m to difine it or -h to see help" && exit 1 +[ -z "$TAG" ] && echo "Error missing tag definition please use -g to difine it or -h to see help" && exit 1 +[ -z "$version" ] && echo "Error missing snmp version definition please use -v to difine it or -h to see help" && exit 1 + + +get_module $MODULE $TAG echo "DEBUG" exit 0 + +#RttOperSense +# 0:other +# 1:ok +# 2:disconnected +# 3:overThreshold +# 4:timeout +# 5:busy +# 6:notConnected +# 7:dropped +# 8:sequenceError +# 9:verifyError +# 10:applicationSpecific +# 11:dnsServerTimeout +# 12:tcpConnectTimeout +# 13:httpTransactionTimeout +# 14:dnsQueryError +# 15:httpError +# 16:error +# 17:mplsLspEchoTxError +# 18:mplsLspUnreachable +# 19:mplsLspMalformedReq +# 20:mplsLspReachButNotFEC +# 21:enableOk +# 22:enableNoConnect +# 23:enableVersionFail +# 24:enableInternalError +# 25:enableAbort +# 26:enableFail +# 27:enableAuthFail +# 28:enableFormatError +# 29:enablePortInUse +# 30:statsRetrieveOk +# 31:statsRetrieveNoConnect +# 32:statsRetrieveVersionFail +# 33:statsRetrieveInternalError +# 34:statsRetrieveAbort +# 35:statsRetrieveFail +# 36:statsRetrieveAuthFail +# 37:statsRetrieveFormatError +# 38:statsRetrievePortInUse \ No newline at end of file From fe46bb92359c35d8d486710627d9249622c80d30 Mon Sep 17 00:00:00 2001 From: Calvo Date: Thu, 30 Jun 2022 11:24:17 +0200 Subject: [PATCH 03/10] Addded pandora_version and build_version globals --- pandora_console/include/global_config.php | 2 ++ 1 file changed, 2 insertions(+) diff --git a/pandora_console/include/global_config.php b/pandora_console/include/global_config.php index d23c6994a6..b14c2b0ae5 100644 --- a/pandora_console/include/global_config.php +++ b/pandora_console/include/global_config.php @@ -1,5 +1,7 @@ Date: Fri, 1 Jul 2022 10:37:08 +0200 Subject: [PATCH 04/10] #9226 Added tuser_task tables --- pandora_console/extras/mr/56.sql | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) create mode 100644 pandora_console/extras/mr/56.sql diff --git a/pandora_console/extras/mr/56.sql b/pandora_console/extras/mr/56.sql new file mode 100644 index 0000000000..bd7681301c --- /dev/null +++ b/pandora_console/extras/mr/56.sql @@ -0,0 +1,26 @@ +START TRANSACTION; + +CREATE TABLE IF NOT EXISTS `tuser_task` ( + `id` INT UNSIGNED NOT NULL AUTO_INCREMENT, + `function_name` VARCHAR(80) NOT NULL DEFAULT '', + `parameters` TEXT , + `name` VARCHAR(60) NOT NULL DEFAULT '', + PRIMARY KEY (`id`) +) ENGINE=InnoDB DEFAULT CHARSET=UTF8MB4; + + +CREATE TABLE IF NOT EXISTS `tuser_task_scheduled` ( + `id` INT UNSIGNED NOT NULL AUTO_INCREMENT, + `id_usuario` VARCHAR(255) NOT NULL DEFAULT '0', + `id_user_task` INT UNSIGNED NOT NULL DEFAULT 0, + `args` TEXT, + `scheduled` ENUM('no','hourly','daily','weekly','monthly','yearly','custom') DEFAULT 'no', + `last_run` INT UNSIGNED DEFAULT 0, + `custom_data` INT NULL DEFAULT 0, + `flag_delete` TINYINT UNSIGNED NOT NULL DEFAULT 0, + `id_grupo` INT UNSIGNED NOT NULL DEFAULT 0, + `enabled` TINYINT UNSIGNED NOT NULL DEFAULT 1, + PRIMARY KEY (`id`) +) ENGINE=InnoDB DEFAULT CHARSET=UTF8MB4; + +COMMIT; From be923c883868181cdcc0603ac5ff34f6dea67f77 Mon Sep 17 00:00:00 2001 From: artica Date: Sat, 9 Jul 2022 01:00:37 +0200 Subject: [PATCH 05/10] Auto-updated build strings. --- pandora_agents/unix/DEBIAN/control | 2 +- pandora_agents/unix/DEBIAN/make_deb_package.sh | 2 +- pandora_agents/unix/pandora_agent | 2 +- pandora_agents/unix/pandora_agent.redhat.spec | 2 +- pandora_agents/unix/pandora_agent.spec | 2 +- pandora_agents/unix/pandora_agent_installer | 2 +- pandora_agents/win32/installer/pandora.mpi | 2 +- pandora_agents/win32/pandora.cc | 2 +- pandora_agents/win32/versioninfo.rc | 2 +- pandora_console/DEBIAN/control | 2 +- pandora_console/DEBIAN/make_deb_package.sh | 2 +- pandora_console/include/config_process.php | 2 +- pandora_console/install.php | 2 +- pandora_console/pandora_console.redhat.spec | 2 +- pandora_console/pandora_console.rhel7.spec | 2 +- pandora_console/pandora_console.spec | 2 +- pandora_server/DEBIAN/control | 2 +- pandora_server/DEBIAN/make_deb_package.sh | 2 +- pandora_server/lib/PandoraFMS/Config.pm | 2 +- pandora_server/lib/PandoraFMS/PluginTools.pm | 2 +- pandora_server/pandora_server.redhat.spec | 2 +- pandora_server/pandora_server.spec | 2 +- pandora_server/pandora_server_installer | 2 +- pandora_server/util/pandora_db.pl | 2 +- pandora_server/util/pandora_manage.pl | 2 +- 25 files changed, 25 insertions(+), 25 deletions(-) diff --git a/pandora_agents/unix/DEBIAN/control b/pandora_agents/unix/DEBIAN/control index d620148297..35a39f2896 100644 --- a/pandora_agents/unix/DEBIAN/control +++ b/pandora_agents/unix/DEBIAN/control @@ -1,5 +1,5 @@ package: pandorafms-agent-unix -Version: 7.0NG.763-220708 +Version: 7.0NG.763-220709 Architecture: all Priority: optional Section: admin diff --git a/pandora_agents/unix/DEBIAN/make_deb_package.sh b/pandora_agents/unix/DEBIAN/make_deb_package.sh index c248f2efba..345e62b576 100644 --- a/pandora_agents/unix/DEBIAN/make_deb_package.sh +++ b/pandora_agents/unix/DEBIAN/make_deb_package.sh @@ -14,7 +14,7 @@ # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. -pandora_version="7.0NG.763-220708" +pandora_version="7.0NG.763-220709" echo "Test if you has the tools for to make the packages." whereis dpkg-deb | cut -d":" -f2 | grep dpkg-deb > /dev/null diff --git a/pandora_agents/unix/pandora_agent b/pandora_agents/unix/pandora_agent index 7b0ef373d0..85674b3141 100755 --- a/pandora_agents/unix/pandora_agent +++ b/pandora_agents/unix/pandora_agent @@ -1015,7 +1015,7 @@ my $Sem = undef; my $ThreadSem = undef; use constant AGENT_VERSION => '7.0NG.763'; -use constant AGENT_BUILD => '220708'; +use constant AGENT_BUILD => '220709'; # Agent log default file size maximum and instances use constant DEFAULT_MAX_LOG_SIZE => 600000; diff --git a/pandora_agents/unix/pandora_agent.redhat.spec b/pandora_agents/unix/pandora_agent.redhat.spec index bb970c96eb..9a10c952c7 100644 --- a/pandora_agents/unix/pandora_agent.redhat.spec +++ b/pandora_agents/unix/pandora_agent.redhat.spec @@ -3,7 +3,7 @@ # %define name pandorafms_agent_unix %define version 7.0NG.763 -%define release 220708 +%define release 220709 Summary: Pandora FMS Linux agent, PERL version Name: %{name} diff --git a/pandora_agents/unix/pandora_agent.spec b/pandora_agents/unix/pandora_agent.spec index d3d00efb6d..acdd44a4a4 100644 --- a/pandora_agents/unix/pandora_agent.spec +++ b/pandora_agents/unix/pandora_agent.spec @@ -3,7 +3,7 @@ # %define name pandorafms_agent_unix %define version 7.0NG.763 -%define release 220708 +%define release 220709 Summary: Pandora FMS Linux agent, PERL version Name: %{name} diff --git a/pandora_agents/unix/pandora_agent_installer b/pandora_agents/unix/pandora_agent_installer index f9ea0fec3d..9fe68a87fe 100755 --- a/pandora_agents/unix/pandora_agent_installer +++ b/pandora_agents/unix/pandora_agent_installer @@ -10,7 +10,7 @@ # ********************************************************************** PI_VERSION="7.0NG.763" -PI_BUILD="220708" +PI_BUILD="220709" OS_NAME=`uname -s` FORCE=0 diff --git a/pandora_agents/win32/installer/pandora.mpi b/pandora_agents/win32/installer/pandora.mpi index 6331b590dd..5a83eacce3 100644 --- a/pandora_agents/win32/installer/pandora.mpi +++ b/pandora_agents/win32/installer/pandora.mpi @@ -186,7 +186,7 @@ UpgradeApplicationID {} Version -{220708} +{220709} ViewReadme {Yes} diff --git a/pandora_agents/win32/pandora.cc b/pandora_agents/win32/pandora.cc index 0462017956..3f81ca5334 100644 --- a/pandora_agents/win32/pandora.cc +++ b/pandora_agents/win32/pandora.cc @@ -30,7 +30,7 @@ using namespace Pandora; using namespace Pandora_Strutils; #define PATH_SIZE _MAX_PATH+1 -#define PANDORA_VERSION ("7.0NG.763 Build 220708") +#define PANDORA_VERSION ("7.0NG.763 Build 220709") string pandora_path; string pandora_dir; diff --git a/pandora_agents/win32/versioninfo.rc b/pandora_agents/win32/versioninfo.rc index 19fdb8a995..9ee4130781 100644 --- a/pandora_agents/win32/versioninfo.rc +++ b/pandora_agents/win32/versioninfo.rc @@ -11,7 +11,7 @@ BEGIN VALUE "LegalCopyright", "Artica ST" VALUE "OriginalFilename", "PandoraAgent.exe" VALUE "ProductName", "Pandora FMS Windows Agent" - VALUE "ProductVersion", "(7.0NG.763(Build 220708))" + VALUE "ProductVersion", "(7.0NG.763(Build 220709))" VALUE "FileVersion", "1.0.0.0" END END diff --git a/pandora_console/DEBIAN/control b/pandora_console/DEBIAN/control index 81de2e2b2c..ff8564c218 100644 --- a/pandora_console/DEBIAN/control +++ b/pandora_console/DEBIAN/control @@ -1,5 +1,5 @@ package: pandorafms-console -Version: 7.0NG.763-220708 +Version: 7.0NG.763-220709 Architecture: all Priority: optional Section: admin diff --git a/pandora_console/DEBIAN/make_deb_package.sh b/pandora_console/DEBIAN/make_deb_package.sh index 4146a78493..25b6b63c78 100644 --- a/pandora_console/DEBIAN/make_deb_package.sh +++ b/pandora_console/DEBIAN/make_deb_package.sh @@ -14,7 +14,7 @@ # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. -pandora_version="7.0NG.763-220708" +pandora_version="7.0NG.763-220709" package_pear=0 package_pandora=1 diff --git a/pandora_console/include/config_process.php b/pandora_console/include/config_process.php index 946a264c45..128b96136f 100644 --- a/pandora_console/include/config_process.php +++ b/pandora_console/include/config_process.php @@ -20,7 +20,7 @@ /** * Pandora build version and version */ -$build_version = 'PC220708'; +$build_version = 'PC220709'; $pandora_version = 'v7.0NG.763'; // Do not overwrite default timezone set if defined. diff --git a/pandora_console/install.php b/pandora_console/install.php index c055b5f58d..5ca5605c28 100644 --- a/pandora_console/install.php +++ b/pandora_console/install.php @@ -129,7 +129,7 @@
[ qw() ] ); diff --git a/pandora_server/pandora_server.redhat.spec b/pandora_server/pandora_server.redhat.spec index e1520a8740..807e45af31 100644 --- a/pandora_server/pandora_server.redhat.spec +++ b/pandora_server/pandora_server.redhat.spec @@ -3,7 +3,7 @@ # %define name pandorafms_server %define version 7.0NG.763 -%define release 220708 +%define release 220709 Summary: Pandora FMS Server Name: %{name} diff --git a/pandora_server/pandora_server.spec b/pandora_server/pandora_server.spec index 271a8c94b5..e54cafca94 100644 --- a/pandora_server/pandora_server.spec +++ b/pandora_server/pandora_server.spec @@ -3,7 +3,7 @@ # %define name pandorafms_server %define version 7.0NG.763 -%define release 220708 +%define release 220709 Summary: Pandora FMS Server Name: %{name} diff --git a/pandora_server/pandora_server_installer b/pandora_server/pandora_server_installer index 594c65cdf3..903439cd2c 100755 --- a/pandora_server/pandora_server_installer +++ b/pandora_server/pandora_server_installer @@ -9,7 +9,7 @@ # ********************************************************************** PI_VERSION="7.0NG.763" -PI_BUILD="220708" +PI_BUILD="220709" MODE=$1 if [ $# -gt 1 ]; then diff --git a/pandora_server/util/pandora_db.pl b/pandora_server/util/pandora_db.pl index 18256e20c5..bbb7b8fd6c 100755 --- a/pandora_server/util/pandora_db.pl +++ b/pandora_server/util/pandora_db.pl @@ -35,7 +35,7 @@ use PandoraFMS::Config; use PandoraFMS::DB; # version: define current version -my $version = "7.0NG.763 Build 220708"; +my $version = "7.0NG.763 Build 220709"; # Pandora server configuration my %conf; diff --git a/pandora_server/util/pandora_manage.pl b/pandora_server/util/pandora_manage.pl index 638c065bfe..e7088266c3 100755 --- a/pandora_server/util/pandora_manage.pl +++ b/pandora_server/util/pandora_manage.pl @@ -36,7 +36,7 @@ use Encode::Locale; Encode::Locale::decode_argv; # version: define current version -my $version = "7.0NG.763 Build 220708"; +my $version = "7.0NG.763 Build 220709"; # save program name for logging my $progname = basename($0); From c72bf4fc9e71de3920ec1fb68496427a8146af02 Mon Sep 17 00:00:00 2001 From: artica Date: Sun, 10 Jul 2022 01:00:19 +0200 Subject: [PATCH 06/10] Auto-updated build strings. --- pandora_agents/unix/DEBIAN/control | 2 +- pandora_agents/unix/DEBIAN/make_deb_package.sh | 2 +- pandora_agents/unix/pandora_agent | 2 +- pandora_agents/unix/pandora_agent.redhat.spec | 2 +- pandora_agents/unix/pandora_agent.spec | 2 +- pandora_agents/unix/pandora_agent_installer | 2 +- pandora_agents/win32/installer/pandora.mpi | 2 +- pandora_agents/win32/pandora.cc | 2 +- pandora_agents/win32/versioninfo.rc | 2 +- pandora_console/DEBIAN/control | 2 +- pandora_console/DEBIAN/make_deb_package.sh | 2 +- pandora_console/include/config_process.php | 2 +- pandora_console/install.php | 2 +- pandora_console/pandora_console.redhat.spec | 2 +- pandora_console/pandora_console.rhel7.spec | 2 +- pandora_console/pandora_console.spec | 2 +- pandora_server/DEBIAN/control | 2 +- pandora_server/DEBIAN/make_deb_package.sh | 2 +- pandora_server/lib/PandoraFMS/Config.pm | 2 +- pandora_server/lib/PandoraFMS/PluginTools.pm | 2 +- pandora_server/pandora_server.redhat.spec | 2 +- pandora_server/pandora_server.spec | 2 +- pandora_server/pandora_server_installer | 2 +- pandora_server/util/pandora_db.pl | 2 +- pandora_server/util/pandora_manage.pl | 2 +- 25 files changed, 25 insertions(+), 25 deletions(-) diff --git a/pandora_agents/unix/DEBIAN/control b/pandora_agents/unix/DEBIAN/control index 35a39f2896..91376e2ac8 100644 --- a/pandora_agents/unix/DEBIAN/control +++ b/pandora_agents/unix/DEBIAN/control @@ -1,5 +1,5 @@ package: pandorafms-agent-unix -Version: 7.0NG.763-220709 +Version: 7.0NG.763-220710 Architecture: all Priority: optional Section: admin diff --git a/pandora_agents/unix/DEBIAN/make_deb_package.sh b/pandora_agents/unix/DEBIAN/make_deb_package.sh index 345e62b576..b57c51499e 100644 --- a/pandora_agents/unix/DEBIAN/make_deb_package.sh +++ b/pandora_agents/unix/DEBIAN/make_deb_package.sh @@ -14,7 +14,7 @@ # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. -pandora_version="7.0NG.763-220709" +pandora_version="7.0NG.763-220710" echo "Test if you has the tools for to make the packages." whereis dpkg-deb | cut -d":" -f2 | grep dpkg-deb > /dev/null diff --git a/pandora_agents/unix/pandora_agent b/pandora_agents/unix/pandora_agent index 85674b3141..8c9d1b4707 100755 --- a/pandora_agents/unix/pandora_agent +++ b/pandora_agents/unix/pandora_agent @@ -1015,7 +1015,7 @@ my $Sem = undef; my $ThreadSem = undef; use constant AGENT_VERSION => '7.0NG.763'; -use constant AGENT_BUILD => '220709'; +use constant AGENT_BUILD => '220710'; # Agent log default file size maximum and instances use constant DEFAULT_MAX_LOG_SIZE => 600000; diff --git a/pandora_agents/unix/pandora_agent.redhat.spec b/pandora_agents/unix/pandora_agent.redhat.spec index 9a10c952c7..5bc8346040 100644 --- a/pandora_agents/unix/pandora_agent.redhat.spec +++ b/pandora_agents/unix/pandora_agent.redhat.spec @@ -3,7 +3,7 @@ # %define name pandorafms_agent_unix %define version 7.0NG.763 -%define release 220709 +%define release 220710 Summary: Pandora FMS Linux agent, PERL version Name: %{name} diff --git a/pandora_agents/unix/pandora_agent.spec b/pandora_agents/unix/pandora_agent.spec index acdd44a4a4..8ea2dc6d63 100644 --- a/pandora_agents/unix/pandora_agent.spec +++ b/pandora_agents/unix/pandora_agent.spec @@ -3,7 +3,7 @@ # %define name pandorafms_agent_unix %define version 7.0NG.763 -%define release 220709 +%define release 220710 Summary: Pandora FMS Linux agent, PERL version Name: %{name} diff --git a/pandora_agents/unix/pandora_agent_installer b/pandora_agents/unix/pandora_agent_installer index 9fe68a87fe..810f300b70 100755 --- a/pandora_agents/unix/pandora_agent_installer +++ b/pandora_agents/unix/pandora_agent_installer @@ -10,7 +10,7 @@ # ********************************************************************** PI_VERSION="7.0NG.763" -PI_BUILD="220709" +PI_BUILD="220710" OS_NAME=`uname -s` FORCE=0 diff --git a/pandora_agents/win32/installer/pandora.mpi b/pandora_agents/win32/installer/pandora.mpi index 5a83eacce3..c56d427f47 100644 --- a/pandora_agents/win32/installer/pandora.mpi +++ b/pandora_agents/win32/installer/pandora.mpi @@ -186,7 +186,7 @@ UpgradeApplicationID {} Version -{220709} +{220710} ViewReadme {Yes} diff --git a/pandora_agents/win32/pandora.cc b/pandora_agents/win32/pandora.cc index 3f81ca5334..78037e6f8c 100644 --- a/pandora_agents/win32/pandora.cc +++ b/pandora_agents/win32/pandora.cc @@ -30,7 +30,7 @@ using namespace Pandora; using namespace Pandora_Strutils; #define PATH_SIZE _MAX_PATH+1 -#define PANDORA_VERSION ("7.0NG.763 Build 220709") +#define PANDORA_VERSION ("7.0NG.763 Build 220710") string pandora_path; string pandora_dir; diff --git a/pandora_agents/win32/versioninfo.rc b/pandora_agents/win32/versioninfo.rc index 9ee4130781..ffbe1f190e 100644 --- a/pandora_agents/win32/versioninfo.rc +++ b/pandora_agents/win32/versioninfo.rc @@ -11,7 +11,7 @@ BEGIN VALUE "LegalCopyright", "Artica ST" VALUE "OriginalFilename", "PandoraAgent.exe" VALUE "ProductName", "Pandora FMS Windows Agent" - VALUE "ProductVersion", "(7.0NG.763(Build 220709))" + VALUE "ProductVersion", "(7.0NG.763(Build 220710))" VALUE "FileVersion", "1.0.0.0" END END diff --git a/pandora_console/DEBIAN/control b/pandora_console/DEBIAN/control index ff8564c218..0fce247ecf 100644 --- a/pandora_console/DEBIAN/control +++ b/pandora_console/DEBIAN/control @@ -1,5 +1,5 @@ package: pandorafms-console -Version: 7.0NG.763-220709 +Version: 7.0NG.763-220710 Architecture: all Priority: optional Section: admin diff --git a/pandora_console/DEBIAN/make_deb_package.sh b/pandora_console/DEBIAN/make_deb_package.sh index 25b6b63c78..550af4f37d 100644 --- a/pandora_console/DEBIAN/make_deb_package.sh +++ b/pandora_console/DEBIAN/make_deb_package.sh @@ -14,7 +14,7 @@ # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. -pandora_version="7.0NG.763-220709" +pandora_version="7.0NG.763-220710" package_pear=0 package_pandora=1 diff --git a/pandora_console/include/config_process.php b/pandora_console/include/config_process.php index 128b96136f..582d2bb634 100644 --- a/pandora_console/include/config_process.php +++ b/pandora_console/include/config_process.php @@ -20,7 +20,7 @@ /** * Pandora build version and version */ -$build_version = 'PC220709'; +$build_version = 'PC220710'; $pandora_version = 'v7.0NG.763'; // Do not overwrite default timezone set if defined. diff --git a/pandora_console/install.php b/pandora_console/install.php index 5ca5605c28..e788140726 100644 --- a/pandora_console/install.php +++ b/pandora_console/install.php @@ -129,7 +129,7 @@
[ qw() ] ); diff --git a/pandora_server/pandora_server.redhat.spec b/pandora_server/pandora_server.redhat.spec index 807e45af31..1d7f54cb67 100644 --- a/pandora_server/pandora_server.redhat.spec +++ b/pandora_server/pandora_server.redhat.spec @@ -3,7 +3,7 @@ # %define name pandorafms_server %define version 7.0NG.763 -%define release 220709 +%define release 220710 Summary: Pandora FMS Server Name: %{name} diff --git a/pandora_server/pandora_server.spec b/pandora_server/pandora_server.spec index e54cafca94..9475ebdc55 100644 --- a/pandora_server/pandora_server.spec +++ b/pandora_server/pandora_server.spec @@ -3,7 +3,7 @@ # %define name pandorafms_server %define version 7.0NG.763 -%define release 220709 +%define release 220710 Summary: Pandora FMS Server Name: %{name} diff --git a/pandora_server/pandora_server_installer b/pandora_server/pandora_server_installer index 903439cd2c..0d8c8b6ac6 100755 --- a/pandora_server/pandora_server_installer +++ b/pandora_server/pandora_server_installer @@ -9,7 +9,7 @@ # ********************************************************************** PI_VERSION="7.0NG.763" -PI_BUILD="220709" +PI_BUILD="220710" MODE=$1 if [ $# -gt 1 ]; then diff --git a/pandora_server/util/pandora_db.pl b/pandora_server/util/pandora_db.pl index bbb7b8fd6c..8a72e67055 100755 --- a/pandora_server/util/pandora_db.pl +++ b/pandora_server/util/pandora_db.pl @@ -35,7 +35,7 @@ use PandoraFMS::Config; use PandoraFMS::DB; # version: define current version -my $version = "7.0NG.763 Build 220709"; +my $version = "7.0NG.763 Build 220710"; # Pandora server configuration my %conf; diff --git a/pandora_server/util/pandora_manage.pl b/pandora_server/util/pandora_manage.pl index e7088266c3..c85b6788a2 100755 --- a/pandora_server/util/pandora_manage.pl +++ b/pandora_server/util/pandora_manage.pl @@ -36,7 +36,7 @@ use Encode::Locale; Encode::Locale::decode_argv; # version: define current version -my $version = "7.0NG.763 Build 220709"; +my $version = "7.0NG.763 Build 220710"; # save program name for logging my $progname = basename($0); From 92936b52678d1b10061082570b818e1bde0c7a6a Mon Sep 17 00:00:00 2001 From: artica Date: Mon, 11 Jul 2022 01:00:52 +0200 Subject: [PATCH 07/10] Auto-updated build strings. --- pandora_agents/unix/DEBIAN/control | 2 +- pandora_agents/unix/DEBIAN/make_deb_package.sh | 2 +- pandora_agents/unix/pandora_agent | 2 +- pandora_agents/unix/pandora_agent.redhat.spec | 2 +- pandora_agents/unix/pandora_agent.spec | 2 +- pandora_agents/unix/pandora_agent_installer | 2 +- pandora_agents/win32/installer/pandora.mpi | 2 +- pandora_agents/win32/pandora.cc | 2 +- pandora_agents/win32/versioninfo.rc | 2 +- pandora_console/DEBIAN/control | 2 +- pandora_console/DEBIAN/make_deb_package.sh | 2 +- pandora_console/include/config_process.php | 2 +- pandora_console/install.php | 2 +- pandora_console/pandora_console.redhat.spec | 2 +- pandora_console/pandora_console.rhel7.spec | 2 +- pandora_console/pandora_console.spec | 2 +- pandora_server/DEBIAN/control | 2 +- pandora_server/DEBIAN/make_deb_package.sh | 2 +- pandora_server/lib/PandoraFMS/Config.pm | 2 +- pandora_server/lib/PandoraFMS/PluginTools.pm | 2 +- pandora_server/pandora_server.redhat.spec | 2 +- pandora_server/pandora_server.spec | 2 +- pandora_server/pandora_server_installer | 2 +- pandora_server/util/pandora_db.pl | 2 +- pandora_server/util/pandora_manage.pl | 2 +- 25 files changed, 25 insertions(+), 25 deletions(-) diff --git a/pandora_agents/unix/DEBIAN/control b/pandora_agents/unix/DEBIAN/control index 91376e2ac8..37a0379a37 100644 --- a/pandora_agents/unix/DEBIAN/control +++ b/pandora_agents/unix/DEBIAN/control @@ -1,5 +1,5 @@ package: pandorafms-agent-unix -Version: 7.0NG.763-220710 +Version: 7.0NG.763-220711 Architecture: all Priority: optional Section: admin diff --git a/pandora_agents/unix/DEBIAN/make_deb_package.sh b/pandora_agents/unix/DEBIAN/make_deb_package.sh index b57c51499e..c795868e1a 100644 --- a/pandora_agents/unix/DEBIAN/make_deb_package.sh +++ b/pandora_agents/unix/DEBIAN/make_deb_package.sh @@ -14,7 +14,7 @@ # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. -pandora_version="7.0NG.763-220710" +pandora_version="7.0NG.763-220711" echo "Test if you has the tools for to make the packages." whereis dpkg-deb | cut -d":" -f2 | grep dpkg-deb > /dev/null diff --git a/pandora_agents/unix/pandora_agent b/pandora_agents/unix/pandora_agent index 8c9d1b4707..3879d48063 100755 --- a/pandora_agents/unix/pandora_agent +++ b/pandora_agents/unix/pandora_agent @@ -1015,7 +1015,7 @@ my $Sem = undef; my $ThreadSem = undef; use constant AGENT_VERSION => '7.0NG.763'; -use constant AGENT_BUILD => '220710'; +use constant AGENT_BUILD => '220711'; # Agent log default file size maximum and instances use constant DEFAULT_MAX_LOG_SIZE => 600000; diff --git a/pandora_agents/unix/pandora_agent.redhat.spec b/pandora_agents/unix/pandora_agent.redhat.spec index 5bc8346040..ed6f48a154 100644 --- a/pandora_agents/unix/pandora_agent.redhat.spec +++ b/pandora_agents/unix/pandora_agent.redhat.spec @@ -3,7 +3,7 @@ # %define name pandorafms_agent_unix %define version 7.0NG.763 -%define release 220710 +%define release 220711 Summary: Pandora FMS Linux agent, PERL version Name: %{name} diff --git a/pandora_agents/unix/pandora_agent.spec b/pandora_agents/unix/pandora_agent.spec index 8ea2dc6d63..f58395f235 100644 --- a/pandora_agents/unix/pandora_agent.spec +++ b/pandora_agents/unix/pandora_agent.spec @@ -3,7 +3,7 @@ # %define name pandorafms_agent_unix %define version 7.0NG.763 -%define release 220710 +%define release 220711 Summary: Pandora FMS Linux agent, PERL version Name: %{name} diff --git a/pandora_agents/unix/pandora_agent_installer b/pandora_agents/unix/pandora_agent_installer index 810f300b70..6cec404c45 100755 --- a/pandora_agents/unix/pandora_agent_installer +++ b/pandora_agents/unix/pandora_agent_installer @@ -10,7 +10,7 @@ # ********************************************************************** PI_VERSION="7.0NG.763" -PI_BUILD="220710" +PI_BUILD="220711" OS_NAME=`uname -s` FORCE=0 diff --git a/pandora_agents/win32/installer/pandora.mpi b/pandora_agents/win32/installer/pandora.mpi index c56d427f47..d1030aa8ee 100644 --- a/pandora_agents/win32/installer/pandora.mpi +++ b/pandora_agents/win32/installer/pandora.mpi @@ -186,7 +186,7 @@ UpgradeApplicationID {} Version -{220710} +{220711} ViewReadme {Yes} diff --git a/pandora_agents/win32/pandora.cc b/pandora_agents/win32/pandora.cc index 78037e6f8c..e6683a7db5 100644 --- a/pandora_agents/win32/pandora.cc +++ b/pandora_agents/win32/pandora.cc @@ -30,7 +30,7 @@ using namespace Pandora; using namespace Pandora_Strutils; #define PATH_SIZE _MAX_PATH+1 -#define PANDORA_VERSION ("7.0NG.763 Build 220710") +#define PANDORA_VERSION ("7.0NG.763 Build 220711") string pandora_path; string pandora_dir; diff --git a/pandora_agents/win32/versioninfo.rc b/pandora_agents/win32/versioninfo.rc index ffbe1f190e..a7ec8223f3 100644 --- a/pandora_agents/win32/versioninfo.rc +++ b/pandora_agents/win32/versioninfo.rc @@ -11,7 +11,7 @@ BEGIN VALUE "LegalCopyright", "Artica ST" VALUE "OriginalFilename", "PandoraAgent.exe" VALUE "ProductName", "Pandora FMS Windows Agent" - VALUE "ProductVersion", "(7.0NG.763(Build 220710))" + VALUE "ProductVersion", "(7.0NG.763(Build 220711))" VALUE "FileVersion", "1.0.0.0" END END diff --git a/pandora_console/DEBIAN/control b/pandora_console/DEBIAN/control index 0fce247ecf..aa6b26d18c 100644 --- a/pandora_console/DEBIAN/control +++ b/pandora_console/DEBIAN/control @@ -1,5 +1,5 @@ package: pandorafms-console -Version: 7.0NG.763-220710 +Version: 7.0NG.763-220711 Architecture: all Priority: optional Section: admin diff --git a/pandora_console/DEBIAN/make_deb_package.sh b/pandora_console/DEBIAN/make_deb_package.sh index 550af4f37d..2ed8047f36 100644 --- a/pandora_console/DEBIAN/make_deb_package.sh +++ b/pandora_console/DEBIAN/make_deb_package.sh @@ -14,7 +14,7 @@ # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. -pandora_version="7.0NG.763-220710" +pandora_version="7.0NG.763-220711" package_pear=0 package_pandora=1 diff --git a/pandora_console/include/config_process.php b/pandora_console/include/config_process.php index 582d2bb634..2aae5ffb75 100644 --- a/pandora_console/include/config_process.php +++ b/pandora_console/include/config_process.php @@ -20,7 +20,7 @@ /** * Pandora build version and version */ -$build_version = 'PC220710'; +$build_version = 'PC220711'; $pandora_version = 'v7.0NG.763'; // Do not overwrite default timezone set if defined. diff --git a/pandora_console/install.php b/pandora_console/install.php index e788140726..7ddb31e578 100644 --- a/pandora_console/install.php +++ b/pandora_console/install.php @@ -129,7 +129,7 @@
[ qw() ] ); diff --git a/pandora_server/pandora_server.redhat.spec b/pandora_server/pandora_server.redhat.spec index 1d7f54cb67..bf111e4449 100644 --- a/pandora_server/pandora_server.redhat.spec +++ b/pandora_server/pandora_server.redhat.spec @@ -3,7 +3,7 @@ # %define name pandorafms_server %define version 7.0NG.763 -%define release 220710 +%define release 220711 Summary: Pandora FMS Server Name: %{name} diff --git a/pandora_server/pandora_server.spec b/pandora_server/pandora_server.spec index 9475ebdc55..38fda2adc5 100644 --- a/pandora_server/pandora_server.spec +++ b/pandora_server/pandora_server.spec @@ -3,7 +3,7 @@ # %define name pandorafms_server %define version 7.0NG.763 -%define release 220710 +%define release 220711 Summary: Pandora FMS Server Name: %{name} diff --git a/pandora_server/pandora_server_installer b/pandora_server/pandora_server_installer index 0d8c8b6ac6..68d0df8604 100755 --- a/pandora_server/pandora_server_installer +++ b/pandora_server/pandora_server_installer @@ -9,7 +9,7 @@ # ********************************************************************** PI_VERSION="7.0NG.763" -PI_BUILD="220710" +PI_BUILD="220711" MODE=$1 if [ $# -gt 1 ]; then diff --git a/pandora_server/util/pandora_db.pl b/pandora_server/util/pandora_db.pl index 8a72e67055..d2f44bfb7a 100755 --- a/pandora_server/util/pandora_db.pl +++ b/pandora_server/util/pandora_db.pl @@ -35,7 +35,7 @@ use PandoraFMS::Config; use PandoraFMS::DB; # version: define current version -my $version = "7.0NG.763 Build 220710"; +my $version = "7.0NG.763 Build 220711"; # Pandora server configuration my %conf; diff --git a/pandora_server/util/pandora_manage.pl b/pandora_server/util/pandora_manage.pl index c85b6788a2..218593a41d 100755 --- a/pandora_server/util/pandora_manage.pl +++ b/pandora_server/util/pandora_manage.pl @@ -36,7 +36,7 @@ use Encode::Locale; Encode::Locale::decode_argv; # version: define current version -my $version = "7.0NG.763 Build 220710"; +my $version = "7.0NG.763 Build 220711"; # save program name for logging my $progname = basename($0); From d601ca88ca2054abec1a52c1ec2ab80327155c2f Mon Sep 17 00:00:00 2001 From: artica Date: Tue, 12 Jul 2022 01:00:19 +0200 Subject: [PATCH 08/10] Auto-updated build strings. --- pandora_agents/unix/DEBIAN/control | 2 +- pandora_agents/unix/DEBIAN/make_deb_package.sh | 2 +- pandora_agents/unix/pandora_agent | 2 +- pandora_agents/unix/pandora_agent.redhat.spec | 2 +- pandora_agents/unix/pandora_agent.spec | 2 +- pandora_agents/unix/pandora_agent_installer | 2 +- pandora_agents/win32/installer/pandora.mpi | 2 +- pandora_agents/win32/pandora.cc | 2 +- pandora_agents/win32/versioninfo.rc | 2 +- pandora_console/DEBIAN/control | 2 +- pandora_console/DEBIAN/make_deb_package.sh | 2 +- pandora_console/include/config_process.php | 2 +- pandora_console/install.php | 2 +- pandora_console/pandora_console.redhat.spec | 2 +- pandora_console/pandora_console.rhel7.spec | 2 +- pandora_console/pandora_console.spec | 2 +- pandora_server/DEBIAN/control | 2 +- pandora_server/DEBIAN/make_deb_package.sh | 2 +- pandora_server/lib/PandoraFMS/Config.pm | 2 +- pandora_server/lib/PandoraFMS/PluginTools.pm | 2 +- pandora_server/pandora_server.redhat.spec | 2 +- pandora_server/pandora_server.spec | 2 +- pandora_server/pandora_server_installer | 2 +- pandora_server/util/pandora_db.pl | 2 +- pandora_server/util/pandora_manage.pl | 2 +- 25 files changed, 25 insertions(+), 25 deletions(-) diff --git a/pandora_agents/unix/DEBIAN/control b/pandora_agents/unix/DEBIAN/control index 37a0379a37..bd1e6273cb 100644 --- a/pandora_agents/unix/DEBIAN/control +++ b/pandora_agents/unix/DEBIAN/control @@ -1,5 +1,5 @@ package: pandorafms-agent-unix -Version: 7.0NG.763-220711 +Version: 7.0NG.763-220712 Architecture: all Priority: optional Section: admin diff --git a/pandora_agents/unix/DEBIAN/make_deb_package.sh b/pandora_agents/unix/DEBIAN/make_deb_package.sh index c795868e1a..878701f279 100644 --- a/pandora_agents/unix/DEBIAN/make_deb_package.sh +++ b/pandora_agents/unix/DEBIAN/make_deb_package.sh @@ -14,7 +14,7 @@ # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. -pandora_version="7.0NG.763-220711" +pandora_version="7.0NG.763-220712" echo "Test if you has the tools for to make the packages." whereis dpkg-deb | cut -d":" -f2 | grep dpkg-deb > /dev/null diff --git a/pandora_agents/unix/pandora_agent b/pandora_agents/unix/pandora_agent index 3879d48063..d7237be6ce 100755 --- a/pandora_agents/unix/pandora_agent +++ b/pandora_agents/unix/pandora_agent @@ -1015,7 +1015,7 @@ my $Sem = undef; my $ThreadSem = undef; use constant AGENT_VERSION => '7.0NG.763'; -use constant AGENT_BUILD => '220711'; +use constant AGENT_BUILD => '220712'; # Agent log default file size maximum and instances use constant DEFAULT_MAX_LOG_SIZE => 600000; diff --git a/pandora_agents/unix/pandora_agent.redhat.spec b/pandora_agents/unix/pandora_agent.redhat.spec index ed6f48a154..8a447346ab 100644 --- a/pandora_agents/unix/pandora_agent.redhat.spec +++ b/pandora_agents/unix/pandora_agent.redhat.spec @@ -3,7 +3,7 @@ # %define name pandorafms_agent_unix %define version 7.0NG.763 -%define release 220711 +%define release 220712 Summary: Pandora FMS Linux agent, PERL version Name: %{name} diff --git a/pandora_agents/unix/pandora_agent.spec b/pandora_agents/unix/pandora_agent.spec index f58395f235..f380814505 100644 --- a/pandora_agents/unix/pandora_agent.spec +++ b/pandora_agents/unix/pandora_agent.spec @@ -3,7 +3,7 @@ # %define name pandorafms_agent_unix %define version 7.0NG.763 -%define release 220711 +%define release 220712 Summary: Pandora FMS Linux agent, PERL version Name: %{name} diff --git a/pandora_agents/unix/pandora_agent_installer b/pandora_agents/unix/pandora_agent_installer index 6cec404c45..df57f81a78 100755 --- a/pandora_agents/unix/pandora_agent_installer +++ b/pandora_agents/unix/pandora_agent_installer @@ -10,7 +10,7 @@ # ********************************************************************** PI_VERSION="7.0NG.763" -PI_BUILD="220711" +PI_BUILD="220712" OS_NAME=`uname -s` FORCE=0 diff --git a/pandora_agents/win32/installer/pandora.mpi b/pandora_agents/win32/installer/pandora.mpi index d1030aa8ee..1c65380333 100644 --- a/pandora_agents/win32/installer/pandora.mpi +++ b/pandora_agents/win32/installer/pandora.mpi @@ -186,7 +186,7 @@ UpgradeApplicationID {} Version -{220711} +{220712} ViewReadme {Yes} diff --git a/pandora_agents/win32/pandora.cc b/pandora_agents/win32/pandora.cc index e6683a7db5..426f21690e 100644 --- a/pandora_agents/win32/pandora.cc +++ b/pandora_agents/win32/pandora.cc @@ -30,7 +30,7 @@ using namespace Pandora; using namespace Pandora_Strutils; #define PATH_SIZE _MAX_PATH+1 -#define PANDORA_VERSION ("7.0NG.763 Build 220711") +#define PANDORA_VERSION ("7.0NG.763 Build 220712") string pandora_path; string pandora_dir; diff --git a/pandora_agents/win32/versioninfo.rc b/pandora_agents/win32/versioninfo.rc index a7ec8223f3..eb972bb494 100644 --- a/pandora_agents/win32/versioninfo.rc +++ b/pandora_agents/win32/versioninfo.rc @@ -11,7 +11,7 @@ BEGIN VALUE "LegalCopyright", "Artica ST" VALUE "OriginalFilename", "PandoraAgent.exe" VALUE "ProductName", "Pandora FMS Windows Agent" - VALUE "ProductVersion", "(7.0NG.763(Build 220711))" + VALUE "ProductVersion", "(7.0NG.763(Build 220712))" VALUE "FileVersion", "1.0.0.0" END END diff --git a/pandora_console/DEBIAN/control b/pandora_console/DEBIAN/control index aa6b26d18c..6e81403f87 100644 --- a/pandora_console/DEBIAN/control +++ b/pandora_console/DEBIAN/control @@ -1,5 +1,5 @@ package: pandorafms-console -Version: 7.0NG.763-220711 +Version: 7.0NG.763-220712 Architecture: all Priority: optional Section: admin diff --git a/pandora_console/DEBIAN/make_deb_package.sh b/pandora_console/DEBIAN/make_deb_package.sh index 2ed8047f36..3a24309700 100644 --- a/pandora_console/DEBIAN/make_deb_package.sh +++ b/pandora_console/DEBIAN/make_deb_package.sh @@ -14,7 +14,7 @@ # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. -pandora_version="7.0NG.763-220711" +pandora_version="7.0NG.763-220712" package_pear=0 package_pandora=1 diff --git a/pandora_console/include/config_process.php b/pandora_console/include/config_process.php index 2aae5ffb75..b9c6e35c49 100644 --- a/pandora_console/include/config_process.php +++ b/pandora_console/include/config_process.php @@ -20,7 +20,7 @@ /** * Pandora build version and version */ -$build_version = 'PC220711'; +$build_version = 'PC220712'; $pandora_version = 'v7.0NG.763'; // Do not overwrite default timezone set if defined. diff --git a/pandora_console/install.php b/pandora_console/install.php index 7ddb31e578..ca55df12b7 100644 --- a/pandora_console/install.php +++ b/pandora_console/install.php @@ -129,7 +129,7 @@
[ qw() ] ); diff --git a/pandora_server/pandora_server.redhat.spec b/pandora_server/pandora_server.redhat.spec index bf111e4449..7d1583d591 100644 --- a/pandora_server/pandora_server.redhat.spec +++ b/pandora_server/pandora_server.redhat.spec @@ -3,7 +3,7 @@ # %define name pandorafms_server %define version 7.0NG.763 -%define release 220711 +%define release 220712 Summary: Pandora FMS Server Name: %{name} diff --git a/pandora_server/pandora_server.spec b/pandora_server/pandora_server.spec index 38fda2adc5..464df38586 100644 --- a/pandora_server/pandora_server.spec +++ b/pandora_server/pandora_server.spec @@ -3,7 +3,7 @@ # %define name pandorafms_server %define version 7.0NG.763 -%define release 220711 +%define release 220712 Summary: Pandora FMS Server Name: %{name} diff --git a/pandora_server/pandora_server_installer b/pandora_server/pandora_server_installer index 68d0df8604..cdac4f4da0 100755 --- a/pandora_server/pandora_server_installer +++ b/pandora_server/pandora_server_installer @@ -9,7 +9,7 @@ # ********************************************************************** PI_VERSION="7.0NG.763" -PI_BUILD="220711" +PI_BUILD="220712" MODE=$1 if [ $# -gt 1 ]; then diff --git a/pandora_server/util/pandora_db.pl b/pandora_server/util/pandora_db.pl index d2f44bfb7a..ef4509e7d0 100755 --- a/pandora_server/util/pandora_db.pl +++ b/pandora_server/util/pandora_db.pl @@ -35,7 +35,7 @@ use PandoraFMS::Config; use PandoraFMS::DB; # version: define current version -my $version = "7.0NG.763 Build 220711"; +my $version = "7.0NG.763 Build 220712"; # Pandora server configuration my %conf; diff --git a/pandora_server/util/pandora_manage.pl b/pandora_server/util/pandora_manage.pl index 218593a41d..0ed23d8fc4 100755 --- a/pandora_server/util/pandora_manage.pl +++ b/pandora_server/util/pandora_manage.pl @@ -36,7 +36,7 @@ use Encode::Locale; Encode::Locale::decode_argv; # version: define current version -my $version = "7.0NG.763 Build 220711"; +my $version = "7.0NG.763 Build 220712"; # save program name for logging my $progname = basename($0); From c3e19c489c8a8782cf157c00895fe7d4ae8aad2b Mon Sep 17 00:00:00 2001 From: alejandro Date: Tue, 12 Jul 2022 15:24:58 +0200 Subject: [PATCH 09/10] editing plugin cisco no enterprise --- pandora_plugins/cisco_ipsla/pandora_ipsla.sh | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/pandora_plugins/cisco_ipsla/pandora_ipsla.sh b/pandora_plugins/cisco_ipsla/pandora_ipsla.sh index 729bf40828..1919d80c7c 100755 --- a/pandora_plugins/cisco_ipsla/pandora_ipsla.sh +++ b/pandora_plugins/cisco_ipsla/pandora_ipsla.sh @@ -21,7 +21,7 @@ function help { echo -e "\t\t-A " echo -e "\t\t-x " echo -e "\t\t-X " - echo -e "\t\t-g " + echo -e "\t\t-g " echo -e "\t\t-m \n" echo -e "Available Modules list: \n" echo -e "\tICPIF - Calculated Planning Impairment Factor for specified tag" @@ -82,7 +82,7 @@ function show_tags { fi fi - cat $TAG_TABLE_CACHE | awk '{ print $2 }' | tr -d "\"" | grep -ve '^$' + cat $TAG_TABLE_CACHE exit } @@ -118,9 +118,8 @@ function get_index { # This function requires two arguments. MODULE_TYPE TAG function get_module { MODULE_TYPE=$1 - TAG=$2 update_tags - INDICE=`get_index $TAG` + INDICE=$2 if [ $version != "3" ] @@ -725,11 +724,11 @@ while getopts ":hc:t:v:l:u:a:A:x:X:sm:g:" optname done # Execution -[ "$SHOWTAGS" ] && echo "Showing avaliables ipsla tags for the device $TARGET" && show_tags +[ "$SHOWTAGS" ] && echo "Showing avaliables ipsla tags for the device $TARGET and OID 1.3.6.1.4.1.9.9.42.1.2.1.1.3" && show_tags [ -z "$TARGET" ] && echo "Error missing target ip definition please use -t to difine it or -h to see help" && exit 1 [ -z "$MODULE" ] && echo "Error missing module definition please use -m to difine it or -h to see help" && exit 1 -[ -z "$TAG" ] && echo "Error missing tag definition please use -g to difine it or -h to see help" && exit 1 +[ -z "$TAG" ] && echo "Error missing id definition please use -g to difine it or -h to see help" && exit 1 [ -z "$version" ] && echo "Error missing snmp version definition please use -v to difine it or -h to see help" && exit 1 From 85c66a390cccd864f149bf5596506420f5ebb0ef Mon Sep 17 00:00:00 2001 From: artica Date: Wed, 13 Jul 2022 01:00:19 +0200 Subject: [PATCH 10/10] Auto-updated build strings. --- pandora_agents/unix/DEBIAN/control | 2 +- pandora_agents/unix/DEBIAN/make_deb_package.sh | 2 +- pandora_agents/unix/pandora_agent | 2 +- pandora_agents/unix/pandora_agent.redhat.spec | 2 +- pandora_agents/unix/pandora_agent.spec | 2 +- pandora_agents/unix/pandora_agent_installer | 2 +- pandora_agents/win32/installer/pandora.mpi | 2 +- pandora_agents/win32/pandora.cc | 2 +- pandora_agents/win32/versioninfo.rc | 2 +- pandora_console/DEBIAN/control | 2 +- pandora_console/DEBIAN/make_deb_package.sh | 2 +- pandora_console/include/config_process.php | 2 +- pandora_console/install.php | 2 +- pandora_console/pandora_console.redhat.spec | 2 +- pandora_console/pandora_console.rhel7.spec | 2 +- pandora_console/pandora_console.spec | 2 +- pandora_server/DEBIAN/control | 2 +- pandora_server/DEBIAN/make_deb_package.sh | 2 +- pandora_server/lib/PandoraFMS/Config.pm | 2 +- pandora_server/lib/PandoraFMS/PluginTools.pm | 2 +- pandora_server/pandora_server.redhat.spec | 2 +- pandora_server/pandora_server.spec | 2 +- pandora_server/pandora_server_installer | 2 +- pandora_server/util/pandora_db.pl | 2 +- pandora_server/util/pandora_manage.pl | 2 +- 25 files changed, 25 insertions(+), 25 deletions(-) diff --git a/pandora_agents/unix/DEBIAN/control b/pandora_agents/unix/DEBIAN/control index bd1e6273cb..0ce4231392 100644 --- a/pandora_agents/unix/DEBIAN/control +++ b/pandora_agents/unix/DEBIAN/control @@ -1,5 +1,5 @@ package: pandorafms-agent-unix -Version: 7.0NG.763-220712 +Version: 7.0NG.763-220713 Architecture: all Priority: optional Section: admin diff --git a/pandora_agents/unix/DEBIAN/make_deb_package.sh b/pandora_agents/unix/DEBIAN/make_deb_package.sh index 878701f279..d3636bdcc7 100644 --- a/pandora_agents/unix/DEBIAN/make_deb_package.sh +++ b/pandora_agents/unix/DEBIAN/make_deb_package.sh @@ -14,7 +14,7 @@ # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. -pandora_version="7.0NG.763-220712" +pandora_version="7.0NG.763-220713" echo "Test if you has the tools for to make the packages." whereis dpkg-deb | cut -d":" -f2 | grep dpkg-deb > /dev/null diff --git a/pandora_agents/unix/pandora_agent b/pandora_agents/unix/pandora_agent index d7237be6ce..0d5980ebc8 100755 --- a/pandora_agents/unix/pandora_agent +++ b/pandora_agents/unix/pandora_agent @@ -1015,7 +1015,7 @@ my $Sem = undef; my $ThreadSem = undef; use constant AGENT_VERSION => '7.0NG.763'; -use constant AGENT_BUILD => '220712'; +use constant AGENT_BUILD => '220713'; # Agent log default file size maximum and instances use constant DEFAULT_MAX_LOG_SIZE => 600000; diff --git a/pandora_agents/unix/pandora_agent.redhat.spec b/pandora_agents/unix/pandora_agent.redhat.spec index 8a447346ab..46588f34ad 100644 --- a/pandora_agents/unix/pandora_agent.redhat.spec +++ b/pandora_agents/unix/pandora_agent.redhat.spec @@ -3,7 +3,7 @@ # %define name pandorafms_agent_unix %define version 7.0NG.763 -%define release 220712 +%define release 220713 Summary: Pandora FMS Linux agent, PERL version Name: %{name} diff --git a/pandora_agents/unix/pandora_agent.spec b/pandora_agents/unix/pandora_agent.spec index f380814505..721890a900 100644 --- a/pandora_agents/unix/pandora_agent.spec +++ b/pandora_agents/unix/pandora_agent.spec @@ -3,7 +3,7 @@ # %define name pandorafms_agent_unix %define version 7.0NG.763 -%define release 220712 +%define release 220713 Summary: Pandora FMS Linux agent, PERL version Name: %{name} diff --git a/pandora_agents/unix/pandora_agent_installer b/pandora_agents/unix/pandora_agent_installer index df57f81a78..690c79a737 100755 --- a/pandora_agents/unix/pandora_agent_installer +++ b/pandora_agents/unix/pandora_agent_installer @@ -10,7 +10,7 @@ # ********************************************************************** PI_VERSION="7.0NG.763" -PI_BUILD="220712" +PI_BUILD="220713" OS_NAME=`uname -s` FORCE=0 diff --git a/pandora_agents/win32/installer/pandora.mpi b/pandora_agents/win32/installer/pandora.mpi index 1c65380333..a01d2efe84 100644 --- a/pandora_agents/win32/installer/pandora.mpi +++ b/pandora_agents/win32/installer/pandora.mpi @@ -186,7 +186,7 @@ UpgradeApplicationID {} Version -{220712} +{220713} ViewReadme {Yes} diff --git a/pandora_agents/win32/pandora.cc b/pandora_agents/win32/pandora.cc index 426f21690e..8ffeb93373 100644 --- a/pandora_agents/win32/pandora.cc +++ b/pandora_agents/win32/pandora.cc @@ -30,7 +30,7 @@ using namespace Pandora; using namespace Pandora_Strutils; #define PATH_SIZE _MAX_PATH+1 -#define PANDORA_VERSION ("7.0NG.763 Build 220712") +#define PANDORA_VERSION ("7.0NG.763 Build 220713") string pandora_path; string pandora_dir; diff --git a/pandora_agents/win32/versioninfo.rc b/pandora_agents/win32/versioninfo.rc index eb972bb494..bcbbd4d566 100644 --- a/pandora_agents/win32/versioninfo.rc +++ b/pandora_agents/win32/versioninfo.rc @@ -11,7 +11,7 @@ BEGIN VALUE "LegalCopyright", "Artica ST" VALUE "OriginalFilename", "PandoraAgent.exe" VALUE "ProductName", "Pandora FMS Windows Agent" - VALUE "ProductVersion", "(7.0NG.763(Build 220712))" + VALUE "ProductVersion", "(7.0NG.763(Build 220713))" VALUE "FileVersion", "1.0.0.0" END END diff --git a/pandora_console/DEBIAN/control b/pandora_console/DEBIAN/control index 6e81403f87..fc1af402dc 100644 --- a/pandora_console/DEBIAN/control +++ b/pandora_console/DEBIAN/control @@ -1,5 +1,5 @@ package: pandorafms-console -Version: 7.0NG.763-220712 +Version: 7.0NG.763-220713 Architecture: all Priority: optional Section: admin diff --git a/pandora_console/DEBIAN/make_deb_package.sh b/pandora_console/DEBIAN/make_deb_package.sh index 3a24309700..1ddd4cad47 100644 --- a/pandora_console/DEBIAN/make_deb_package.sh +++ b/pandora_console/DEBIAN/make_deb_package.sh @@ -14,7 +14,7 @@ # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. -pandora_version="7.0NG.763-220712" +pandora_version="7.0NG.763-220713" package_pear=0 package_pandora=1 diff --git a/pandora_console/include/config_process.php b/pandora_console/include/config_process.php index b9c6e35c49..e6a6249388 100644 --- a/pandora_console/include/config_process.php +++ b/pandora_console/include/config_process.php @@ -20,7 +20,7 @@ /** * Pandora build version and version */ -$build_version = 'PC220712'; +$build_version = 'PC220713'; $pandora_version = 'v7.0NG.763'; // Do not overwrite default timezone set if defined. diff --git a/pandora_console/install.php b/pandora_console/install.php index ca55df12b7..d15258be3c 100644 --- a/pandora_console/install.php +++ b/pandora_console/install.php @@ -129,7 +129,7 @@
[ qw() ] ); diff --git a/pandora_server/pandora_server.redhat.spec b/pandora_server/pandora_server.redhat.spec index 7d1583d591..c924852194 100644 --- a/pandora_server/pandora_server.redhat.spec +++ b/pandora_server/pandora_server.redhat.spec @@ -3,7 +3,7 @@ # %define name pandorafms_server %define version 7.0NG.763 -%define release 220712 +%define release 220713 Summary: Pandora FMS Server Name: %{name} diff --git a/pandora_server/pandora_server.spec b/pandora_server/pandora_server.spec index 464df38586..6b5071bfbb 100644 --- a/pandora_server/pandora_server.spec +++ b/pandora_server/pandora_server.spec @@ -3,7 +3,7 @@ # %define name pandorafms_server %define version 7.0NG.763 -%define release 220712 +%define release 220713 Summary: Pandora FMS Server Name: %{name} diff --git a/pandora_server/pandora_server_installer b/pandora_server/pandora_server_installer index cdac4f4da0..590eaaa41c 100755 --- a/pandora_server/pandora_server_installer +++ b/pandora_server/pandora_server_installer @@ -9,7 +9,7 @@ # ********************************************************************** PI_VERSION="7.0NG.763" -PI_BUILD="220712" +PI_BUILD="220713" MODE=$1 if [ $# -gt 1 ]; then diff --git a/pandora_server/util/pandora_db.pl b/pandora_server/util/pandora_db.pl index ef4509e7d0..7407a09950 100755 --- a/pandora_server/util/pandora_db.pl +++ b/pandora_server/util/pandora_db.pl @@ -35,7 +35,7 @@ use PandoraFMS::Config; use PandoraFMS::DB; # version: define current version -my $version = "7.0NG.763 Build 220712"; +my $version = "7.0NG.763 Build 220713"; # Pandora server configuration my %conf; diff --git a/pandora_server/util/pandora_manage.pl b/pandora_server/util/pandora_manage.pl index 0ed23d8fc4..a13bd9b85b 100755 --- a/pandora_server/util/pandora_manage.pl +++ b/pandora_server/util/pandora_manage.pl @@ -36,7 +36,7 @@ use Encode::Locale; Encode::Locale::decode_argv; # version: define current version -my $version = "7.0NG.763 Build 220712"; +my $version = "7.0NG.763 Build 220713"; # save program name for logging my $progname = basename($0);