Next header names the following protocol; hop limit is a separate forwarding byte.

highlighted = computed this step

Next header names what follows

Next header 17 names UDP for this toy packet.

next header=17\text{next header}=17
Next header and hop limitThe fixed header fields are decoded from the pinned packet bytes.Next header and hop limit320 bits / 40 bytes0x600123450004114020010db800000000000000000000000120010db8000000000000000000000002byte 0byte 1byte 2byte 301100000000000010010001101000101byte 4byte 5byte 6byte 700000000000001000001000101000000byte 8byte 9byte 10byte 1100100000000000010000110110111000byte 12byte 13byte 14byte 1500000000000000000000000000000000byte 16byte 17byte 18byte 1900000000000000000000000000000000byte 20byte 21byte 22byte 2300000000000000000000000000000001byte 24byte 25byte 26byte 2700100000000000010000110110111000byte 28byte 29byte 30byte 3100000000000000000000000000000000byte 32byte 33byte 34byte 3500000000000000000000000000000000byte 36byte 37byte 38byte 3900000000000000000000000000000010version6traffic-class0flow-label0x12345payload-length4next-header17->UDPhop-limit64source2001:db8::1(cont.)(cont.)(cont.)destination2001:db8::2(cont.)(cont.)(cont.)

Hop limit is another byte

The hop limit byte is 64. This book does not model a router decrement.

hop limit=64\text{hop limit}=64
Next header and hop limitThe fixed header fields are decoded from the pinned packet bytes.Next header and hop limit320 bits / 40 bytes0x600123450004114020010db800000000000000000000000120010db8000000000000000000000002byte 0byte 1byte 2byte 301100000000000010010001101000101byte 4byte 5byte 6byte 700000000000001000001000101000000byte 8byte 9byte 10byte 1100100000000000010000110110111000byte 12byte 13byte 14byte 1500000000000000000000000000000000byte 16byte 17byte 18byte 1900000000000000000000000000000000byte 20byte 21byte 22byte 2300000000000000000000000000000001byte 24byte 25byte 26byte 2700100000000000010000110110111000byte 28byte 29byte 30byte 3100000000000000000000000000000000byte 32byte 33byte 34byte 3500000000000000000000000000000000byte 36byte 37byte 38byte 3900000000000000000000000000000010version6traffic-class0flow-label0x12345payload-length4next-header17->UDPhop-limit64source2001:db8::1(cont.)(cont.)(cont.)destination2001:db8::2(cont.)(cont.)(cont.)

These are separate fields

Next header names the following protocol; hop limit is the forwarding budget.

17,6417,64
Next header and hop limitThe fixed header fields are decoded from the pinned packet bytes.Next header and hop limit320 bits / 40 bytes0x600123450004114020010db800000000000000000000000120010db8000000000000000000000002byte 0byte 1byte 2byte 301100000000000010010001101000101byte 4byte 5byte 6byte 700000000000001000001000101000000byte 8byte 9byte 10byte 1100100000000000010000110110111000byte 12byte 13byte 14byte 1500000000000000000000000000000000byte 16byte 17byte 18byte 1900000000000000000000000000000000byte 20byte 21byte 22byte 2300000000000000000000000000000001byte 24byte 25byte 26byte 2700100000000000010000110110111000byte 28byte 29byte 30byte 3100000000000000000000000000000000byte 32byte 33byte 34byte 3500000000000000000000000000000000byte 36byte 37byte 38byte 3900000000000000000000000000000010version6traffic-class0flow-label0x12345payload-length4next-header17->UDPhop-limit64source2001:db8::1(cont.)(cont.)(cont.)destination2001:db8::2(cont.)(cont.)(cont.)

Summary

The fixed header has a protocol byte and a hop-limit byte before the addresses.

next header=17\text{next header}=17
Next header and hop limitThe fixed header fields are decoded from the pinned packet bytes.Next header and hop limit320 bits / 40 bytes0x600123450004114020010db800000000000000000000000120010db8000000000000000000000002byte 0byte 1byte 2byte 301100000000000010010001101000101byte 4byte 5byte 6byte 700000000000001000001000101000000byte 8byte 9byte 10byte 1100100000000000010000110110111000byte 12byte 13byte 14byte 1500000000000000000000000000000000byte 16byte 17byte 18byte 1900000000000000000000000000000000byte 20byte 21byte 22byte 2300000000000000000000000000000001byte 24byte 25byte 26byte 2700100000000000010000110110111000byte 28byte 29byte 30byte 3100000000000000000000000000000000byte 32byte 33byte 34byte 3500000000000000000000000000000000byte 36byte 37byte 38byte 3900000000000000000000000000000010version6traffic-class0flow-label0x12345payload-length4next-header17->UDPhop-limit64source2001:db8::1(cont.)(cont.)(cont.)destination2001:db8::2(cont.)(cont.)(cont.)