Do you have an iptables scripts? if yes, just put your rules for port you want to open first
(example: $IPTABLES -A INPUT -s 0/0 --dport http -j ACCEPT)
then at the end of your script add a command like :
( $IPTABLES -A INPUT -s/s -j DROP )
iptables uses the first applicable rules it can find, so if there is no rules about "another port" than this one will be use as default.
|