Please Whitelist This Site?

I know everyone hates ads. But please understand that I am providing premium content for free that takes hundreds of hours of time to research and write. I don't want to go to a pay-only model like some sites, but when more and more people block ads, I end up working for free. And I have a family to support, just like you. :)

If you like The TCP/IP Guide, please consider the download version. It's priced very economically and you can read all of it in a convenient format without ads.

If you want to use this site for free, I'd be grateful if you could add the site to the whitelist for Adblock. To do so, just open the Adblock menu and select "Disable on tcpipguide.com". Or go to the Tools menu and select "Adblock Plus Preferences...". Then click "Add Filter..." at the bottom, and add this string: "@@||tcpipguide.com^$document". Then just click OK.

Thanks for your understanding!

Sincerely, Charles Kozierok
Author and Publisher, The TCP/IP Guide


NOTE: Using software to mass-download the site degrades the server and is prohibited.
If you want to read The TCP/IP Guide offline, please consider licensing it. Thank you.

The Book is Here... and Now On Sale!

Get The TCP/IP Guide for your own computer.
The TCP/IP Guide

Custom Search







Table Of Contents  The TCP/IP Guide
 9  TCP/IP Lower-Layer (Interface, Internet and Transport) Protocols (OSI Layers 2, 3 and 4)
      9  TCP/IP Transport Layer Protocols
           9  Transmission Control Protocol (TCP) and User Datagram Protocol (UDP)
                9  TCP/IP User Datagram Protocol (UDP)

Previous Topic/Section
UDP Operation
Previous Page
Pages in Current Topic/Section
1
2
Next Page
UDP Common Applications and Server Port Assignments
Next Topic/Section

UDP Message Format
(Page 1 of 2)

What's the magic word when it comes to UDP? Right, simple. This is true of the operation of the protocol, and it is also true of the format used for UDP messages. Interestingly, however, it is here that we will actually encounter probably the only aspect of UDP that is not simple. I bet that got you interested, huh? Okay, well, it was a worth a try. J

In keeping with the goal of efficiency, the UDP header is only eight bytes in length; this contrasts with the TCP header size of 20 bytes or more. Table 147 and Figure 200 show the format of UDP messages.


Table 147: UDP Message Format

Field Name

Size (bytes)

Description

Source Port

2

Source Port: The 16-bit port number of the process that originated the UDP message on the source device. This will normally be an ephemeral (client) port number for a request sent by a client to a server, or a well-known/registered (server) port number for a reply sent by a server to a client. See the section describing port numbers for details.

Destination Port

2

Destination Port: The 16-bit port number of the process that is the ultimate intended recipient of the message on the destination device. This will usually be a well-known/registered (server) port number for a client request, or an ephemeral (client) port number for a server reply. Again, see the section describing port numbers for details.

Length

2

Length: The length of the entire UDP datagram, including both header and Data fields.

Checksum

2

Checksum: An optional 16-bit checksum computed over the entire UDP datagram plus a special “pseudo header” of fields. See below for more information.

Data

Variable

Data: The encapsulated higher-layer message to be sent.



Figure 200: UDP Message Format

 


Previous Topic/Section
UDP Operation
Previous Page
Pages in Current Topic/Section
1
2
Next Page
UDP Common Applications and Server Port Assignments
Next Topic/Section

If you find The TCP/IP Guide useful, please consider making a small Paypal donation to help the site, using one of the buttons below. You can also donate a custom amount using the far right button (not less than $1 please, or PayPal gets most/all of your money!) In lieu of a larger donation, you may wish to consider purchasing a download license of The TCP/IP Guide. Thanks for your support!
Donate $2
Donate $5
Donate $10
Donate $20
Donate $30
Donate: $



Home - Table Of Contents - Contact Us

The TCP/IP Guide (http://www.TCPIPGuide.com)
Version 3.0 - Version Date: September 20, 2005

© Copyright 2001-2005 Charles M. Kozierok. All Rights Reserved.
Not responsible for any loss resulting from the use of this site.