#!/bin/bash function version_gt() { test "$(printf '%s\n' "$@" | sort -V | head -n 1)" != "$1"; } IP="$1" if [ "$IP" == "" ]; then echo echo -e "\033${TERM_COLOR_LIGHT_RED}Usage: $FUNCNAME \033${TERM_COLOR_NORMAL}" echo cat <&1 | grep -v "$IP is not banned"; else iptables -D f2b-$JAIL -s $IP -j DROP 2>&1 | grep -v 'iptables: Bad rule' && sleep 5 || echo "$IP is not banned"; fi done exit 0