Tuesday 25 September 2012

How to disable ICMP requests on Linux and Windows

The ICMP requests can be disabled in Linux and Windows. It is disabled for security purposes.

a) Linux

Linux we have to use procfs

To ignore broadcasts :

    $ cat /proc/sys/net/ipv4/icmp_echo_ignore_broadcasts

    $ echo 1 > /proc/sys/net/ipv4/icmp_echo_ignore_broadcasts

To ignore all type of ICMP traffic

    $ cat /proc/sys/net/ipv4/icmp_echo_ignore_all

    $ echo 1 > /proc/sys/net/ipv4/icmp_echo_ignore_all

b) Windows -> go to "Network connections" -> Select Local Area connection

  On Left side -> "Change setting of this connection" -> Advanced -> Setting -> Advanced

 ICMP-> Settings-> Un-check all to disable all type of ICMP traffic