ECE 4110 – Internetwork Programming IP Protocol. 2 * From TCP/IP Protocol Suite, B. A. Forouzan, Prentice Hall Position of IP in TCP/IP Protocol Suite.

Slides:



Advertisements
Similar presentations
1 IP - The Internet Protocol Relates to Lab 2. A module on the Internet Protocol.
Advertisements

Computer Networks20-1 Chapter 20. Network Layer: Internet Protocol 20.1 Internetworking 20.2 IPv IPv6.
CE363 Data Communications & Networking Chapter 7 Network Layer: Internet Protocol.
20.1 Chapter 20 Network Layer: Internet Protocol Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
U N I T - 3.
20.1 Chapter 20 Network Layer: Internet Protocol Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
IPv4 - The Internet Protocol Version 4
Network Layer – IPv4 Dr. Sanjay P. Ahuja, Ph.D.
1 IP - The Internet Protocol Relates to Lab 2. A module on the Internet Protocol.
Chapter 20 Network Layer: Internet Protocol Stephen Kim 20.1.
Internet Protocol (IP)
1 K. Salah Module 5.2: Internet Protocol CO vs. CL protocols IP Features –Fragmentation –Routing IP Datagram Format IPv6.
Network Layer Packet Forwarding IS250 Spring 2010
1 TDC TDC 365 Network Interconnections Technologies Lecture #4 Notes Spring, 2009.
TCP/IP Protocol Suite 1 Chapter 8 Upon completion you will be able to: Internet Protocol Understand the format and fields of a datagram Understand the.
IP Protocol. The Internet Protocol (IP) is a network-layer (Layer 3) protocol that contains addressing information and some control information that enables.
Oct 19, 2004CS573: Network Protocols and Standards1 IP: Datagram and Addressing Network Protocols and Standards Autumn
Internet Protocol-IP. Objective l TCP/IP vs. OSI models l CO vs. CL protocols l IP Features »Fragmentation »Routing l IP Datagram Format l IPv6.
TCP/IP Protocol Suite 1 Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display. Chapter 7 Internet Protocol Version4.
20.1 Chapter 20 Network Layer: Internet Protocol Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
Microsoft Windows Server 2003 TCP/IP Protocols and Services Technical Reference Slide: 1 Lesson 5 Internet Protocol (IP) Basics.
Dr. John P. Abraham Professor UTPA
Internet Protocol --- Connectionless Datagram Delivery Linda Wu (CMPT )
Chapter 81 Internet Protocol (IP) Our greatest glory is not in never failing, but in rising up every time we fail. - Ralph Waldo Emerson.
20.1 Chapter 20 Network Layer: Internet Protocol Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
Network Layer: Internet Protocol.
The Internet Protocol Dr. Adil Yousif. 2  IP (Internet Protocol) is a Network Layer Protocol. Orientation.
TCP/IP Protocol Suite 1 Chapter 8 Upon completion you will be able to: Internet Protocol Understand the format and fields of a datagram Understand the.
Communications Services Connection Oriented Service  A connection is established  Data is sent or received over this connection  Connection may be terminated.
CS 4396 Computer Networks Lab
Chapter 20 Network Layer: Internet Protocol
1 Kyung Hee University Chapter 8 Internet Protocol (IP)
TCP/IP Protocol Suite 1 Chapter 8 Upon completion you will be able to: Internet Protocol Understand the format and fields of a datagram Understand the.
© 2009 Pearson Education Inc., Upper Saddle River, NJ. All rights reserved.1 Computer Networks and Internets, 5e By Douglas E. Comer Lecture PowerPoints.
CSC 600 Internetworking with TCP/IP Unit 5: IP, IP Routing, and ICMP (ch. 7, ch. 8, ch. 9, ch. 10) Dr. Cheer-Sun Yang Spring 2001.
Chapter 8 Internet Protocol (IP)
1 Computer Communication & Networks Lecture 19 Network Layer: IP and Address Mapping Waleed Ejaz.
Internet Protocol Version 4 VersionHeader Length Type of Service Total Length IdentificationFragment Offset Time to LiveProtocolHeader Checksum Source.
Network Layer Protocols COMP 3270 Computer Networks Computing Science Thompson Rivers University.
IP Fragmentation. Network layer transport segment from sending to receiving host on sending side encapsulates segments into datagrams on rcving side,
Chapter 20 Network Layer: Internet Protocol Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
TCP/IP Protocol Suite 1 Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display. Chapter 7 Internet Protocol Version4.
IPv4 IPv4 The Internet Protocol version 4 (IPv4) is the delivery mechanism used by the TCP/IP protocols. Datagram Fragmentation Checksum Options Topics.
20.1 Chapter 20 Network Layer: Internet Protocol Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
20.1 Chapter 20 Network Layer: Internet Protocol Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
Chapter 19 Network Layer Protocols
Behrouz A. Forouzan TCP/IP Protocol Suite, 3rd Ed.
IP - The Internet Protocol
7 Network Layer Part IV Computer Networks Tutun Juhana
Chapter 8: Internet Protocol (IP)
Chapter 7: The Infamous IP
IP - The Internet Protocol
Internet Protocol Version4
Chapter 20 Network Layer: Internet Protocol
Internet Protocol Version4
IP - The Internet Protocol
Chapter 7: The Infamous IP
Dr. John P. Abraham Professor UTPA
Chapter 20 Network Layer: Internet Protocol
Dr. John P. Abraham Professor UTRGV, EDINBURG, TX
IP - The Internet Protocol
Dr. John P. Abraham Professor UTPA
Chapter 20. Network Layer: IP
Net 323 D: Networks Protocols
IP - The Internet Protocol
Chapter 7 Internet Protocol Version 4 (IPv4)
Internet Protocol (IP)
ITIS 6167/8167: Network and Information Security
IP - The Internet Protocol
NET 323D: Networks Protocols
Presentation transcript:

ECE 4110 – Internetwork Programming IP Protocol

2 * From TCP/IP Protocol Suite, B. A. Forouzan, Prentice Hall Position of IP in TCP/IP Protocol Suite

Spring 2003 Tuna Tugcu ECE 4110 – Internetwork Programming 3 Introduction Packets in IP are called datagrams. IP service is: Connectionless Unreliable Best-effort: No error checking or tracking. IP does its best to get the datagram to the destination with no guarantees.

4 * From TCP/IP Protocol Suite, B. A. Forouzan, Prentice Hall IPv4 Datagram Format

Spring 2003 Tuna Tugcu ECE 4110 – Internetwork Programming 5 IPv4 Header Network byte order (big endian) used. Fields: Version: 4 Header length: Number of 32-bit words in the header (5 without options) Service type: Discussed later. Total length: Total length of IP datagram in bytes (max 65535). Identification: Uniquely identifies each datagram sent by a host. Used for fragmentation and reassembly. Flags: Used for fragmentation. Fragmentation offset: Used for fragmentation. In 8-byte units. Time to live: Upper limit on number of hops. Often 32 or 64.

Spring 2003 Tuna Tugcu ECE 4110 – Internetwork Programming 6 IPv4 Header (cont’d) Fields (cont’d): Protocol: Identifies which protocol gave data to IP. Checksum: Only for the header. Source address: 32-bit IP address. Destination address: 32-bit IP address. Options: Variable length list of options. Not all hosts/routers support all of them. Security and handling restrictions: For military applications. Record route: Have each router record its IP address Timestamp: Have each router record its IP address and time Loose source routing: List of IP addresses that must be traversed. Strict source routing: Similar to above, but only these addresses must be traversed.

Spring 2003 Tuna Tugcu ECE 4110 – Internetwork Programming 7 Encapsulation of IP datagram in an Ethernet Frame

Spring 2003 Tuna Tugcu ECE 4110 – Internetwork Programming 8 Multiplexing/Demultiplexing in Network Layer

Spring 2003 Tuna Tugcu ECE 4110 – Internetwork Programming 9 Service Type

Spring 2003 Tuna Tugcu ECE 4110 – Internetwork Programming 10 Service Type (cont’d) Also known as type of service. IETF recently changed the name (and the format) as differentiated services. Service Type: The precedence subfield is not used in IPv4. TOS bits: Minimize delay Maximize throughput Maximize reliability Minimize monetary cost Only one of TOS bits can be specified. Last bit is unused and must be zero.

Spring 2003 Tuna Tugcu ECE 4110 – Internetwork Programming 11 Differentiated Services: Codepoint: When the 3 rightmost bits are all zero, the 3 leftmost bits show precedence. O/w, codepoint defines 64 services. Last 2 bits are unused. Service Type (cont’d) CategoryCodepointAssigning Authority 1XXXXX0Internet 2XXXX11Local 3XXXX01Temporary or experiemental

Spring 2003 Tuna Tugcu ECE 4110 – Internetwork Programming 12 Fragmentation Each router decapsulates the IP datagram from the incoming frame and encapsulates into the outgoing frame. MTU: Maximum Transfer Unit

Spring 2003 Tuna Tugcu ECE 4110 – Internetwork Programming 13 Fragmentation (cont’d) Though maximum IP datagram size is 65535, the data link layer imposes restrictions  fragmentation A fragmented datagram may be further fragmented if it crosses a network with smaller MTU. Reassembly is done only at the destination. Why?

Spring 2003 Tuna Tugcu ECE 4110 – Internetwork Programming 14 Fragmentation (cont’d) IP fields related to fragmentation: Identification (16 bits): Provides uniqueness of each datagram. Copied into all fragments.

Spring 2003 Tuna Tugcu ECE 4110 – Internetwork Programming 15 Fragmentation (cont’d) IP fields related to fragmentation: Flags (3 bits): First bit is reserved. If do not fragment bit is set, and datagram does not fit the frame, datagram is discarded and ICMP error message is sent. If more fragments bit is set, there are other fragments following.

Spring 2003 Tuna Tugcu ECE 4110 – Internetwork Programming 16 Fragmentation (cont’d) IP fields related to fragmentation (cont’d): Fragmentation offset (13 bits): Offset of data in the original datagram. Specified in units of 8 bytes.

Spring 2003 Tuna Tugcu ECE 4110 – Internetwork Programming 17 Fragmentation Example

18 * From TCP/IP Protocol Suite, B. A. Forouzan, Prentice Hall Fragmentation Example (cont’d)

Spring 2003 Tuna Tugcu ECE 4110 – Internetwork Programming 19 Fragmentation Example 1 A packet has arrived with an M bit value of 0. Is this the first fragment, the last fragment, or a middle fragment? Do we know if the packet was fragmented?

Spring 2003 Tuna Tugcu ECE 4110 – Internetwork Programming 20 Fragmentation Example 1 (sol’n) M bit is 0  No more fragments; This is the last fragment. However, we cannot say if the original packet was fragmented or not.

Spring 2003 Tuna Tugcu ECE 4110 – Internetwork Programming 21 Fragmentation Example 2 A packet has arrived with an M bit value of 1. Is this the first fragment, the last fragment, or a middle fragment? Do we know if the packet was fragmented?

Spring 2003 Tuna Tugcu ECE 4110 – Internetwork Programming 22 Fragmentation Example 2 (sol’n) M bit is 1  At least one more fragment. This fragment can be the first one or a middle one, but not the last one. We don’t know if it is the first one or a middle one; we need more information (the value of the fragmentation offset). However, we can definitely say the original packet has been fragmented because the M bit value is 1.

Spring 2003 Tuna Tugcu ECE 4110 – Internetwork Programming 23 Fragmentation Example 3 A packet has arrived with an M bit value of 1 and a fragmentation offset value of zero. Is this the first fragment, the last fragment, or a middle fragment?

Spring 2003 Tuna Tugcu ECE 4110 – Internetwork Programming 24 Fragmentation Example 3 (sol’n) M bit is 1  Either the first fragment or a middle one. Offset value is 0  it is the first fragment.

Spring 2003 Tuna Tugcu ECE 4110 – Internetwork Programming 25 Fragmentation Example 4 A packet has arrived in which the offset value is 100. What is the number of the first byte? Do we know the number of the last byte?

Spring 2003 Tuna Tugcu ECE 4110 – Internetwork Programming 26 Fragmentation Example 4 (sol’n) Multiply the offset value by 8  First byte number is 800. We cannot determine the number of the last byte unless we know the length of the data.

Spring 2003 Tuna Tugcu ECE 4110 – Internetwork Programming 27 Fragmentation Example 5 A packet has arrived in which the offset value is 100, the value of HLEN is 5 and the value of the total length field is 100. What is the number of the first byte and the last byte?

Spring 2003 Tuna Tugcu ECE 4110 – Internetwork Programming 28 Fragmentation Example 5 (sol’n) First byte number is 100  8 = 800. The total length is 100 bytes and the header length is 20 bytes (5  4)  80 bytes of data. If the first byte number is 800, the last byte number must 879.

Spring 2003 Tuna Tugcu ECE 4110 – Internetwork Programming 29 IP Options

Spring 2003 Tuna Tugcu ECE 4110 – Internetwork Programming 30 IP Options (cont’d)

Spring 2003 Tuna Tugcu ECE 4110 – Internetwork Programming 31 IP Options (cont’d) No operation option:

Spring 2003 Tuna Tugcu ECE 4110 – Internetwork Programming 32 IP Options (cont’d) End of option option:

Spring 2003 Tuna Tugcu ECE 4110 – Internetwork Programming 33 IP Options (cont’d) Record route option:

Spring 2003 Tuna Tugcu ECE 4110 – Internetwork Programming 34 Record Route Concept

Spring 2003 Tuna Tugcu ECE 4110 – Internetwork Programming 35 IP Options (cont’d) Strict Source Route option:

Spring 2003 Tuna Tugcu ECE 4110 – Internetwork Programming 36 Strict Source Route Concept

Spring 2003 Tuna Tugcu ECE 4110 – Internetwork Programming 37 IP Options (cont’d) Loose Source Route option:

Spring 2003 Tuna Tugcu ECE 4110 – Internetwork Programming 38 IP Options (cont’d) Timestamp option:

Spring 2003 Tuna Tugcu ECE 4110 – Internetwork Programming 39 Use of Flag in Timestamp

Spring 2003 Tuna Tugcu ECE 4110 – Internetwork Programming 40 Timestamp Concept

41 * From TCP/IP Protocol Suite, B. A. Forouzan, Prentice Hall IP Package