Sunday, February 10, 2008

header of every IP packet

TOS (Type Of Service)
The TOS byte can be used to mark the priority of a packet. It’s generally set to
zero, which means that the devices in the network that examine the packet give it
there best effort in delivering it from one side of the network to the other. By setting
this byte to a non-zero value, an application can request improved handling for
a packet, meaning it’s less likely to be dropped or delayed.
This byte is also known as the Differentiated Services (or DiffServ) field.
TTL (Time To Live)
Each time a packet takes one hop in its path across a network, the number in the
TTL byte is reduced by one. If a device receives a packet with a zero in its TTL
byte, it discards the packet. A TTL of zero mean the packet has lived too long (that
is, it has taken too many hops), indicating a problem with the network or with the
packet. The TTL keeps packets from circling an IP network forever.
Checksum
A checksum is used to detect any changes made to the bits during a transmission.
The sending side feeds all the bits it is sending through a sophisticated equation and
writes the final result of the equation into the checksum field. The receiving side
similarly passes all the bits it receives through the same equation. If its results match
the checksum that was sent, the receiving side can be confident no bits were
changed (accidentally or maliciously) during the transmission. Otherwise, it should
discard the packet it received.
This checksum is used to verify the integrity of the IP header.
Source Address and Destination Address
These are the four-byte IP addresses of the sending and receiving applications. We
traditionally write these four bytes in dotted notation, like 199.72.46.202.
The above definitions merely scratch the surface of an extremely complex subject. Because
this is obviously a brief primer, we recommend that you seek out some of the many excellent
books that explain TCP/IP comprehensively

No comments: