Book Image

Understanding TCP/IP

By : CP Books a.s.
Book Image

Understanding TCP/IP

By: CP Books a.s.

Overview of this book

This book covers in detail the Open System Interconnection (OSI) reference model and the TCP/IP protocols that operate that different layers. Its coverage includes various application protocols. The authors explain in an easy-to-read style networking concepts and protocols, with examples that make the book a practical guide in addition to its coverage of theory.
Table of Contents (20 chapters)
19
Index

Chapter 10. User Datagram Protocol

User Datagram Protocol (UDP) is a simple alternative to TCP. UDP is a connectionless service, it does not establish a connection, in contrast to TCP. The source party sends a UDP datagram to the destination party and then stops worrying about the datagram getting lost (this is a job for the application protocol).

UDP datagrams are enveloped in an IP datagram as shown in the following figure:

User Datagram Protocol

Figure 10.1: UDP datagram header

As you can see from the figure above, a UDP header is very simple. It contains the numbers of both the source and destination ports completely analogous to TCP. Again, it is important to mention that the port numbers of the UDP protocol have nothing to do with the port numbers of TCP. UDP uses an independent set of port numbers.

The UDP Length field indicates the length of UDP datagram (header length + data length). The minimum length is 8, i.e., a UDP datagram containing just the header and no data.

An interesting thing is...