Iptables ping !
iptables -A OUTPUT -o eth0 -p icmp -m state --state ! INVALID -j ACCEPT # ou DROP
iptables -A INPUT -i eth0 -p icmp -m state ESTABLISHED,RELATED -j ACCEPT # ou DROP
On peut aller plus finement en gérant le type de réponse icmp.
iptables -A INPUT -i eth0 -p icmp --icmp-type destination-unreachable -j ACCEPT # ou DROP
iptables -A INPUT -i eth0 -p icmp --icmp-type echo-reply -j ACCEPT # ou DROP
iptables -A INPUT -i eth0 -p icmp --icmp-type echo-request -j ACCEPT # ou DROP
iptables -A INPUT -i eth0 -p icmp --icmp-type time-exceeded -j ACCEPT # ou DROP
iptables -A INPUT -i eth0 -p icmp --icmp-type source-quench -j ACCEPT # ou DROP
Pagination
<<| Page : IpTables : FAQ : ping : |>>