CHips L MINI SHELL

CHips L pro

Current Path : /opt/zabbix_scripts/
Upload File :
Current File : //opt/zabbix_scripts/check_ips.sh

#!/bin/bash

declare IPLIST=$(curl --silent -L http://chkips.init3.com/)

CHK=$(/sbin/iptables -nL |grep -E $IPLIST|grep DROP|awk '{print $4}'| tr '\n' '|')

if [ -z "$CHK" ]
then
        RET=${STATE_OK}
        DATA="OK"
else
        RET=${STATE_CRITICAL}
        DATA="${CHK}"
fi

echo "${DATA}"
exit ${RET}

Copyright 2K16 - 2K18 Indonesian Hacker Rulez