Make ADMINISABSENTMINDED logic clearer

git-svn-id: https://shorewall.svn.sourceforge.net/svnroot/shorewall/trunk@5722 fbd18981-670d-0410-9b5c-8dc0c1a9a2bb
This commit is contained in:
teastep 2007-03-28 14:20:46 +00:00
parent c13b504c14
commit e93ecfd0e6

View File

@ -397,27 +397,27 @@ stop_firewall() {
"done\n"
);
}
} elsif ( ! $config{ADMINISABSENTMINDED} ) {
} elsif ( $config{ADMINISABSENTMINDED} ) {
emitj( 'for chain in INPUT FORWARD; do',
' setpolicy $chain DROP',
'done',
'',
'setpolicy OUTPUT ACCEPT',
'',
'deleteallchains',
'',
'for chain in INPUT FORWARD; do',
' setcontinue $chain',
"done\n",
);
} else {
emitj( 'for chain in INPUT OUTPUT FORWARD; do',
' setpolicy $chain DROP',
'done',
'',
"deleteallchains\n"
);
} else {
emitj( 'for chain in INPUT FORWARD; do',
' setpolicy $chain DROP',
'done',
'',
'setpolicy OUTPUT ACCEPT',
'',
'deleteallchains',
'',
'for chain in INPUT FORWARD; do',
' setcontinue $chain',
"done\n",
);
}
}
process_routestopped;