A simple command-line tracert implementation in Python 3 using ICMP packets

Traceroute

A simple command-line tracert implementation in Python 3 using ICMP packets
Traceroute

Details

Traceroute is a networking tool designed for tracing the movement of packets across a network. In this Python 3 implementation, ICMP ‘ping’ packets are used, much like the Windows tracert.exe program (and unlike Unix tracert which typically uses UDP packets).

The application sends a sequence of ICMP packets to the host, initially with the Time-To-Live field set to 1. As the packet travels across the network to its final destination, each node it passes through will decrement the TTL field by 1. When the field reaches zero the node will respond by saying that the packet could not reach its destination.

+------+           +--------+
| | TTL = 1

 

 

 

To finish reading, please visit source site