+ All Categories

Download - RIP Presentation

Transcript
  • 8/3/2019 RIP Presentation

    1/43

    Routing Information ProtocolRouting Information Protocol(RIP)(RIP)

    Sungsu KimSungsu Kim

    March 25, 2008March 25, 2008

  • 8/3/2019 RIP Presentation

    2/43

    ContentsContents

    Autonomous systemsAutonomous systems Interdomain and intradomain routingInterdomain and intradomain routing RIP Overview, historyRIP Overview, history Distance vector algorithmDistance vector algorithm Protocol Specification and Message FormatProtocol Specification and Message Format Potential problems of RIPPotential problems of RIP TimersTimers Security considerations in RIP2Security considerations in RIP2

    What is RIPng advantages and usageWhat is RIPng advantages and usage Disadvantages of RIP2 and proposedDisadvantages of RIP2 and proposed

    solutionssolutions ConclusionConclusion

  • 8/3/2019 RIP Presentation

    3/43

    Autonomous SystemsAutonomous Systems

    AnAn autonomous system (AS)autonomous system (AS) is a region of theis a region of theInternet that is administered by a single entity andInternet that is administered by a single entity andthat has a unified routing policythat has a unified routing policy

    Each autonomous system is assigned anEach autonomous system is assigned anAutonomous System Number (Autonomous System Number (ASNASN).).

    Examples of autonomous regions are:Examples of autonomous regions are: UofTUofTs campus networks campus network MCIMCIs backbone networks backbone network Regional Internet Service ProviderRegional Internet Service Provider

    Routing is done differentlyRouting is done differently within an autonomous system (within an autonomous system (intradomain routingintradomain routing) and) and between autonomous systemsbetween autonomous systems (interdomain routing(interdomain routing).).

  • 8/3/2019 RIP Presentation

    4/43

    Interdomain and IntradomainInterdomain and Intradomain

    RoutingRouting

    Routing protocols for intradomain routing are called interiorRouting protocols for intradomain routing are called interiorgateway protocols (IGP)gateway protocols (IGP)

    Routing protocols for interdomain routing are called exteriorRouting protocols for interdomain routing are called exteriorgateway protocols (EGP)gateway protocols (EGP)

  • 8/3/2019 RIP Presentation

    5/43

    Interdomain and IntradomainInterdomain and Intradomain

    RoutingRoutingIntradomain RoutingIntradomain Routing Routing within an ASRouting within an AS

    Ignores the InternetIgnores the Internetoutside the autonomousoutside the autonomous

    systemsystem Protocols for IntradomainProtocols for Intradomain

    routing are also calledrouting are also calledInterior GatewayInterior GatewayProtocolsProtocols oror IGPIGPss..

    Popular protocols arePopular protocols are

    RIP (simple, old)RIP (simple, old)

    OSPF (better)OSPF (better)

    Interdomain RoutingInterdomain Routing Routing between ASRouting between ASss

    Assumes that the InternetAssumes that the Internetconsists of a collection ofconsists of a collection of

    interconnected ASinterconnected ASss Protocols for interdomainProtocols for interdomain

    routing are also calledrouting are also calledExterior GatewayExterior GatewayProtocolsProtocols oror EGPEGPs.s.

    Routing protocol:Routing protocol:

    BGPBGP

  • 8/3/2019 RIP Presentation

    6/43

  • 8/3/2019 RIP Presentation

    7/43

    Components of a RoutingComponents of a Routing

    AlgorithmAlgorithm A procedure for sending and receivingA procedure for sending and receivingreachability information betweenreachability information betweenneighboring routersneighboring routers

    A procedure for calculating optimal routesA procedure for calculating optimal routes Routes are calculated using a shortest pathRoutes are calculated using a shortest path

    algorithm:algorithm:GoalGoal:: Given a network were each link is assigned aGiven a network were each link is assigned a

    cost. Find the path with the least cost between twocost. Find the path with the least cost between twonetworks.networks.

    A procedures for reacting to andA procedures for reacting to andadvertising topology changesadvertising topology changes

  • 8/3/2019 RIP Presentation

    8/43

    Approaches to Shortest PathApproaches to Shortest Path

    RoutingRouting There are two basic routing algorithms found onThere are two basic routing algorithms found onthe Internet.the Internet.

    1. Distance Vector Routing1. Distance Vector Routing Each node knows the distance (=cost) to its directlyEach node knows the distance (=cost) to its directly

    connected neighborsconnected neighbors A node sends periodically a list of routing updates to itsA node sends periodically a list of routing updates to its

    neighbors.neighbors. If all nodes update their distances, the routing tablesIf all nodes update their distances, the routing tables

    eventually convergeeventually converge New nodes advertise themselves to their neighborsNew nodes advertise themselves to their neighbors

    2. Link State Routing2. Link State Routing Each node knows the distance to its neighborsEach node knows the distance to its neighbors The distance information (=link state) is broadcast to allThe distance information (=link state) is broadcast to all

    nodes in the networknodes in the network Each node calculates the routing tables independentlyEach node calculates the routing tables independently

  • 8/3/2019 RIP Presentation

    9/43

    RIP updating algorithmRIP updating algorithm1. Add on 1 hop to the hop count for each advertised

    destination

    2. Repeat the following steps for each advertised destination

    1. If (destination no in the routing table)

    1. Add the advertised information to the table

    2. Else

    1. If (next-hop field is the same)

    1. Replace entry in the table with the advertisedone

    2. Else

    1. If (advertised hop count smaller than one inthe table)

    2. Replace entry in the routing table

    3. return

  • 8/3/2019 RIP Presentation

    10/43

    13.213.2 RIP (routing table)RIP (routing table)

    update periodically by updatingupdate periodically by updatingalgorithmalgorithm

    Destination Hop Count Next Hop

    ------------- ------------- ------------

    163.5.0.0 7 172.6.23.4

    197.5.13.0 5 176.3.6.17

    189.45.0.0 4 200.5.1.6115.0.0.0 6 131.4.7.19

  • 8/3/2019 RIP Presentation

    11/43

    N2

    N3

    N4

    N5

    N6

    N1

    A

    B

    C

    N1 1 -

    N2 1 -

    N3 1 -

    N2 1 -

    N4 1 -

    N5 1 -

    N3 1 -

    N6 1 -

    N2 1 -

    N4 1 -

    N5 1 -

    RIP

    N1 1 -N2 1 -

    N3 1 -

    N4 2 B

    N5 2 B

    Hop count Next hop

    Updating routing table by RIPUpdating routing table by RIP

  • 8/3/2019 RIP Presentation

    12/43

    RIPv1 Packet FormatRIPv1 Packet Format

    IP header UDP header RIP Message

    Command Version Set to 00...0

    32-bit address

    Unused (Set to 00...0)

    address family Set to 00.00

    Unused (Set to 00...0)

    metric (1-16)o

    ne

    ro

    u

    te

    en

    try

    (

    20

    b

    ytes)

    Up to 24 more routes (each 20 bytes)

    32 bits

    One RIP message can

    have up to 25 route entries

    1: request

    2: response

    2: forIP

    00: request full rou-

    ting table

    Address of destination

    Cost (measured in hops)

    1:RIPv1

  • 8/3/2019 RIP Presentation

    13/43

    OperationsOperations -- Input ProcessingInput Processing

    Handles the datagram received on RIP port (520).Handles the datagram received on RIP port (520).

    Do validation ( such as version number etc)Do validation ( such as version number etc)

    If validation fails log the errorIf validation fails log the error

    Check command field (Request or Response)Check command field (Request or Response)

    Handling Input Request MessageHandling Input Request Message

    Initialization Request Initialization Request ---- Send entire routingSend entire routingtable.table.

    Specific requestSpecific request ---- Send only entriesSend only entriesrequested.requested.

    Send response immediatelySend response immediately

    Handling Input Response MessageHandling Input Response Message-- A response can beA response can be

    received for one of several following reasons.received for one of several following reasons. Response to a specific query (direct UDP connectionResponse to a specific query (direct UDP connection

    for the router).for the router).

    Regular update (Unsolicited response).Regular update (Unsolicited response).

    Triggered update caused by a route changeTriggered update caused by a route change..

  • 8/3/2019 RIP Presentation

    14/43

    RIP RequestRIP Request

    When a router is powered onWhen a router is powered on

    Used for diagnostic purposesUsed for diagnostic purposes

  • 8/3/2019 RIP Presentation

    15/43

    OperationsOperations Output ProcessingOutput Processing

    Describes the processing used to createDescribes the processing used to create responseresponse andand

    requestrequestmessages.messages. TheThe out put processingout put processing is triggered by the following ways.is triggered by the following ways. By input processingBy input processing By regular routing update ( broadcast/multi cast atBy regular routing update ( broadcast/multi cast at

    every 30 secs)every 30 secs) By the triggered updates ( When a route changes)By the triggered updates ( When a route changes)

    Generating Request MessageGenerating Request Message Can send one RequestCan send one Request Request for entire routing table.Request for entire routing table.

    Generating Response MessagesGenerating Response Messages Response to RequestResponse to Request

    Sent to only one destinationSent to only one destination Regular updatesRegular updates

    Send the entire routing tableSend the entire routing table Triggered UpdatesTriggered Updates

    Create Response messages to neighbors.Create Response messages to neighbors.

  • 8/3/2019 RIP Presentation

    16/43

    RIP ResponseRIP Response

    Response to request, deliver routing informationResponse to request, deliver routing informationevery 30 secondsevery 30 seconds

  • 8/3/2019 RIP Presentation

    17/43

    Example of RIP massageExample of RIP massage

  • 8/3/2019 RIP Presentation

    18/43

  • 8/3/2019 RIP Presentation

    19/43

    Potential Problems and SolutionsPotential Problems and Solutions

    Potential Problems:Potential Problems:

    Count to infinity problemCount to infinity problem Routing loopsRouting loops

    SOLUTION: Triggered Updates/Split Horizon for Preventing TwoSOLUTION: Triggered Updates/Split Horizon for Preventing Two--hop Loopshop Loops

    Split Horizon:Split Horizon:"Split horizon" is a scheme for avoiding problems caused by including routes in"Split horizon" is a scheme for avoiding problems caused by including routes in

    updates sent to the router from which they were learned.updates sent to the router from which they were learned. SimpleSimple -- The information about destination routed on the link is omittedThe information about destination routed on the link is omitted With poisonous reverseWith poisonous reverse --The corresponding distance is set to infinity ifThe corresponding distance is set to infinity if

    the destination is routed on the linkthe destination is routed on the link

    Triggered updates:Triggered updates:

    Split horizon with poisoned reverse will prevent any routing loops thatSplit horizon with poisoned reverse will prevent any routing loops thatinvolve only two routers. However, it is possible to end up with patternsinvolve only two routers. However, it is possible to end up with patternsin which three routers are engaged in mutual deception.in which three routers are engaged in mutual deception.

    A timer is associated with each entry in the routing tableA timer is associated with each entry in the routing table -- much longermuch longerthan the period of transmission of informationthan the period of transmission of information

    Triggered updates request nodes to send messages as soon as theyTriggered updates request nodes to send messages as soon as theynotice a change in the routing tablenotice a change in the routing table

  • 8/3/2019 RIP Presentation

    20/43

    Count to infinity problemCount to infinity problem

    Limit hop count as 16Limit hop count as 16

    If hop count is 16, then destination isIf hop count is 16, then destination is

    unreachableunreachable

  • 8/3/2019 RIP Presentation

    21/43

    Disadvantages of RIPDisadvantages of RIP

    Slow convergenceSlow convergence meaning that a change somewhere in the

    Internet propagates very slowly through therest of the internet .

    For example, suppose there is a change innetwork 1 . since each router sends its periodic update every 30

    seconds, it means an average of 15 seconds (rangeof 0 to 30 sec)

  • 8/3/2019 RIP Presentation

    22/43

    InstabilityInstability

    Happening when a packet could goHappening when a packet could gofrom one router to another in a loopfrom one router to another in a loop

  • 8/3/2019 RIP Presentation

    23/43

    For the stability of RIPFor the stability of RIP

    Triggered updateTriggered update If there are no changes, updates are sent at 30secIf there are no changes, updates are sent at 30sec

    intervalinterval

    If there is change, router immediately sends out theIf there is change, router immediately sends out the

    its new tableits new table--update in less time than 15secupdate in less time than 15sec

    Spilt horizonsSpilt horizons Utilizes selectivity in sending of routingUtilizes selectivity in sending of routing

    messagemessage

    Router must distinguish between different

    Router must distinguish between differentinterfacesinterfaces

    If a router has received route updating infoIf a router has received route updating infofrom an interface, then this same updated infofrom an interface, then this same updated infomust not be sent back through this interfacemust not be sent back through this interface

  • 8/3/2019 RIP Presentation

    24/43

    Poison ReversePoison Reverse

    Variation of split horizonsVariation of split horizons Information received by the router is used toInformation received by the router is used to

    update the RT and then passed out to allupdate the RT and then passed out to allinterfacesinterfaces

    But, a table entry that has come through oneBut, a table entry that has come through oneinterface is set to a metric of 16 as it goes outinterface is set to a metric of 16 as it goes outthroughout the samethroughout the same

  • 8/3/2019 RIP Presentation

    25/43

    Advantages of RIP and Disadvantages of RIP1Advantages of RIP and Disadvantages of RIP1

    Advantages of RIP:Advantages of RIP:

    RIP is very useful in a small network, where it has veryRIP is very useful in a small network, where it has verylittle overhead in terms of bandwidth used andlittle overhead in terms of bandwidth used andconfiguration and management time.configuration and management time.

    Easy to implement than newer IGPsEasy to implement than newer IGPs

    Many implementations are available in the RIP field.Many implementations are available in the RIP field.

    Disadvantages of RIP1:Disadvantages of RIP1:

    minimal amount of information for router to route theminimal amount of information for router to route thepacket and also very large amount of unused space.packet and also very large amount of unused space.

    Subnet support : Supports subnet routes only within theSubnet support : Supports subnet routes only within thesubnet networksubnet network Not secure; anyone can act as a router just by sendingNot secure; anyone can act as a router just by sending

    RIPRIP--1 messages1 messages RIP1 was developed for an AS that originally includedRIP1 was developed for an AS that originally included

    less than a 100 routersless than a 100 routers

  • 8/3/2019 RIP Presentation

    26/43

    RIP2RIP2

    Latest version of RIP, RFC: 2453,Build inLatest version of RIP, RFC: 2453,Build in19901990

    Advantages:Advantages: An AS can include several hundred routers withAn AS can include several hundred routers with

    RIPRIP--2 protocol.2 protocol. Compatible upgrade of RIPv1 including subnetCompatible upgrade of RIPv1 including subnetrouting, authentication, CIDR aggregation, routerouting, authentication, CIDR aggregation, routetags and multicast transmissiontags and multicast transmission

    Subnet Support : uses more convenient partitioningSubnet Support : uses more convenient partitioningusing variableusing variable--length subnetslength subnets

    An end system can run RIP in passive mode tolisten for routing information without supplying any.

    Low requirement in memory and processing at thenode

    RIP and RIP2 are for the IPv4 network whileRIP and RIP2 are for the IPv4 network while

    thethe RIPngRIPng is designed for the IPv6 network.is designed for the IPv6 network.

  • 8/3/2019 RIP Presentation

    27/43

    Practical use in Yahoo Chat IMPractical use in Yahoo Chat IM

    Routing information protocol: givesRouting information protocol: givescommand, version ip domain andcommand, version ip domain andaddress information.address information.

  • 8/3/2019 RIP Presentation

    28/43

    Distance Vector ProtocolDistance Vector Protocol

    Compatible upgrade of RIPv1 including subnet routing,Compatible upgrade of RIPv1 including subnet routing,authentication, CIDR aggregation, route tags and multicastauthentication, CIDR aggregation, route tags and multicasttransmissiontransmission

    Subnet support: RIPv1 supports subnet routes only within theSubnet support: RIPv1 supports subnet routes only within thesubnet network while RIPv2 includes subnet mask in thesubnet network while RIPv2 includes subnet mask in themessages. This allows for subnet knowledge outside subnet. Moremessages. This allows for subnet knowledge outside subnet. Moreconvenient partitioning using variable length subnet.convenient partitioning using variable length subnet.

    RIPv2 is a distance vector based routing protocol. RIP2 supportsRIPv2 is a distance vector based routing protocol. RIP2 supportsvariablevariable--length subnet masks (VLSM).length subnet masks (VLSM).

    Distance vector routing protocols: DistanceDistance vector routing protocols: Distance--based vector routingbased vector routingprotocols base the optimal route on the number of hops (i.e.,protocols base the optimal route on the number of hops (i.e.,devices) a packet must pass through to reach a destination.devices) a packet must pass through to reach a destination.

    Neighboring nodes send information in regular time intervalsNeighboring nodes send information in regular time intervals

    Install routes directly in tables, lowest cost winsInstall routes directly in tables, lowest cost wins The information sent (the distance vectors) are all routesThe information sent (the distance vectors) are all routes

    from the tablefrom the table The shortest path tree is contained in the routing tableThe shortest path tree is contained in the routing table Calculations are based on the BellmanCalculations are based on the Bellman--Ford algorithmFord algorithm

  • 8/3/2019 RIP Presentation

    29/43

    RIP 2 Packet FormatRIP 2 Packet Format

    CommandCommand ---- The command field is usedThe command field is used

    to specify the purpose of the datagram.to specify the purpose of the datagram.

    VersionVersion ---- The RIP version number. TheThe RIP version number. Thecurrent version is 2.current version is 2.

    Address family identifierAddress family identifier ---- IndicatesIndicateswhat type of address is specified in thiswhat type of address is specified in thisparticular entry.particular entry.

    Route tagRoute tag ---- Attribute assigned to aAttribute assigned to aroute which must be preserved androute which must be preserved andreadvertised with a route. The route tagreadvertised with a route. The route tagprovides a method of separating internalprovides a method of separating internalRIP routes from external RIP routes,RIP routes from external RIP routes,which may have been imported from anwhich may have been imported from anEGP or another IGP.EGP or another IGP.

    IP addressIP address ---- The destination IP address.The destination IP address.

    Subnet maskSubnet mask ---- Value applied to the IPValue applied to the IPaddress to yield the nonaddress to yield the non--host portion ofhost portion ofthe address. If zero, then no subnetthe address. If zero, then no subnetmask has been included for this entry.mask has been included for this entry.

    Next hopNext hop ---- Immediate next hop IPImmediate next hop IPaddress to which packets to theaddress to which packets to thedestination specified by this route entrydestination specified by this route entryshould be forwarded.should be forwarded.

    MetricMetric ---- Represents the total cost ofRepresents the total cost ofgetting a datagram from the host to thatgetting a datagram from the host to thatdestination.destination.

    Protocol Structure - RIP & and RIP2: Routing Information Protocol

    http://www.colasoft.com/resources/protocol.php?id=RIP2

    Max pkt size 512

  • 8/3/2019 RIP Presentation

    30/43

    RIPv2 Packet Format (With/Without Authentication Header)RIPv2 Packet Format (With/Without Authentication Header)

    RIPv2 packet with no AuthenticationRIPv2 packet with no Authentication RIPv2 packet with AuthenticationRIPv2 packet with Authenticationheaderheader

    Authentication type (2) is passwordAuthentication type (2) is password

  • 8/3/2019 RIP Presentation

    31/43

    Example and Routing Table StructureExample and Routing Table Structure

    IP Routing table for Router R1IP Routing table for Router R1

    Included in RIP routing table

    -Address of (net/subnet/host) destination

    -Metric associated with destination

    -Address of next hop router

    -Recently updated flag

    -Several timers

  • 8/3/2019 RIP Presentation

    32/43

    RIP2 ExtensionsRIP2 Extensions

    authenticationauthentication

    routing per subnetrouting per subnetsupport of multiple metricssupport of multiple metrics

    routing domainsrouting domains

    multicastingmulticasting

  • 8/3/2019 RIP Presentation

    33/43

    Addressing ConsiderationAddressing Consideration IP address field in RIP2IP address field in RIP2

    messagemessage (Request/ Response )(Request/ Response )format can be networks,format can be networks,hosts, or a special codehosts, or a special codeused to indicate a defaultused to indicate a defaultaddressaddress -- exampleexample

    128.6128.6 Network AddressNetwork Address

    128.6.4.1128.6.4.1 HostHostaddressaddress

    0.0.0.00.0.0.0 Default addressDefault address

    Subnet addresses must notSubnet addresses must notbe sent outside the networkbe sent outside the networkof which the subnet is aof which the subnet is apart.part.

    0.0.0.0 is used to describe a0.0.0.0 is used to describe adefault route.default route.

  • 8/3/2019 RIP Presentation

    34/43

    InitializationInitialization

    InitializationInitialization This is done when host first comes online.This is done when host first comes online.

    Determine who the neighbors are.Determine who the neighbors are.

    Set command field to 1Set command field to 1

    Send request for entire routing table fromSend request for entire routing table fromneighborsneighbors..

  • 8/3/2019 RIP Presentation

    35/43

    Interaction between RIPV1 andInteraction between RIPV1 andRIPV2RIPV2

    Limiting NetworksLimiting Networks

    Disable AutoDisable Auto--SummarizationSummarization

    Single SubnetmaskSingle Subnetmask

  • 8/3/2019 RIP Presentation

    36/43

    Security ConsiderationsSecurity Considerations

    AuthenticationAuthentication

    1. Plaintext Authentication1. Plaintext Authentication

    AlgorithmAlgorithm2.Cryptographic2.Cryptographic

    AuthenticationAuthentication

    1.Keyed Message Digest 51

    .Keyed Message Digest 52.HMAC2.HMAC--SHA1SHA1

    Peer SecurityPeer Security

    Router FiltersRouter Filters

  • 8/3/2019 RIP Presentation

    37/43

    RIPngRIPng

    IPv6 compatible version of RIPIPv6 compatible version of RIP

    complete new protocolcomplete new protocol

    UsesUses distance vector algorithmdistance vector algorithm

    Uses standard port nuber 521 and runs overUses standard port nuber 521 and runs overUDPUDP

    Installs the best route in the RIPng routingInstalls the best route in the RIPng routingtabletable

  • 8/3/2019 RIP Presentation

    38/43

    RIPng v/s RIPRIPng v/s RIP--22

    RIPngRIPng RIPRIP--22

    Learns IPv6 routeLearns IPv6 routeinformationinformation

    Learns IPv4 routeLearns IPv4 routeinformationinformation

    Uses port number 521.Uses port number 521. Uses port number 520Uses port number 520

    Requires noRequires noauthentication for RIPngauthentication for RIPng

    protocol packets.protocol packets.

    Requires authenticationRequires authenticationfor RIP protocol packetsfor RIP protocol packets

    No support for multipleNo support for multipleinstances ofRIPng.instances ofRIPng.

    Support for multipleSupport for multipleinstances ofRIPinstances ofRIP--22

  • 8/3/2019 RIP Presentation

    39/43

    RIP2RIP2 -- DisadvantagesDisadvantages

    RIP-2 supports generic notion ofauthentication, but only password isdefined so far. Still not very secure.

    RIP2 packet size increases as the number of

    networks increases hence it is not suitablefor large networks.

    RIP2 generates more protocol traffic thanOSPF, because it propagates routinginformation by periodically transmitting the

    entire routing table to neighbor routers RIP2 may be slow to adjust for link failures.

  • 8/3/2019 RIP Presentation

    40/43

  • 8/3/2019 RIP Presentation

    41/43

    ConclusionConclusion

    RIP2 offers many substantial featuresused to increase the efficiency ofRIP1

    RIP2 have one negative feature ofRIP1 - the path between two subnetsis based on the fewest number ofrouter hops

    RIPng is a complete new protocoldesigned for Ipv6. It uses the sameoperations as that of RIP1 and RIP2

  • 8/3/2019 RIP Presentation

    42/43

    ReferencesReferences

    http://www.networkdictionary.com/protocols/rip.php?PHPSEShttp://www.networkdictionary.com/protocols/rip.php?PHPSESSID=c2a79111d168fafSID=c2a79111d168faf

    http://www.tcpipguide.com/free/t_RIPOverviewHistoryStandahttp://www.tcpipguide.com/free/t_RIPOverviewHistoryStandardsandVersions.htmrdsandVersions.htm

    http://www.cisco.com/univercd/cc/td/doc/product/software/ihttp://www.cisco.com/univercd/cc/td/doc/product/software/ios121/121cgcr/ip_c/ipcprt2/1cdrip.htmos121/121cgcr/ip_c/ipcprt2/1cdrip.htm

    http://www.duke.edu/~yy7/ee156/rip.htmhttp://www.duke.edu/~yy7/ee156/rip.htm

  • 8/3/2019 RIP Presentation

    43/43

    Questions???Questions???


Top Related