I’ve got a few talks coming up so need to build some more demo machines. One thing I like to be able to do in the demo environment is ping between machines – sometimes necessary when testing things out but ping is disabled by the Windows firewall in Windows 2008 & R2.
James O’Neill has blogged about working with the Windows firewall at http://blogs.technet.com/jamesone/archive/2009/02/18/how-to-manage-the-windows-firewall-settings-with-powershell.aspx
To just set ping on
Use the HNetCfg.FWPolicy2 COM object and enable the rules for "File and Printer Sharing (Echo Request – ICMPv4-In)". There are similar rules for IPv6 if needed. Blocking pings is just the opposite.