changed the occurence of path /etc/pf.conf in the rdr.sh script for reading it as a variable from the bastille configuration.
This commit is contained in:
@@ -11,6 +11,9 @@ bastille_releasesdir="${bastille_prefix}/releases" ## default
|
|||||||
bastille_templatesdir="${bastille_prefix}/templates" ## default: "${bastille_prefix}/templates"
|
bastille_templatesdir="${bastille_prefix}/templates" ## default: "${bastille_prefix}/templates"
|
||||||
bastille_logsdir="/var/log/bastille" ## default: "/var/log/bastille"
|
bastille_logsdir="/var/log/bastille" ## default: "/var/log/bastille"
|
||||||
|
|
||||||
|
## pf configuration path
|
||||||
|
bastille_pf_conf="/etc/pf.conf" ## default: "/etc/pf.conf"
|
||||||
|
|
||||||
## bastille scripts directory (assumed by bastille pkg)
|
## bastille scripts directory (assumed by bastille pkg)
|
||||||
bastille_sharedir="/usr/local/share/bastille" ## default: "/usr/local/share/bastille"
|
bastille_sharedir="/usr/local/share/bastille" ## default: "/usr/local/share/bastille"
|
||||||
|
|
||||||
|
|||||||
@@ -88,7 +88,7 @@ check_jail_validity() {
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
# Check if ext_if is defined in pf.conf
|
# Check if ext_if is defined in pf.conf
|
||||||
EXT_IF=$(grep "^[[:space:]]*${bastille_network_pf_ext_if}[[:space:]]*=" /etc/pf.conf)
|
EXT_IF=$(grep "^[[:space:]]*${bastille_network_pf_ext_if}[[:space:]]*=" ${bastille_pf_conf})
|
||||||
if [ -z "${EXT_IF}" ]; then
|
if [ -z "${EXT_IF}" ]; then
|
||||||
error_exit "bastille_network_pf_ext_if (${bastille_network_pf_ext_if}) not defined in pf.conf"
|
error_exit "bastille_network_pf_ext_if (${bastille_network_pf_ext_if}) not defined in pf.conf"
|
||||||
fi
|
fi
|
||||||
|
|||||||
Reference in New Issue
Block a user