IPUtils - Source Code Walk
IPUtils - Source Code Walk

IPUtils is a popular Linux Open-Source package which includes various utilities for Linux networking such as ping, arping, ping6 and so on.

Refer:
GitHub iputils ↗
ping.c ↗
ping.h ↗
ping6_common.c ↗
ping_common.c ↗

Refer my Google Drive export diagram of the IPUtils :: Ping command implementation architecture:

  • green box represents function pointer set
  • yellow boxes are the important APIs/functions
  • gray boxes are the standard external APIs (such as system calls and glibc library)
  • pink/purple box(es) are the additional helper APIs (which are not as critical as those yellow ones)

* please note that I am not expanding deliberately ping6_run() and ping6_function_set since it is quite obvious that it has the same identical architecture as that of IPv4 implementation (i.e: ping4_run() and ping4_func_set).

The Linux Channel - IP Utils ping command implementation API flow Architecture