ls -l /etc/rc.local -rwxr-xr-x 1 root root 843 2012-09-27 17:02 /etc/rc.local /etc/rc.local #!/bin/sh -e # # rc.local # # This script is executed at the end of each multiuser runlevel. # Make sure that the script will "exit 0" on success or any other # value on error. # # In order to enable or disable this script just change the execution # bits. # # By default this script does nothing. #Flush of all rules iptables -F #permit SSH access iptables -A INPUT -p tcp --dport 22 -j ACCEPT #Permit local traffic iptables -A INPUT -p tcp -s 127.0.0.1/8 -j ACCEPT iptables -A INPUT -p tcp -s 192.168.0.98 -j ACCEPT #Permit access from you workstation iptables -A INPUT -p tcp -s 192.168.0.98 -j ACCEPT #Block all Zimbra ports for incoming traffic iptables -A INPUT -i eth0 -p tcp -m multiport --dport 25,80,110,143,443,993,995 -j REJECT #Block all Zimbra outgoing traffic iptables -A OUTPUT -o eth0 -p tcp --dport 25 -j REJECT exit 0