Current APIs for ICMP

I'm trying to make sure that we're using the most up-to-date networking code on Apple platforms, and generally moving away from BSD sockets.

This is fine for HTTP get <-> response exchanges (URLSession), and for TCP,TLS,UDP,DTLS etc. connections (NWConnection variants).

I see nothing other than sockets for handling ICMP though. Is this true, or is there some API which I've missed that would let me deal with ICMP without using BSD sockets?

generally moving away from BSD sockets.

Yay!

I see nothing other than sockets for handling ICMP though.

Indeed. BSD Sockets is still the best API for ICMP on our platforms.

If you’d like to see this change, I encourage you to file an enhancement request against Network framework. Please post your bug number, just for the record.

Share and Enjoy

Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@apple.com"
Current APIs for ICMP
 
 
Q