Latest Posts »
Latest Comments »
Popular Posts »

UDP Packet Structure

Written by The Geekette on July 9, 2006 – 3:08 pm
Posted in Networking | No Comments »

UDP does not perform any of the handshaking sequences that are seen with TCP. UDP is a lot less reliable than TCP, but UDP does offer more speed than TCP. This is ideal for data that does not require all packets to arrive and in order and needs fast delivery. Such services that use UDP are ones like DHCP and DNS. This protocol is the easier of the two protocols of TCP/IP to spoof since it does not use sequencing or acknowledgement numbers.

 

Source
Port
Destination
Port
Length Optional
Checksum

 



TCP Packet Structure

Written by The Geekette on July 9, 2006 – 2:48 pm
Posted in Networking | No Comments »

The diagram shown below demonstrates the fixed packet structure that is use by TCP/ This fixed packet structure is used to provide flow control, maintain the reliability of the communication and ensure that any data that is missing is resent buy sequencing and acknowledgement.

The Flag field is a 1 byte field. Common flags in this field include

SYN Synchronize
ACK Acknowledgement
PSH Push
FIN Finish
RST Reset
URG Urgent
Source Port Destination Port
Sequence Number
Acknowledgement Number
Data Offset Reserved U
R
G
A
C
K
P
S
H
R
S
T
S
Y
N
F
I
N
Window
Checksum                                              Urgent Pointer
Options      Padding
Data


TCP Handshakes

Written by The Geekette on July 9, 2006 – 2:38 pm
Posted in Networking | No Comments »

To allow two hosts to communicate and exchange data reliably, TCP performs a three step handshake before any of the data is sent. This is when TCP guarantees that the data will arrive in tact by using a sequence and acknowledgement numbers. After all data is sent, TCP then performs a four step shutdown that concludes the session.

Three Step Startup

PC

—————- SYN —————->

Server

<———— SYN ACK————–
—————- ACK —————->

Four Step Shutdown

PC

—————FIN ACK ————->

Server

<—————ACK——————
<———— FIN ACK—————
—————- ACK —————->