In the commonly used TCP/IP communications, that would either be a TCP header, or a UDP header.In the commonly used TCP/IP communications, that would either be a TCP header, or a UDP header.In the commonly used TCP/IP communications, that would either be a TCP header, or a UDP header.In the commonly used TCP/IP communications, that would either be a TCP header, or a UDP header.
It is a TCP Header
a tcp header contains the information of the source and destination networks and well as what port to access with out it the packet would not know where to go
both tcp and udp
The sequence number, acknowledge number, and Window fields.
To reassemble the segments into data.
2^16 bytes - size of TCP header
code bits
in tcp header (32 bits) we have a field that is called options and padding that has variable in length and the header length shows the actual header size i.e size of 20 octets+size of options and padding field and in UDP we dont have any field like that and its header is fixed of 8 OCTETS (32 bits header size) refrence: WIRELESS COMMUNICATIONS AND NETWORKS by William Stallings Second Edition pg 91(see fig)
That is the way the standard designed the header. They could be placed anywhere as long as everyone understood where in the packet header it was placed.
Both TCP and UDP have origin and destination ports - and that is about all the similarity there is between the two. TCP has several other fields that UDP doesn't have, including window size; a consecutive byte numbering (to figure out where to place a TCP segment in a data stream); the bytes that the other side is expected to send; and others.
souce and destination ports