If I add this line to my iptables
:
-A INPUT -s /32 -i tcp -p tcp -m tcp --dport 22 -j DROP
I get the error:
iptables-restore v1.4.14: host/network
' not found`
When running:
sudo iptables-restore /etc/network/iptables
Is there a problem with that line? If not, I will post the rest of the iptable configuration.
complete configuration:
*filter
:INPUT DROP [23:2584]
:FORWARD ACCEPT [0:0]
:OUTPUT ACCEPT [1161:105847]
-A INPUT -i lo -j ACCEPT
-A INPUT -i eth0 -p tcp -m tcp --dport 80 -j ACCEPT
-A INPUT -i eth0 -p tcp -m tcp --dport 443 -j ACCEPT
# -A INPUT -s /32 -i tcp -p tcp -m tcp --dport 22 -j DROP
-A INPUT -s 192.168.0.10/24 -j ACCEPT
-A INPUT -p icmp -m icmp --icmp-type 8 -j ACCEPT
-A INPUT -i eth0 -m state --state RELATED,ESTABLISHED -j ACCEPT
COMMIT
copied from here