|
|
@ -46,6 +46,9 @@ if [ ! -e "$rules" ]; then
|
|
|
|
exit
|
|
|
|
exit
|
|
|
|
fi
|
|
|
|
fi
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if [ -f /etc/redhat-release ]; then
|
|
|
|
|
|
|
|
conntrack='yes'
|
|
|
|
|
|
|
|
else
|
|
|
|
# Checking conntrack module avaiabilty
|
|
|
|
# Checking conntrack module avaiabilty
|
|
|
|
$modprobe nf_conntrack > /dev/null 2>&1
|
|
|
|
$modprobe nf_conntrack > /dev/null 2>&1
|
|
|
|
if [ $? -ne 0 ]; then
|
|
|
|
if [ $? -ne 0 ]; then
|
|
|
@ -54,11 +57,16 @@ if [ $? -ne 0 ]; then
|
|
|
|
conntrack='no'
|
|
|
|
conntrack='no'
|
|
|
|
fi
|
|
|
|
fi
|
|
|
|
fi
|
|
|
|
fi
|
|
|
|
|
|
|
|
fi
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if [ -f /etc/redhat-release ]; then
|
|
|
|
|
|
|
|
conntrack_ftp='yes'
|
|
|
|
|
|
|
|
else
|
|
|
|
$modprobe nf_conntrack_ftp > /dev/null 2>&1
|
|
|
|
$modprobe nf_conntrack_ftp > /dev/null 2>&1
|
|
|
|
if [ $? -ne 0 ]; then
|
|
|
|
if [ $? -ne 0 ]; then
|
|
|
|
conntrack_ftp='no'
|
|
|
|
conntrack_ftp='no'
|
|
|
|
fi
|
|
|
|
fi
|
|
|
|
|
|
|
|
fi
|
|
|
|
|
|
|
|
|
|
|
|
# Checking custom OpenSSH port
|
|
|
|
# Checking custom OpenSSH port
|
|
|
|
sshport=$(grep '^Port ' /etc/ssh/sshd_config | head -1 | cut -d ' ' -f 2)
|
|
|
|
sshport=$(grep '^Port ' /etc/ssh/sshd_config | head -1 | cut -d ' ' -f 2)
|
|
|
|