Network Programming Ass 1
Network Programming Ass 1
ii). What parameters for netstat should you use to show all the TCP
connections established? Include a printout of this list for your machine. Be
sure to explain what all fields are.
To display all active TCP connections, use:
netstat -at or netstat -an | grep ESTABLISHED
2. traceroute
i). Explain in detail how traceroute works.
traceroute operates as a diagnostic solution to display packet routes from source machines to
their intended destinations by tracking their intermediate stops.
It works by:
IP packets with ICMP Echo Request protocol or UDP packets use TTL value starting
from 1 in their initial transmission.
The Internet routers in succession subtract TTL values before they respond with an ICMP
Time Exceeded message when TTL hits zero.
The destination information traceroute records includes IP addresses together with round-
trip time measurements and hop count data.