Skip to content

Commit

Permalink
Dropping support for ULOG.
Browse files Browse the repository at this point in the history
  • Loading branch information
Andrew Benson committed Nov 20, 2015
1 parent 46215eb commit 295aa37
Showing 1 changed file with 5 additions and 22 deletions.
27 changes: 5 additions & 22 deletions hostfw.sh
Original file line number Diff line number Diff line change
Expand Up @@ -194,29 +194,12 @@ set_policy()
log_exceptions()
{
if [ $LOGEXCEPT -eq 1 ]; then
logger=""
lsmod | grep -q "ipt_LOG"
if [ $? -eq 0 ]; then
logger="LOG"
fi
lsmod | grep -q "xt_LOG"
if [ $? -eq 0 ]; then
logger="LOG"
fi
lsmod | grep -q "ipt_ULOG"
if [ $? -eq 0 ]; then
logger="ULOG"
fi
if [ -z $logger ]; then
echo "Will not log; Please configure a valid logging method."
else
if [ $PRINTSTATUS -eq 1 ]; then
echo "Logging exceptions..."
fi
$IPTABLES -A INPUT -m limit --limit 5/min -j $logger
$IPTABLES -A OUTPUT -m limit --limit 5/min -j $logger
$IPTABLES -A FORWARD -m limit --limit 5/min -j $logger
if [ $PRINTSTATUS -eq 1 ]; then
echo "Logging exceptions..."
fi
$IPTABLES -A INPUT -m limit --limit 5/min -j LOG
$IPTABLES -A OUTPUT -m limit --limit 5/min -j LOG
$IPTABLES -A FORWARD -m limit --limit 5/min -j LOG
fi
}

Expand Down

0 comments on commit 295aa37

Please sign in to comment.