Computer Networks Chapter 10 Connectionless Data Packet Formats









































- Slides: 41
Computer Networks Chapter 10 – Connectionless Data Packet Formats CEN 5501 C - Computer Networks - Spring 2007 - UF/CISE - Newman 1
Example Networks • • • IP IPX IPv 6 CLNP Apple. Talk DECnet CEN 5501 C - Computer Networks - Spring 2007 - UF/CISE - Newman 2
Connectionless Network Pieces • Basic connectionless service – Format for data packets – Format & use for error messages/notifications • Neighbor greeting – Nodes find routers on same link – Find if end node is on same link • Routing – Moving packets toward destination node CEN 5501 C - Computer Networks - Spring 2007 - UF/CISE - Newman 3
IP Format Version IHL Type of Service Total Length Identification 0 DF MF Offset (continued) Time to Live Protocol Header Checksum Source Address Destination Address Options (var) Padding (var) CEN 5501 C - Computer Networks - Spring 2007 - UF/CISE - Newman 4
IPX Format CEN 5501 C - Computer Networks - Spring 2007 - UF/CISE - Newman 5
IPX+ Format CEN 5501 C - Computer Networks - Spring 2007 - UF/CISE - Newman 6
Apple. Talk Format CEN 5501 C - Computer Networks - Spring 2007 - UF/CISE - Newman 7
IPv 6 Format CEN 5501 C - Computer Networks - Spring 2007 - UF/CISE - Newman 8
DECnet Format CEN 5501 C - Computer Networks - Spring 2007 - UF/CISE - Newman 9
CLNP Format CEN 5501 C - Computer Networks - Spring 2007 - UF/CISE - Newman 10
Data Packet Format Comparisons • Destination/Source Address – Variable length in CLNP, DECnet IV – Hierarchical in IPX and Apple. Talk (routers only look at net part) • Destination/Source Sockets – IPX and Apple. Talk – like UDP port • Header Length – IP IHL – mult of 4 octets => padding, max 60 – CLNP – octets, maximum of 254 – IPv 6 – handles variable length with option length CEN 5501 C - Computer Networks - Spring 2007 - UF/CISE - Newman 11
Comparisons (cont) • Packet Length – Owed to Ethernet minimum packet length – All but DECnet (assumes layer 2 correct) • Header Checksum – IP, Apple. Talk – 1’s complement ARC – CLNP – 2 octet ARCs • One like IP, but 8 bit instead of 16 • Other “Fletcher’s checksum” Sum (Vi x i) – IPX – ignored… watch this space! – IPv 6, DECnet – none (slows router down) CEN 5501 C - Computer Networks - Spring 2007 - UF/CISE - Newman 12
Comparisons (cont) • Fragmentation Allowed – Both IP and CLNP have flag, opposite logic – IPv 6 has info, but expects source to do it (!) • Packet Identifier – For association of fragments – CLNP only has this if SP=1 – IPv 6 only has in optional fragment header – Only 16 bits in IP, CLNP (too short at Gbps) – 32 bits in IPv 6 CEN 5501 C - Computer Networks - Spring 2007 - UF/CISE - Newman 13
Comparisons (cont) • Fragment Offset – Field is 0 in first fragment (or unfragged pkt) – All require fragments to be 8 -octet multiples – IPv 4, IPv 6 – 13 bit field with 8 -octet units – CLNP – 16 bit field with 1 -octet units (!) – Optional in CLNP and IPv 6 • Prefragmentation Length – Only CLNP has this (when SP=1) – Allows destination to reserve buffer space CEN 5501 C - Computer Networks - Spring 2007 - UF/CISE - Newman 14
Comparisons (cont) • More Fragments – IPv 4, IPv 6, CLNP – flag for final fragment – Useless in CLNP due to Total Length field • Lifetime – Second most useful field in the lot of ‘em – Decrements in IP (sec), CLNP (. 5 s) by time – Decrements in IPv 6 by hop – Increments by hop in IPX, DECnet, Apple. Talk CEN 5501 C - Computer Networks - Spring 2007 - UF/CISE - Newman 15
Why Have Lifetime? • Routing Inconsistencies while updating – Kill looping packets • Limiting multicast range – Allow source to select appropriate cost • Traceroute – Set incrementally and get error reports • Reuse of connection IDs, etc. – Constrain maximum persistence of packet in the NW – Better to have transport layer use large fields CEN 5501 C - Computer Networks - Spring 2007 - UF/CISE - Newman 16
Comparisons (cont) • Version – IPv 4, IPv 6, CLNP, DECnet – have it – IPX did not – used destination socket for IPX+ – Apple. Talk – used frame format to decide version!! Created problems with bridges! – Nice for adding features, but not necessary • Padding – IPv 4, CLNP, DECnet pad header – DECnet – padding in front of packet with flag Only use a pad length field if padding is present CEN 5501 C - Computer Networks - Spring 2007 - UF/CISE - Newman 17
Comparisons (cont) • Protocol Field – IPv 4, IPv 6, DECnet, Apple. Talk, IPX have it – 1 byte long = next layer protocol – DECnet Phase III did not have it • Added by clever use of first byte of NSP header – TLV encoding in IPv 6 – CLNP uses type and addresses • Last octet of address is virtually same as protocol CEN 5501 C - Computer Networks - Spring 2007 - UF/CISE - Newman 18
Comparisons (cont) • Type – CLNP has this for management protocols – 28 is data, 1 is error report, 2, 4, 6 are IS-IS, … – RTS flag in DECnet distinguishing data/error • Error Report Requested – DECnet RQR, CLNP E/R – Typically ask for this initially, then turn off – IP, IPv 6 use ICMP, assume always desired CEN 5501 C - Computer Networks - Spring 2007 - UF/CISE - Newman 19
Comparisons (cont) • Congestion Feedback – Source Quench – ICMP error message – DEC bit (C bit in CLNP) – piggybacked – In TOS field of IPv 4, IPv 6, DECnet Phase IV – Speed of notification, overhead, … • Forward vs. Backward Congestion Notif. – Fwd can piggyback (no added traffic, easy) – Fwd can alert before too congested – But pkt with bit set may be dropped CEN 5501 C - Computer Networks - Spring 2007 - UF/CISE - Newman 20
Comparisons (cont) • Type of Service (TOS) – IPv 4, IPv 6, CLNP have it – Intended to indicate special aspects of pkt – Currently still under experimentation CEN 5501 C - Computer Networks - Spring 2007 - UF/CISE - Newman 21
Type of Service IPv 4 TOS precedence D T R unused • IPv 4 TOS – 8 bits – Precedence 0 (low) – 7 (high) – D=1 low delay, =0 “normal” – T=1 high throughput, =0 “normal” – R=1 high reliability, =0 “normal” • (What is “normal” anyway? ) CEN 5501 C - Computer Networks - Spring 2007 - UF/CISE - Newman 22
CLNP Qo. S Maintenance & Priority CLNP Globally Defined Qo. S format R S/D C D/C E/D E/C • Globally defined Qo. S Option (opt. code 201) – Format=11 to indicate globally defined Qo. S – R = reserved – S/D – sequencing vs. delay (=1 keep order) – Congestion experienced – D/C – delay vs. cost (=1 low delay important) – E/D – Residual error rate vs. delay (=1 reliable) – E/C – Residual error rate vs. cost (=1 reliable) CEN 5501 C - Computer Networks - Spring 2007 - UF/CISE - Newman 23
TOS Issues • Multiple Metrics considered harmful – Delay and bandwidth pretty much the same – Error rate is just weird – Extra configuration costs, complexity – More or larger routing messages – More computation for routing • Congestion control – 1 bit to notify end node if congestion seen – 1 bit to advise router to drop packet CEN 5501 C - Computer Networks - Spring 2007 - UF/CISE - Newman 24
Service Class Categories • Directives (handled link by link) – Link encryption, hop-by-hop error recovery, priority, ordering, etc. – Easy to implement • Metrics – Delay, cost, bandwidth, reliability • Constraints – Avoid domain, use free links, etc. – Difficult to impossible, but may be necessary CEN 5501 C - Computer Networks - Spring 2007 - UF/CISE - Newman 25
CLNP Options • TLV coded #octets 1 1 0 -254 Option code length value – Security and Qo. S use 2 MSBs as • • 00 = reserved 01 = source addr specific (sender authority defined) 10 = destination addr specific (receiver auth defined) 11 = globally unique (in spec) CEN 5501 C - Computer Networks - Spring 2007 - UF/CISE - Newman 26
IP Options IP option first byte copy class number • Also TLV coded – Copy=1 copy option into every fragment – Class (2 bits) • 00 = control • 01, 11 = reserved • 10 = debugging/measurement – Number (5 bits) – specifies option CEN 5501 C - Computer Networks - Spring 2007 - UF/CISE - Newman 27
IP 1 -byte Options • Two one-byte options – Code indicates that there is no length field • End-of-option-list: option 0 – Last option in header • No option: option 1 – Padding (even internally) CEN 5501 C - Computer Networks - Spring 2007 - UF/CISE - Newman 28
IP and CLNP Options • Security • Source Routing – Loose – Strict • Route Recording – Record path taken • Internet Timestamp (IP): Class 2 number 4 – 32 -bit timestamps, maybe with addresses CEN 5501 C - Computer Networks - Spring 2007 - UF/CISE - Newman 29
Route Recording Option IP route record option type CLNP route record option type length pointer length P/C pointer Route data P/C = 0 for “partial”, 1 for “complete” • P/C – allow non-implementing routers to ignore; otherwise drop (IP always partial) • Same format as source routing • Source allocates space for route data • If route full, forward, even if “Complete” – Set pointer to 0 x. FF if can’t address CEN 5501 C - Computer Networks - Spring 2007 - UF/CISE - Newman 30
Internet Timestamp Option (IP) x 1000100 length 1 octet pointer Where to store next hop info OFL holds overflow count Flag indicates what to record OFL flag Info (variable) • • Copy flag, class 2, option 4 Flag = 0 timestamp Flag = 1 or 3 address timestamp 32 -bit Timestamp ms. since midnight UTC If no space left, then increment OFL Flag=1 then all routers record address Flag=3 then source specifies router addrs CEN 5501 C - Computer Networks - Spring 2007 - UF/CISE - Newman 31
Source Routing Option Type=131 loose; Type=137 strict IP source route option type length pointer CLNP source route opt. Type=200 length P/C pointer IPv 6 source route option SR type Segt R unused 1 1 Route data 4 Route data multiple of 16 octets • P/C flag as before (complete/partial) • Segts Remaining compacts pointer field • Unused to align addrs on 8 -octet boundary – (Type and length of next header already there) CEN 5501 C - Computer Networks - Spring 2007 - UF/CISE - Newman 32
Source Routing • Strict – Specifies exact route (must hit all in order) – Useful if source does not trust NW to route – Useful to avoid distrusted nodes • Loose – Specifies some routers to visit in order – Useful when not all addresses recognized – Useful to control some aspects of route – Only type (type 0) in IPv 6 CEN 5501 C - Computer Networks - Spring 2007 - UF/CISE - Newman 33
Source Route Addr Handling • Overwrite SR addr with outgoing link addr – IP changes its address in SR info from the incoming to the outgoing link address • Overwrite DA with next SR address – Done in IPv 4 and IPv 6 – fixed address lengths – Can’t be done in CLNP (variable lengths) – Could cause looping in CLNP • Non-implementing routers just use DA • Forced loose SR option to be mandatory in CLNP CEN 5501 C - Computer Networks - Spring 2007 - UF/CISE - Newman 34
Error Messages • CLNP – Handled as a type • IPv 4 – ICMP – Carried in IP packet as body (protocol = ICMP) • IPv 6 – modified ICMP – Next header indicates ICMP message (58) CEN 5501 C - Computer Networks - Spring 2007 - UF/CISE - Newman 35
CLNP Error Messages • • • Type = 1 instead of 28 (data packet) Predicated by E/R = 1 Reason coded in header option (0 xc 1) 2 octets: type + location Returned packet includes NW header + ? ? ? Segmentation not permitted – Truncated instead – Never done for data packets CEN 5501 C - Computer Networks - Spring 2007 - UF/CISE - Newman 36
ICMP • • • Type (1 byte) Code (1 byte) Checksum (2 bytes) Type-specific (2 bytes) Payload (variable) – Internet header – First 8 octets of datagram payload CEN 5501 C - Computer Networks - Spring 2007 - UF/CISE - Newman 37
ICMP Message Types • Echo Request/Reply – “ping” • Timestamp Request/Reply – ID and sequence # – 32 -bit timestamps – Originate / Receive / Transmit • Information Request/Reply • Address Mask Request/Reply CEN 5501 C - Computer Networks - Spring 2007 - UF/CISE - Newman 38
ICMP Message Types (cont) • Destination Unreachable – net/host/protocol/port/fragmentation/SR failed • Parameter Problem – Pointer to offending parameter • Time Exceeded – en route / in reassembly • Source Quench – Backward congestion notification • Redirect (routing) CEN 5501 C - Computer Networks - Spring 2007 - UF/CISE - Newman 39
IPv 6 Error Messages • Similar to ICMP • Use “next header” value=58 • Type (1 octet) – Type<128: error – Type>127: informational • Code (1 octet) • Checksum (2 octets) CEN 5501 C - Computer Networks - Spring 2007 - UF/CISE - Newman 40
IPv 6 Error Messages (cont) • Errors – 1=Dest unreachable/code says why – 2=Packet too big/code gives hop MTU – 3=Time exceeded/code says hops vs. reass. – 4=Parameter problem/code says type • Informational – like echo request/reply – 128=echo request – 129=echo reply CEN 5501 C - Computer Networks - Spring 2007 - UF/CISE - Newman 41