4 ms·
Should I Block ICMP?
- veganjay 4y agoI have burned a lot of time thinking a host was down only to find it blocks ICMP echo (ping). As a follow-up to a ping fail, I check to see if a known port is open using nmap. gist: https://gist.github.com/veganjay/6b902c478bda429187f39e53a5b7c04a https://gist.github.com/veganjay/6b902c478bda429187f39e53a5b...
- redrove 4y agoI find that a little hard to remember, and nmap isn't as widely available as netcat: nc -zv 1.1.1.1 443 Alternatively, the most barebones version, useful for inside a container where all you have is a shell and the kernel: cat > /dev/tcp/www.google.com/443
- tredre3 4y ago> Alternatively, the most barebones version, useful for inside a container where all you have is a shell and the kernel: > cat > /dev/tcp/www.google.com/443 I was unfamiliar with this device so I googled a bit. This isn't a real file/device, it's a bash-ism when built with --enable-net-redirections (apparently disabled in debian-based distros [1]). That's too bad, would have been cool to have such easy access to sockets anywhere using fopen(). 1. https://www.oreilly.com/library/view/bash-cookbook/0596526784/ch15s09.html https://www.oreilly.com/library/view/bash-cookbook/059652678...
- jonas-w 4y agoIf it is a device in your local network, arp-scanning is also very useful. IIRC e.g. windows or ios devices won't respond to icmp pings but to arp "pings".
- commandersaki 4y agoDon't really agree with rate limiting ICMP echo request/response traffic. I've found flood ping useful in diagnosing packet loss.
- cafard 4y agoSee https://rachelbythebay.com/w/2015/05/15/pmtud/ https://rachelbythebay.com/w/2015/05/15/pmtud/ and https://rachelbythebay.com/w/2013/07/19/slip/ https://rachelbythebay.com/w/2013/07/19/slip/
- klysm 4y agoSomething this site doesn’t address is ICMP redirect behavior and it’s security implications.