Fixed UFW defaults for Centos
Fixed selinux ssh port
This commit is contained in:
@@ -1,7 +1,20 @@
|
|||||||
|
##--------------------##
|
||||||
|
# (Centos) SeLinux #
|
||||||
|
##--------------------##
|
||||||
|
if [ "$shortdist" = "cent8" ]; then
|
||||||
|
semanage port -a -t ssh_port_t -p tcp 4242
|
||||||
|
fi
|
||||||
|
|
||||||
##-------##
|
##-------##
|
||||||
# UFW #
|
# UFW #
|
||||||
##-------##
|
##-------##
|
||||||
|
|
||||||
|
if [ "$shortdist" = "cent8" ]; then
|
||||||
|
sed -i -e '/tuple/d' -e '/dapp/d' /usr/share/ufw/iptables/user.rules
|
||||||
|
sed -i -e '/tuple/d' -e '/dapp/d' /usr/share/ufw/iptables/user6.rules
|
||||||
|
echo "y" | ufw reset > $OUTPUT 2>&1
|
||||||
|
fi
|
||||||
|
|
||||||
sed -i '/IPV6=/c\IPV6=yes' /etc/default/ufw
|
sed -i '/IPV6=/c\IPV6=yes' /etc/default/ufw
|
||||||
ufw default deny incoming > $OUTPUT 2>&1
|
ufw default deny incoming > $OUTPUT 2>&1
|
||||||
ufw default allow outgoing > $OUTPUT 2>&1
|
ufw default allow outgoing > $OUTPUT 2>&1
|
||||||
|
|||||||
@@ -1 +1 @@
|
|||||||
cronie
|
cronie policycoreutils-python-utils
|
||||||
@@ -1,4 +1,3 @@
|
|||||||
echo "DEBUG Start preconf"
|
|
||||||
if [ "$shortdist" = "ubu1804" ] || [ "$osrel" = "ubu2004" ] || [ "$osrel" = "deb10" ] ; then
|
if [ "$shortdist" = "ubu1804" ] || [ "$osrel" = "ubu2004" ] || [ "$osrel" = "deb10" ] ; then
|
||||||
########################
|
########################
|
||||||
# Debian/Ubunbtu #
|
# Debian/Ubunbtu #
|
||||||
@@ -36,7 +35,6 @@ elif [ "$shortdist" = "cent8" ]; then
|
|||||||
################
|
################
|
||||||
# Centos #
|
# Centos #
|
||||||
################
|
################
|
||||||
echo "DEBUG running cent8 preconf"
|
|
||||||
##--------------##
|
##--------------##
|
||||||
# Repositories #
|
# Repositories #
|
||||||
##--------------##
|
##--------------##
|
||||||
|
|||||||
Reference in New Issue
Block a user