170 likes | 191 Views
Learn the concept and application of packet encapsulation in computer networks. Visualized examples and detailed explanations explore layered protocol architectures, protocol data units, headers, and more.
E N D
Packet Encapsulation Concept and Application CS 447 Networks and Data Communication Department of Computer Science Southern Illinois University Edwardsville Fall, 2019 Dr. Hiroshi Fujinoki E-mail: hfujino@siue.edu
Request Request Request Request Request (1) Request (1) Response Response Response Response Response with tag (2) Response with tag (2) Computer Network Request (3) Request (3) Internet Internet Internet Internet Response (4) Response (4) User Data User Data Packet With Packets Computer Network User Data User Data Packet Header CS 447 Networks and Data Communication Concept of packets Without Packets (e.g. destination address) (e.g. packet sequence #) Packet_Encapsulation/001
User Data 4 layers Host Computer Host Computer Network Cable CS 447 Networks and Data Communication Concept of packet encapsulation: Layered Protocol Architecture TCP/IP Model OSI 7-Layer Model User Data 7 layers Network Cable Packet_Encapsulation/002
Protocol Data Unit (PDU) Header Datalink Layer Network Layer Frame Physical Layer Frame Physical Layer A packet = Header + PDU CS 447 Networks and Data Communication Packet Encapsulation Visualized (1): User Data (User Data Packet) TCP Packet TCP Layer IP Packet IP Layer Header = Information specific to each protocol layer Packet_Encapsulation/003
CS 447 Networks and Data Communication Example: IP packet header IP packet IP Header IP payload (PDU) image source: https://nmap.org/book/tcpip-ref.html Ext_Int/002
Protocol Data Unit (PDU) Header Datalink Layer Network Layer Frame Physical Layer Frame Physical Layer Packet Encapsulation CS 447 Networks and Data Communication Packet Encapsulation Visualized (2): User Data (User Data Packet) TCP Packet TCP Layer IP Packet IP Layer Packet_Encapsulation/004
User Data A packet in TCP layer TCP Packet TCP Layer IP Packet IP Layer PDU in IP layer A packet (header + PDU) in an upper protocol layer = PDU in the next protocol layer CS 447 Networks and Data Communication Packet Encapsulation Visualized (3): Packet_Encapsulation/005
A packet in TCP layer TCP Layer PDU in IP layer At IP protocol layer, information in TCP header will be handled as if it were a part of user data Packet Encapsulation Any change in TCP will not affect internal design of IP CS 447 Networks and Data Communication Packet Encapsulation Visualized (3): TCP Packet IP Packet IP Layer Packet_Encapsulation/006
Request Request Request (1) Response Response Response with tag (2) Request (3) User Data Internet Internet Response (4) User Data 4 4 3 3 2 2 1 1 CS 447 Networks and Data Communication What is possible if we have packet encapsulation? Communicate using the information in the packet header NW Corresponding protocol layer can communicate Packet_Encapsulation/007
This property guarantees the independence of each protocol layer in a protocol stack CS 447 Networks and Data Communication Definition of Packet Encapsulation: • The entire packet in a lower protocol layer becomes the PDU for the next upper protocol layer • A protocol layer can handle packets from the lower layer without knowing anything about the layer • Without packet encapsulation, each protocol layer has to know the rules in any lower layers • Without packet encapsulation, most of the advantages in the layered structure will not be utilized Packet_Encapsulation/008
Receiver External Operation Sender The top four layers in OSI 7-layer model Presentation Layer Presentation Layer Internal Operation Transport Layer Transport Layer Application Layer Application Layer Session Layer Session Layer The bottom three layers in OSI 7-layer model Network Layer Physical Layer Network Layer Physical Layer DataLink Layer DataLink Layer Protocol layers Underlying Network CS 447 Networks and Data Communication External and Internal Operations Ext_Int/001
CS 447 Networks and Data Communication External Operation Virtual Circuit Datagram D A Virtual Circuit Internal Operation B Datagram C Ext_Int/002
Packets will be re-ordered 3 Receiver 2 Sender 1 External Operation (Virtual Circuit) External Operation (Virtual Circuit) TCP TCP Internal Operation (Datagram) Internal Operation (Datagram) IP IP 1 3 3 3 2 2 2 1 1 1 3 2 CS 447 Networks and Data Communication Example: External Virtual Circuit and Internal Datagram Datagram Network Protocol layers Ext_Int/003
Packets will not be re-ordered 3 Receiver 2 Sender 1 3 1 2 UDP UDP IP IP 3 3 3 2 2 1 1 1 2 CS 447 Networks and Data Communication Example: External Datagram and Internal Datagram External Operation (Datagram) External Operation (Datagram) Internal Operation (Datagram) Internal Operation (Datagram) Datagram Network Protocol layers Ext_Int/004
3 Receiver 2 Sender 1 1 External Operation (Virtual Circuit) External Operation (Virtual Circuit) 2 3 1 Internal Operation (Virtual Circuit) Internal Operation (Virtual Circuit) 2 3 3 3 2 2 1 1 CS 447 Networks and Data Communication Example: External Virtual Circuit and Internal Virtual Circuit ISDN Telephone Network Virtual Circuit Network Protocol layers Ext_Int/005
3 Receiver 2 Sender 1 CS 447 Networks and Data Communication Example: External Datagram and Internal Virtual Circuit External Operation (Datagram) External Operation (Datagram) Internal Operation (Virtual Circuit) Internal Operation (Virtual Circuit) Virtual Circuit Network Protocol layers Ext_Int/006
CS 447 Networks and Data Communication External Operation Virtual Circuit Datagram Analog Public Telephone Virtual Circuit ISDN Telephone (Digital Telephone Network) Internal Operation Datagram UDP/IP (Internet) TCP/IP (Internet) Ext_Int/007