mirror of
https://gitlab.com/shorewall/code.git
synced 2024-11-09 01:04:06 +01:00
Fix maclist verification
git-svn-id: https://shorewall.svn.sourceforge.net/svnroot/shorewall/trunk@3363 fbd18981-670d-0410-9b5c-8dc0c1a9a2bb
This commit is contained in:
parent
51f53236ec
commit
dfdbdff286
@ -2369,6 +2369,7 @@ setup_mac_lists() {
|
||||
addresses="$mac"
|
||||
mac="$interface"
|
||||
interface="$disposition"
|
||||
disposition=ACCEPT
|
||||
target=RETURN
|
||||
;;
|
||||
esac
|
||||
|
@ -2590,6 +2590,8 @@ setup_mac_lists() {
|
||||
while read disposition interface mac addresses; do
|
||||
expandv disposition interface mac addresses
|
||||
|
||||
level=
|
||||
|
||||
case $disposition in
|
||||
ACCEPT:*)
|
||||
level=${disposition#*:}
|
||||
@ -2597,7 +2599,7 @@ setup_mac_lists() {
|
||||
target=RETURN
|
||||
;;
|
||||
ACCEPT)
|
||||
disposition=RETURN
|
||||
target=RETURN
|
||||
;;
|
||||
REJECT:*)
|
||||
[ $MACLIST_TABLE = mangle ] && fatal_error "DISPOSITION = REJECT is incompatible with MACLIST_TABLE=mangle"
|
||||
@ -2606,6 +2608,7 @@ setup_mac_lists() {
|
||||
;;
|
||||
REJECT)
|
||||
[ $MACLIST_TABLE = mangle ] && fatal_error "DISPOSITION = REJECT is incompatible with MACLIST_TABLE=mangle"
|
||||
target=reject
|
||||
;;
|
||||
DROP:*)
|
||||
level=${disposition#*:}
|
||||
@ -2613,12 +2616,14 @@ setup_mac_lists() {
|
||||
target=DROP
|
||||
;;
|
||||
DROP)
|
||||
target=DROP
|
||||
;;
|
||||
*)
|
||||
addresses="$mac"
|
||||
mac="$interface"
|
||||
interface="$disposition"
|
||||
disposition=RETURN
|
||||
disposition=ACCEPT
|
||||
target=RETURN
|
||||
;;
|
||||
esac
|
||||
|
||||
@ -2643,7 +2648,7 @@ setup_mac_lists() {
|
||||
if [ -z "$addresses" ]; then
|
||||
fatal_error "You must specify a MAC address or an IP address"
|
||||
else
|
||||
mac=
|
||||
maclist=
|
||||
fi
|
||||
else
|
||||
macpart=$(mac_match $mac)
|
||||
|
@ -874,13 +874,12 @@ reload_command() {
|
||||
esac
|
||||
|
||||
export NOROUTES
|
||||
export PROGRAM=Yes
|
||||
|
||||
[ -n "$nolock" ] || mutex_on
|
||||
|
||||
progress_message3 "Compiling..."
|
||||
|
||||
export PROGRAM=Yes
|
||||
|
||||
if $SHOREWALL_SHELL /usr/share/shorewall/compiler $debugging $nolock compile /var/lib/shorewall/.reload; then
|
||||
progress_message3 "Installing..."
|
||||
/var/lib/shorewall/.reload reload
|
||||
|
Loading…
Reference in New Issue
Block a user