3 # Copyright 2013-2016 by Jan Vales <jan@jvales.net> (Someone <someone@somenet.org>)
4 # send me your changes. credit author(s). do not publish. share alike.
5 # to be done: find a suitable licence text.
7 # Script to apply new xtable rules.
10 cat iptables.rules.* > iptables.new.tmp
12 /sbin/iptables-save > iptables.old.tmp
14 echo "applying new rules ..."
15 /sbin/iptables-restore < iptables.new.tmp
16 mkdir -p /media/sf_vmshare/_orga/read_only_info
17 cat iptables.new.tmp > /media/sf_vmshare/_orga/read_only_info/iptables.rules
21 echo "LOCK-OUT-PREVENTION will revert to old rules in 30 sec. ctrl + c to abort."
22 echo "ctrl + c to abort."
25 echo "reverting to old rules ..."
26 /sbin/iptables-restore < iptables.old.tmp
27 cat iptables.old.tmp > /media/sf_vmshare/_orga/read_only_info/iptable.rules