How to open only tcp-22 and close other ports in iptables 12 # iptables -t filter -A INPUT -p tcp --dport 22 -j ACCEPT# iptables -t filter -A INPUT -j DROP