Protocol Architecture 1 Protocols 2 ConnectionOriented and Connectionless




































































- Slides: 68
Protocol Architecture 1. Protocols 2. Connection-Oriented and Connectionless Protocols 3. OSI Standard Architecture 4. TCP/IP Protocol Architecture 5. Vertical Communication Between Layer Processes 1
1. Protocols
Key Elements of a Protocol • Syntax – Data formats – Signal levels • Semantics – Control information – Error handling • Timing – Speed matching – Sequencing 3
Standards are rules of operation that allow two hardware or software processes to work together Even if they are from different vendors 4
Figure 2 -1: Standards Govern the Exchange of Messages • Standards Govern the Exchange of Messages – Messages must be governed by strict rules – Because computers are not intelligent Message 5
Figure 2 -1: Standards Govern the Exchange of Messages (Continued) • Standards Govern Syntax – Syntax: the organization of the message – Human example: “Susan thanked Tom” – This sentence has a subject-verb-object syntax • Standards Govern Semantics – Semantics: The meaning of the message – Human example: “Susan thanked Tom” – Humans understand this message easily 6
Figure 2 -1: Standards Govern the Exchange of Messages, Continued • General Message Syntax (Organization) – General Message Organization (Figure 2 -4) – Primary parts of messages • Data Field (content to be delivered) • Header (everything before the data field) • Trailer (everything after the data field) – The header and trailer act like a delivery envelope for the data field. Trailer Data Field Header 7
Figure 2 -1: Standards Govern the Exchange of Messages, Continued • General Message Syntax (Organization) – Header and trailer are further divided into fields Trailer Message with all three parts Data Field Header Other Header Field Destination Address Field is Used by Switches and Routers Like the Address on an Envelope 8
Figure 2 -4: General Message Organization, Continued Data Field Message without a trailer Header Other Header Field Destination Address Field Usually only data link layer messages have trailers 9
Figure 2 -4: General Message Organization, Continued Header Message with only a header e. g. TCP supervisory messages are pure headers (there is no data field content to deliver) Other Header Field Destination Address Field 10
2. Connection-Oriented and Connectionless Protocols
Figure 2 -6: Connection-Oriented and Connectionless Protocols Connection-Oriented Protocol A Open Connection B Connectionless Protocol A Message (No Sequence Number) B Message 1 (Seq. Num = A 1) Message 3 (Seq. Num B 1) Message 2 (Seq. Num = A 2) Close Connection-oriented protocols Formal openings and closings Also have sequence numbers so that the receiver can put messages in order And so the receiver can send Acknowledgments for specific messages 12
Figure 2 -6: Connection-Oriented and Connectionless Protocols, Continued Client PC Browser Webserver Application HTTP Request HTTP is connectionless No Openings No Closings No Sequence Numbers No Acknowledgments 13
Figure 2 -6: Connection-Oriented and Connectionless Protocols, Continued Client PC TCP Process In TCP Webserver TCP Process Connection-Opening Messages Time Messages During the Connection-Closing Messages 14
Figure 2 -7: Advantages and Disadvantages or Connection-Oriented Protocols • Advantages – Thanks to sequence numbers, the parties can tell if a message is lost. – Error messages, such as ACKs can refer to specific messages. – Long messages can be fragmented into many smaller messages that can fit inside packets. • Fragmentation followed by reassembly on the destination host is an important concept in networking. 15
Figure 2 -7: Advantages and Disadvantages or Connection-Oriented Protocols, Cont. • Disadvantages – The presence of many supervisory messages consumes existing bandwidth – The processing of connection information places a heavy processing load on computers connected to the network 16
3. OSI Standard Architecture
Standards Architecture • A Standards Architecture is a Broad Plan for Creating Standards – Break the problem of effective communication into smaller pieces for ease of development – Develop standards for the individual pieces – Just as a building architect creating a general plan for a house before designing the individual rooms in detail 18
OSI • Open Systems Interconnection • Developed by the International Organization for Standardization (ISO) • Seven layers • A theoretical system delivered too late! • TCP/IP is the de facto standard 19
OSI - The Model • A layer model • Each layer performs a subset of the required communication functions • Each layer relies on the next lower layer to perform more primitive functions • Each layer provides services to the next higher layer • Changes in one layer should not require changes in other layers 20
Why Layer? • Breaking up large tasks into smaller tasks and assigning tasks to different individuals is common in all fields • Specialization in standards design (EEs for physical layer, application specialists for application layer, etc. ) • Simplification in standards design for individual standards • If you change a standard at one layer, you do not have to change standards at other layers 21
OSI Layers 22
The OSI Environment 23
Protocol Data Units (PDU) • At each layer, protocols are used to communicate • Control information is added to user data at each layer (PDU = Control + Data) • Transport layer may fragment user data • Each fragment has a transport header added – Destination SAP – Sequence number – Error detection code • This gives a transport protocol data unit 24
Protocol Data Units 25
OSI as Framework for Standardization 26
Figure 2. 9 Layer Specific Standards 27
4. TCP/IP Protocol Architecture
TCP/IP Protocol Architecture • Developed by the US Defense Advanced Research Project Agency (DARPA) for its packet switched network (ARPANET) • Used by the global Internet • No official model but a working one. Application layer Transport layer (host-to-host) Internet layer Data Link layer Physical layer (Network Access) 29
Hybrid TCP/IP-OSI Architecture General Purpose Layer Specific Layer Purpose Application-application communication Application (5) Application-application interworking Transmission across an internet Transport (4) Host-host communication Internet (3) Packet delivery across an internet Data Link (2) Frame delivery across a network Physical (1) Device-device connection Transmission across a single network (LAN or WAN) 30
Figure 2 -8: Hybrid TCP/IP-OSI Architecture, Continued • Physical and Data Link Layer Standards – Govern Communication Through a Single Network – LAN or WAN 31
Physical Layer • Physical interface between data transmission device (e. g. computer) and transmission medium or network • Characteristics of transmission medium • Signal levels • Data rates • etc. 32
Figure 2 -9: Physical and Data Link Layer Standards in a Single Network • Physical Layer – Physical layer standards govern transmission between adjacent devices connected by a transmission medium Physical Link A-X 1 Host A Switch X 1 Physical Link X 1 -X 2 Switch X 2 33
Figure 2 -9: Physical and Data Link Layer Standards in a Single Network, Continued • Data Link Layer – Data link layer standards govern the transmission of frames across a single network—typically by sending them through several switches along the data link Data Link A-B Host A Host B Switch X 1 Switch X 2 34
Figure 2 -9: Physical and Data Link Layer Standards in a Single Network, Continued • Data Link Layer – Data link layer standards also govern • Frame organization • Switch operation 35
Figure 2 -9: Physical and Data Link Layer Standards in a Single Network, Continued Host A Switch 3 Physical Links 1 Data Link 2 Switches Data Link A-R 1 Switch Physical Link A-X 1 Switch X 1 Physical Link X 1 -X 2 Mobile Client Station Switch X 2 Physical Link X 2 -R 1 Server Station Router R 1 36
Figure 2 -10: Internet and Data Link Layers in an Internet • Internet and Transport Layers – An internet is a group of networks connected by routers so that any application on any host on any network can communicate with any application on any other host on any other network – Internet and transport layer standards govern communication across an internet composed of two or more single networks 37
Figure 2 -10: Internet and Data Link Layers in an Internet, Continued • Internet Layer – Internet layer standards govern the transmission of packets across an internet—typically by sending them through several routers along the route – Messages at the internet layer are called packets – Internet layer standards also govern packet organization and router operation Router 1 Router 2 38
Figure 2 -10: Internet and Data Link Layers in an Internet, Continued Host A Data Link A-R 1 Network X 3 Data Links: One per Network 1 Route per Internet Network Z Route A-B Network Y Data Link R 1 -R 2 Host B Data Link R 3 -B 39
Figure 2 -10: Internet and Data Link Layers in an Internet, Continued Frame X Packet Host A Data Link A-R 1 Switch In Network X: Two Destination Addresses: Switch Server Packet: Host B (Destination Host) Station Frame: Router R 1 Switch X 1 Mobile Client Station Switch X 2 Route A-B Router R 1 Network X 40
Figure 2 -10: Internet and Data Link Layers in an Internet, Continued To Network X Route A-B Router R 1 Data Link In Network Y: R 1 -R 2 Two Destination Addresses: Packet: Host B (Destination Host) Frame: Router R 2 To Network Z Router R 2 Frame Y Packet Network Y 41
Figure 2 -10: Internet and Data Link Layers in an Internet, Continued Data Link R 2 -B Frame Z Packet Switch Z 1 Host B Router R 2 In Network Z: Two Destination. Switch Addresses: Packet: Host B (Destination Host) Z 2 Frame: Host B Mobile Client Stations Switch X 2 Router Network Z 42
Frames and Packets • In an internet with hosts separated by N networks, there will be: – – – 2 hosts One packet (going all the way between hosts) One route (between the two hosts) N frames (one in each network) N-1 routers (change frames between each pair of networks) – There usually are many switches within single networks – There usually are many physical links within networks 43
Figure 2 -11: Internet and Transport Layer Standards • Transport Layer – Transport layer standards govern aspects of end-toend communication between two end hosts that are not handled by the internet layer – These standards allow hosts to work together even if the two computers are from different vendors and have different internal designs 44
Figure 2 -11: Internet and Transport Layer Standards, Continued Client PC Transport Layer end-to-end (host-to-host) TCP is connection-oriented, reliable UDP is connectionless and unreliable Server Internet Layer (usually IP) hop-by-hop (host-router or router-router) connectionless, unreliable Router 1 Router 2 Router 3 45
Figure 2 -12: Application Layer Standards • Application Layer – The application layer governs how two applications work with each other, even if they are from different vendors Browser Client PC Webserver Application Webserver 46
Figure 2 -12: Application Layer Standards • There are more application layer standards than any other type of standard because there are many applications – HTTP – E-Mail – Database – Instant Messaging – FTP – Etc. 47
Some Protocols in TCP/IP Suite 48
5. Vertical Communication Between Layer Processes
Figure 2 -18: Layered Communication on the Source Host The process begins when a browser creates an HTTP request message Application Process HTTP Message Passes Message Down to Transport Process HTTP TCP Message Hdr Encapsulation of HTTP Message in Data Field of TCP Segment 50
Figure 2 -18: Layered Communication on the Source Host, Continued • When a layer process (N) creates a message, it passes it down to the nextlower-layer process (N-1) immediately • The receiving process (N-1) will encapsulate the Layer N message, that is, place it in the data field of its own (N-1) message 51
Figure 2 -18: Layered Communication on the Source Host, Continued Transport Process Internet Process HTTP TCP Message Hdr HTTP TCP IP Message Hdr Encapsulation of TCP Segment in Data Field of IP Packet 52
Figure 2 -18: Layered Communication on the Source Host, Continued Internet Process HTTP TCP IP Message Hdr Data Link Process Eth HTTP TCP IP Eth Trlr Message Hdr Hdr Encapsulation of IP Packet in Data Field of Ethernet Frame 53
Figure 2 -18: Layered Communication on the Source Host, Continued Data Link Process Eth HTTP TCP IP Eth Trlr Message Hdr Hdr Physical Process Physical Layer converts the bits of the frame into signals. 54
Figure 2 -18: Layered Communication on the Source Host, Continued The following is the final frame for a an HTTP message on an Ethernet LAN Eth HTTP TCP IP Eth Trlr Message Hdr Hdr L 2 L 5 L 4 L 3 L 2 Notice the Pattern: From Right to Left: L 2, L 3, L 4, L 5, maybe L 2 This makes it easier to remember the order of headers and messages Don’t forget the possible trailing L 2 trailer 55
Figure 2 -19: Decapsulation on the Destination Host Eth HTTP TCP IP Eth Trlr Message Hdr Hdr Data Link Process Physical Process 56
Figure 2 -19: Decapsulation on the Destination Host, Continued HTTP TCP IP Message Hdr Internet Process Eth HTTP TCP IP Eth Trlr Message Hdr Hdr Data Link Process Decapsulation of IP Packet from Data Field of Ethernet Frame 57
Figure 2 -19: Decapsulation on the Destination Host, Continued HTTP TCP Message Hdr HTTP TCP IP Message Hdr Transport Process Internet Process Decapsulation of TCP Segment from Data Field of IP Packet 58
Figure 2 -19: Decapsulation on the Destination Host, Continued HTTP Message Application Process HTTP TCP Message Hdr Transport Process Decapsulation of HTTP Message from Data Field of TCP Segment 59
PDUs in TCP/IP 60
Figure 2 -20: Layered End-to-End Communication Source and Destination Hosts Have 5 Layers App Trans Int DL Phy Source Host Switches Have Two Layers --Each Switch Port Has One Layer (1) Switch 1 Switch 2 Routers Have Three Layers --Each Router Port Has Two Layers (1&2) Router 1 Switch 3 Router Destination 2 Host 61
Figure 2 -21: Combining Horizontal and Vertical Communication Hypertext Transfer Protocol App Transmission Control Protocol Trans Internet Protocol DL Phy Source Host Switch 1 Switch 2 Router 1 Switch 3 Router Destination Host 2 62
Telnet Data TCP Header + Telnet Data 63
IP Header + TCP Header + Telnet Data Ethernet Frame Header + IP Header + TCP Header + Telnet Data 64
Example Header Information • Destination port • Sequence number • Checksum 65
Figure 2 -23: OSI and TCP/IP Standards Agency or Agencies OSI TCP/IP ISO (International Organization for Standardization) IETF (Internet Engineering Task Force) ITU-T (International Telecommunications Union— Telecommunications Standards Sector) 66
Figure 2 -23: OSI and TCP/IP, Continued OSI TCP/IP Dominance Nearly 100% dominant at physical and data link layers 70%-80% dominant at the internet and transport layers. Documents are Called Various Mostly RFCs (requests for comments) 67
Figure 2 -26: Characteristics of Protocols Discussed in the Chapter Layer Protocol Connection. Oriented /Connectionless Reliable/ Unreliable 5 (App) HTTP Connectionless Unreliable 4 (Transport) TCP Connectionoriented Reliable 4 (Transport) UDP Connectionless Unreliable 3 (Internet) IP Connectionless Unreliable 2 (Data Link) Ethernet Connectionless Unreliable Note: Only TCP is connection-oriented and reliable 68