SlideShare a Scribd company logo
2
Most read
5
Most read
© Peter R. Egli 2015
1/7
Rev. 3.50
UDP - User Datagram Protocol indigoo.com
INTRODUCTION TO USER DATAGRAM PROTOCOL,
A SIMPLE PACKET TRANSPORT SERVICE IN THE
INTERNET PROTOCOL SUITE
PETER R. EGLI
INDIGOO.COM
USER DATAGRAM PROTOCOL
UDP
© Peter R. Egli 2015
2/7
Rev. 3.50
UDP - User Datagram Protocol indigoo.com
Contents
1. UDP (RFC768) characteristics
2. UDP Service
3. Typical UDP applications
4. UDP Checksum
5. UDP versus TCP
© Peter R. Egli 2015
3/7
Rev. 3.50
UDP - User Datagram Protocol indigoo.com
1. UDP (RFC768) characteristics
• No connection establishment/teardown; data is just sent right away.
• No flow control / congestion control, sender can overrun receiver‘s buffer:
 UDP is not suited for bulk data transfer.
 For data transfer with UDP a lock-step protocol is required (to be implemented
by the application).
• No error control; corrupted data is not retransmitted (even though UDP header has a
checksum to detect errors and report these to the application).
Packet 4 is
dropped (buffer
overrun).
Host 1 Host 2
Packet 1 is sent
to the application.
Packet 4 is missing. The
packet loss needs
to be handled by
the application
(detection, retransmission).
1
Packet 1 is stored
in the receive queue.
1
2
1
2
1
2
3
4
3
1
2
3
5
Packet 2 is stored
in the receive queue.
Packet 3 is stored
in the receive queue.
2
3
5
1
Host 1 sends
packets.
© Peter R. Egli 2015
4/7
Rev. 3.50
UDP - User Datagram Protocol indigoo.com
2. UDP service
 UDP is basically a simple extension of the IP datagram service.
 UDP adds multiplexing (on port number) to IP datagram service.
 Application writes are mapped 1:1 to UDP datagrams; UDP passes these 1:1 to the IP layer.
UDP layer
Appl.
IP packets
Application
sends packets
(APDU’s) over
the socket
interface
Socket interface
IP layer
2500
300
500
150
TPDU’s
(UDP datagrams)
2500
300
500
150
300 500 15015001000
IP layer
300
2500
500
150
UDP layer
300
2500
500
150
Appl.
Application
reads packets
(APDU’s)
from the
socket
interface
TPDU’s
(UDP datagrams)
2500byte packet is too big. IP layer fragments
the UDP datagram.
© Peter R. Egli 2015
5/7
Rev. 3.50
UDP - User Datagram Protocol indigoo.com
3. Typical UDP applications
UDP is best suited for applications with short command-response type „transactions“
that do not justify the establishment / release prior to the data exchange.
Host 1 Host 2
SNMP GET Request
SNMP GET Response
SNMP Host 1 Host 2
DNS Query
DNS Response
DNS Host 1 Host 2
Time request
Time response
SNTP
Host 1 Host 2
DHCP Request
DHCP Response
DHCP/Bootp Host 1 Host 1 Host 2
RIP Route Update
RIPHost 2
RADIUS Access Request
RADIUS
RADIUS Access Accept
Host 1 Host 2
RPC Request
RPC Reply
RPC
© Peter R. Egli 2015
6/7
Rev. 3.50
UDP - User Datagram Protocol indigoo.com
4. UDP checksum
 UDP has a checksum too that provides minimal protection against transmission errors.
 The checksum is optional; if it is not used it shall be set to 0.
 Becaus the IP addresses are used in the UDP checksum calculation,
UDP is tightly bound to the IP layer. Therefore UDP can only run on top of IP.
Pseudo
header
The checksum is
calculated over
the pseudo header,
UDP header and
data (UDP payload).
Source Port Destination Port
Checksum Length
Data
UDP Length00000000 Protocol=17 UDP Length
IP Destination Address
IP Source Address
UDP
header
© Peter R. Egli 2015
7/7
Rev. 3.50
UDP - User Datagram Protocol indigoo.com
5. UDP versus TCP
TCP
 Connection-oriented, point-to-point (unicast)
 Reliable end-to-end:
No bit errors due to checksum.
Packet ordering preserved.
No duplicates.
No packet loss.
 Stream-oriented (no message boundary preservation)
 Has flow control to maximise throughput
 Has congestion control to minimise packet loss
 Analogon: phone
Examples of application protocols using TCP:
HTTP, SMTP, FTP, TELNET
UDP
 Connection-less, best-effort
 Not reliable (no retransmissions)
 Message boundary preservation
 No flow control
 No congestion control
 Analogon: mail (snail mail)
Examples of application protocols
using UDP:
SNMP, DNS, TFTP, RTP, DHCP, SNTP
N.B.: It is possible to run application protocols over both TCP and UDP. E.g. DNS is normally run on UDP, but
for zone transfers (higher data volume) DNS uses TCP. Actually there is a shift towards using TCP instead
UDP since TCP can better provide security (SSL/TLS, simpler filtering in firewalls etc.).

More Related Content

What's hot (20)

PPT
Chapter 4 data link layer
Naiyan Noor
 
PPT
Internet control message protocol
asimnawaz54
 
PPTX
Multicastingand multicast routing protocols
Iffat Anjum
 
PPTX
Network Layer
Dr Shashikant Athawale
 
PPTX
Ethernet
sijil chacko
 
PPTX
Multiplexing
Neeraj Garwal
 
PPTX
The medium access sublayer
Lal Bahadur Gehlot
 
PPTX
Transmission Control Protocol (TCP)
k33a
 
PPT
TCP/IP Basics
sanjoysanyal
 
PPTX
Computer network switching
Shivani Godha
 
PPT
IPV4 Frame Format
Aditya Rawat
 
PPTX
Dhcp ppt
Hema Dhariwal
 
PPTX
IPV6 ADDRESS
Jothi Lakshmi
 
PPTX
Data link layer
Mukesh Chinta
 
PPT
User datagram protocol
Mohd Arif
 
PPTX
Arp and rarp
Nita Dalla
 
PPT
Packet switching
asimnawaz54
 
PDF
TCP Vs UDP
Ahmed Elnaggar
 
Chapter 4 data link layer
Naiyan Noor
 
Internet control message protocol
asimnawaz54
 
Multicastingand multicast routing protocols
Iffat Anjum
 
Network Layer
Dr Shashikant Athawale
 
Ethernet
sijil chacko
 
Multiplexing
Neeraj Garwal
 
The medium access sublayer
Lal Bahadur Gehlot
 
Transmission Control Protocol (TCP)
k33a
 
TCP/IP Basics
sanjoysanyal
 
Computer network switching
Shivani Godha
 
IPV4 Frame Format
Aditya Rawat
 
Dhcp ppt
Hema Dhariwal
 
IPV6 ADDRESS
Jothi Lakshmi
 
Data link layer
Mukesh Chinta
 
User datagram protocol
Mohd Arif
 
Arp and rarp
Nita Dalla
 
Packet switching
asimnawaz54
 
TCP Vs UDP
Ahmed Elnaggar
 

Viewers also liked (7)

PPTX
Tcp and udp
Ahmad Khalid Nasrat
 
PPT
Comparacion estre modelos osi y tcp/ip
ggordillo
 
PPTX
protocolos udp y tcp
Prodanz club de baile y quinceañeras
 
PPT
Ejemplo De AplicacióN En El Modelo Tcp
katior
 
PPTX
Comparacion modelo osi y tcp ip
wsar85
 
PPT
Comparacion entre el modelo TCP/IP Y MODELO OSI
dariospeed
 
PPTX
3. Modelos OSI y TCP/IP (Características, Funciones, Diferencias)
wilber147
 
Tcp and udp
Ahmad Khalid Nasrat
 
Comparacion estre modelos osi y tcp/ip
ggordillo
 
Ejemplo De AplicacióN En El Modelo Tcp
katior
 
Comparacion modelo osi y tcp ip
wsar85
 
Comparacion entre el modelo TCP/IP Y MODELO OSI
dariospeed
 
3. Modelos OSI y TCP/IP (Características, Funciones, Diferencias)
wilber147
 
Ad

Similar to UDP - User Datagram Protocol (20)

PPTX
User Datagram Protocol
Purushottam Kamble
 
PPT
Computer Network - Transport Layer Services
RAJASEKARAN G
 
PPTX
07 coms 525 tcpip - udp
Palanivel Kuppusamy
 
PPTX
user development programing in networking UDP.pptx
Getnetedegemu
 
DOCX
UDP and TCP Protocol & Encrytion and its algorithm
Ayesha Tahir
 
PPTX
What Is User Datagram Protocol?
Simplilearn
 
DOC
User datagram protocol
Ishtdeep Hora
 
PDF
mrutu sammary 1.pdf
SamiaMaulidi
 
PDF
Computer Communication Networks- TRANSPORT LAYER PROTOCOLS
Krishna Nanda
 
PPTX
#KPC #CST #Protocols
KEIKolkata
 
PPT
UDP and TCP header.ppt
nehayarrapothu
 
PPT
Unityfyfyufhufhhcfhfufhufhhufufhyrruruuf4-2.ppt
naganekishor7
 
PDF
UNit-4 Transport Layer and its protocols.pdf
ManimegalaM3
 
PPTX
07-UDP.pptx
ShajiThomas67
 
PDF
TCP/IP & UDP
ghayour abbas
 
PPT
2-CN_UDP_TCP_f7a922763a77c5ea2bc334f8e36c71f8.ppt
vihashni2310922
 
PPTX
SYBSC IT COMPUTER NETWORKS UNIT V Process to-Process Delivery
Arti Parab Academics
 
PPTX
Unit 4 UDP
Nivetha Palanisamy
 
PPTX
Internet of Things Unit - 01 Part 3A.pptx
SunilNirmal9
 
User Datagram Protocol
Purushottam Kamble
 
Computer Network - Transport Layer Services
RAJASEKARAN G
 
07 coms 525 tcpip - udp
Palanivel Kuppusamy
 
user development programing in networking UDP.pptx
Getnetedegemu
 
UDP and TCP Protocol & Encrytion and its algorithm
Ayesha Tahir
 
What Is User Datagram Protocol?
Simplilearn
 
User datagram protocol
Ishtdeep Hora
 
mrutu sammary 1.pdf
SamiaMaulidi
 
Computer Communication Networks- TRANSPORT LAYER PROTOCOLS
Krishna Nanda
 
#KPC #CST #Protocols
KEIKolkata
 
UDP and TCP header.ppt
nehayarrapothu
 
Unityfyfyufhufhhcfhfufhufhhufufhyrruruuf4-2.ppt
naganekishor7
 
UNit-4 Transport Layer and its protocols.pdf
ManimegalaM3
 
07-UDP.pptx
ShajiThomas67
 
TCP/IP & UDP
ghayour abbas
 
2-CN_UDP_TCP_f7a922763a77c5ea2bc334f8e36c71f8.ppt
vihashni2310922
 
SYBSC IT COMPUTER NETWORKS UNIT V Process to-Process Delivery
Arti Parab Academics
 
Unit 4 UDP
Nivetha Palanisamy
 
Internet of Things Unit - 01 Part 3A.pptx
SunilNirmal9
 
Ad

More from Peter R. Egli (20)

PDF
LPWAN Technologies for Internet of Things (IoT) and M2M Scenarios
Peter R. Egli
 
PDF
Data Networking Concepts
Peter R. Egli
 
PDF
Communication middleware
Peter R. Egli
 
PDF
Transaction Processing Monitors (TPM)
Peter R. Egli
 
PDF
Business Process Model and Notation (BPMN)
Peter R. Egli
 
PDF
Microsoft .NET Platform
Peter R. Egli
 
PDF
Overview of Cloud Computing
Peter R. Egli
 
PDF
MQTT - MQ Telemetry Transport for Message Queueing
Peter R. Egli
 
PDF
Enterprise Application Integration Technologies
Peter R. Egli
 
PDF
Overview of Microsoft .Net Remoting technology
Peter R. Egli
 
PDF
Android Native Development Kit
Peter R. Egli
 
PDF
Overview of SCTP (Stream Control Transmission Protocol)
Peter R. Egli
 
PDF
Overview of SCTP (Stream Control Transmission Protocol)
Peter R. Egli
 
PDF
Web services
Peter R. Egli
 
PDF
Overview of Spanning Tree Protocol (STP & RSTP)
Peter R. Egli
 
PDF
MSMQ - Microsoft Message Queueing
Peter R. Egli
 
PDF
Common Object Request Broker Architecture - CORBA
Peter R. Egli
 
PDF
Component Object Model (COM, DCOM, COM+)
Peter R. Egli
 
PDF
JMS - Java Messaging Service
Peter R. Egli
 
PDF
Web Services (SOAP, WSDL, UDDI)
Peter R. Egli
 
LPWAN Technologies for Internet of Things (IoT) and M2M Scenarios
Peter R. Egli
 
Data Networking Concepts
Peter R. Egli
 
Communication middleware
Peter R. Egli
 
Transaction Processing Monitors (TPM)
Peter R. Egli
 
Business Process Model and Notation (BPMN)
Peter R. Egli
 
Microsoft .NET Platform
Peter R. Egli
 
Overview of Cloud Computing
Peter R. Egli
 
MQTT - MQ Telemetry Transport for Message Queueing
Peter R. Egli
 
Enterprise Application Integration Technologies
Peter R. Egli
 
Overview of Microsoft .Net Remoting technology
Peter R. Egli
 
Android Native Development Kit
Peter R. Egli
 
Overview of SCTP (Stream Control Transmission Protocol)
Peter R. Egli
 
Overview of SCTP (Stream Control Transmission Protocol)
Peter R. Egli
 
Web services
Peter R. Egli
 
Overview of Spanning Tree Protocol (STP & RSTP)
Peter R. Egli
 
MSMQ - Microsoft Message Queueing
Peter R. Egli
 
Common Object Request Broker Architecture - CORBA
Peter R. Egli
 
Component Object Model (COM, DCOM, COM+)
Peter R. Egli
 
JMS - Java Messaging Service
Peter R. Egli
 
Web Services (SOAP, WSDL, UDDI)
Peter R. Egli
 

Recently uploaded (20)

PDF
CIFDAQ Market Wrap for the week of 4th July 2025
CIFDAQ
 
PDF
Transforming Utility Networks: Large-scale Data Migrations with FME
Safe Software
 
PDF
UiPath DevConnect 2025: Agentic Automation Community User Group Meeting
DianaGray10
 
PDF
“NPU IP Hardware Shaped Through Software and Use-case Analysis,” a Presentati...
Edge AI and Vision Alliance
 
PDF
Mastering Financial Management in Direct Selling
Epixel MLM Software
 
PPTX
Agentforce World Tour Toronto '25 - MCP with MuleSoft
Alexandra N. Martinez
 
PPTX
MuleSoft MCP Support (Model Context Protocol) and Use Case Demo
shyamraj55
 
PDF
What’s my job again? Slides from Mark Simos talk at 2025 Tampa BSides
Mark Simos
 
PPTX
New ThousandEyes Product Innovations: Cisco Live June 2025
ThousandEyes
 
PDF
Book industry state of the nation 2025 - Tech Forum 2025
BookNet Canada
 
PDF
Future-Proof or Fall Behind? 10 Tech Trends You Can’t Afford to Ignore in 2025
DIGITALCONFEX
 
PDF
SIZING YOUR AIR CONDITIONER---A PRACTICAL GUIDE.pdf
Muhammad Rizwan Akram
 
PDF
AI Agents in the Cloud: The Rise of Agentic Cloud Architecture
Lilly Gracia
 
PPTX
Digital Circuits, important subject in CS
contactparinay1
 
PPTX
The Project Compass - GDG on Campus MSIT
dscmsitkol
 
PDF
Automating Feature Enrichment and Station Creation in Natural Gas Utility Net...
Safe Software
 
PPTX
From Sci-Fi to Reality: Exploring AI Evolution
Svetlana Meissner
 
PDF
Peak of Data & AI Encore AI-Enhanced Workflows for the Real World
Safe Software
 
PDF
Bitcoin for Millennials podcast with Bram, Power Laws of Bitcoin
Stephen Perrenod
 
PPTX
COMPARISON OF RASTER ANALYSIS TOOLS OF QGIS AND ARCGIS
Sharanya Sarkar
 
CIFDAQ Market Wrap for the week of 4th July 2025
CIFDAQ
 
Transforming Utility Networks: Large-scale Data Migrations with FME
Safe Software
 
UiPath DevConnect 2025: Agentic Automation Community User Group Meeting
DianaGray10
 
“NPU IP Hardware Shaped Through Software and Use-case Analysis,” a Presentati...
Edge AI and Vision Alliance
 
Mastering Financial Management in Direct Selling
Epixel MLM Software
 
Agentforce World Tour Toronto '25 - MCP with MuleSoft
Alexandra N. Martinez
 
MuleSoft MCP Support (Model Context Protocol) and Use Case Demo
shyamraj55
 
What’s my job again? Slides from Mark Simos talk at 2025 Tampa BSides
Mark Simos
 
New ThousandEyes Product Innovations: Cisco Live June 2025
ThousandEyes
 
Book industry state of the nation 2025 - Tech Forum 2025
BookNet Canada
 
Future-Proof or Fall Behind? 10 Tech Trends You Can’t Afford to Ignore in 2025
DIGITALCONFEX
 
SIZING YOUR AIR CONDITIONER---A PRACTICAL GUIDE.pdf
Muhammad Rizwan Akram
 
AI Agents in the Cloud: The Rise of Agentic Cloud Architecture
Lilly Gracia
 
Digital Circuits, important subject in CS
contactparinay1
 
The Project Compass - GDG on Campus MSIT
dscmsitkol
 
Automating Feature Enrichment and Station Creation in Natural Gas Utility Net...
Safe Software
 
From Sci-Fi to Reality: Exploring AI Evolution
Svetlana Meissner
 
Peak of Data & AI Encore AI-Enhanced Workflows for the Real World
Safe Software
 
Bitcoin for Millennials podcast with Bram, Power Laws of Bitcoin
Stephen Perrenod
 
COMPARISON OF RASTER ANALYSIS TOOLS OF QGIS AND ARCGIS
Sharanya Sarkar
 

UDP - User Datagram Protocol

  • 1. © Peter R. Egli 2015 1/7 Rev. 3.50 UDP - User Datagram Protocol indigoo.com INTRODUCTION TO USER DATAGRAM PROTOCOL, A SIMPLE PACKET TRANSPORT SERVICE IN THE INTERNET PROTOCOL SUITE PETER R. EGLI INDIGOO.COM USER DATAGRAM PROTOCOL UDP
  • 2. © Peter R. Egli 2015 2/7 Rev. 3.50 UDP - User Datagram Protocol indigoo.com Contents 1. UDP (RFC768) characteristics 2. UDP Service 3. Typical UDP applications 4. UDP Checksum 5. UDP versus TCP
  • 3. © Peter R. Egli 2015 3/7 Rev. 3.50 UDP - User Datagram Protocol indigoo.com 1. UDP (RFC768) characteristics • No connection establishment/teardown; data is just sent right away. • No flow control / congestion control, sender can overrun receiver‘s buffer:  UDP is not suited for bulk data transfer.  For data transfer with UDP a lock-step protocol is required (to be implemented by the application). • No error control; corrupted data is not retransmitted (even though UDP header has a checksum to detect errors and report these to the application). Packet 4 is dropped (buffer overrun). Host 1 Host 2 Packet 1 is sent to the application. Packet 4 is missing. The packet loss needs to be handled by the application (detection, retransmission). 1 Packet 1 is stored in the receive queue. 1 2 1 2 1 2 3 4 3 1 2 3 5 Packet 2 is stored in the receive queue. Packet 3 is stored in the receive queue. 2 3 5 1 Host 1 sends packets.
  • 4. © Peter R. Egli 2015 4/7 Rev. 3.50 UDP - User Datagram Protocol indigoo.com 2. UDP service  UDP is basically a simple extension of the IP datagram service.  UDP adds multiplexing (on port number) to IP datagram service.  Application writes are mapped 1:1 to UDP datagrams; UDP passes these 1:1 to the IP layer. UDP layer Appl. IP packets Application sends packets (APDU’s) over the socket interface Socket interface IP layer 2500 300 500 150 TPDU’s (UDP datagrams) 2500 300 500 150 300 500 15015001000 IP layer 300 2500 500 150 UDP layer 300 2500 500 150 Appl. Application reads packets (APDU’s) from the socket interface TPDU’s (UDP datagrams) 2500byte packet is too big. IP layer fragments the UDP datagram.
  • 5. © Peter R. Egli 2015 5/7 Rev. 3.50 UDP - User Datagram Protocol indigoo.com 3. Typical UDP applications UDP is best suited for applications with short command-response type „transactions“ that do not justify the establishment / release prior to the data exchange. Host 1 Host 2 SNMP GET Request SNMP GET Response SNMP Host 1 Host 2 DNS Query DNS Response DNS Host 1 Host 2 Time request Time response SNTP Host 1 Host 2 DHCP Request DHCP Response DHCP/Bootp Host 1 Host 1 Host 2 RIP Route Update RIPHost 2 RADIUS Access Request RADIUS RADIUS Access Accept Host 1 Host 2 RPC Request RPC Reply RPC
  • 6. © Peter R. Egli 2015 6/7 Rev. 3.50 UDP - User Datagram Protocol indigoo.com 4. UDP checksum  UDP has a checksum too that provides minimal protection against transmission errors.  The checksum is optional; if it is not used it shall be set to 0.  Becaus the IP addresses are used in the UDP checksum calculation, UDP is tightly bound to the IP layer. Therefore UDP can only run on top of IP. Pseudo header The checksum is calculated over the pseudo header, UDP header and data (UDP payload). Source Port Destination Port Checksum Length Data UDP Length00000000 Protocol=17 UDP Length IP Destination Address IP Source Address UDP header
  • 7. © Peter R. Egli 2015 7/7 Rev. 3.50 UDP - User Datagram Protocol indigoo.com 5. UDP versus TCP TCP  Connection-oriented, point-to-point (unicast)  Reliable end-to-end: No bit errors due to checksum. Packet ordering preserved. No duplicates. No packet loss.  Stream-oriented (no message boundary preservation)  Has flow control to maximise throughput  Has congestion control to minimise packet loss  Analogon: phone Examples of application protocols using TCP: HTTP, SMTP, FTP, TELNET UDP  Connection-less, best-effort  Not reliable (no retransmissions)  Message boundary preservation  No flow control  No congestion control  Analogon: mail (snail mail) Examples of application protocols using UDP: SNMP, DNS, TFTP, RTP, DHCP, SNTP N.B.: It is possible to run application protocols over both TCP and UDP. E.g. DNS is normally run on UDP, but for zone transfers (higher data volume) DNS uses TCP. Actually there is a shift towards using TCP instead UDP since TCP can better provide security (SSL/TLS, simpler filtering in firewalls etc.).