0

By default, for Traceroute utility, the "time to live" value will be decremented by 1 each time packet passes through a router. However, is the "time to live" value also decremented by the receiving host?

enter image description here

As the picture show, for the last time traceroute packet is sent, device A increase the TTL value to 3. After packet passes router B and C, it still have TTL=1. Then, it seems when the packet reaches the receiving host - device D, its TTL value is decremented again to 0, even though the packet is not going to be forwarded anymore.

I cannot find any sources on the internet saying the destination host also decrement the TTL value of the packet. Most of them are just talking about the router.

Thanks in advance!

2 Answers 2

1

is the "time to live" value also decremented by the receiving host?

No. TTL is decremented before forwarding a packet (RFC 791 states "when it is processed"). When the TTL counter reaches 0 the packet is discarded.

If the destination host would decrement a TTL of 1 to 0, it would need to discard the packet, making all previous transport futile in spite of actually reaching the destination.

RFC 791 explicitly states (emphasis mine)

If the time to live reaches zero before the internet datagram reaches its destination, the internet datagram is destroyed.

(Note that above RFC originally defined TTL as a timer, but when forwarding eventually became faster than anticipated TTL effectively grew to a counter.)

2
  • Is it the same principle for ICMP Time to Live? Not just traceroute? Thanks!
    – Student95
    Apr 28, 2021 at 6:15
  • Not just the same principle but the very same thing. Traceroute uses either ICMP echo requests or (dummy) UDP datagrams, depending on platform and preferences.
    – Zac67
    Apr 28, 2021 at 6:52
0

TTL is decremented on two occasions:

passing through a router, i.e. being forwarded from one interface to another

or

delayed in a router queue for certain amount of time, usually one drop in TTL for every second

and is discarded if it turns zero.

Destination host has nothing much to do with that value.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.