Transcript momina-RIP

RIP – Routing
Information Protocol
Syeda Momina Tabish
MIT - 7
Outline



Introduction
History
Version




RIP v1
RIP v2
RIPng
Functioning
RIP – Introduction




One of Interior gateway protocol (IGP) routing
protocols on internal networks.
Helps routers dynamically adapt to changes of
network connections by communicating information
about which networks each router can reach and
how far away those networks are.
Its made obsolete by OSPF and IS-IS.
Also sometimes called Rest in Pieces.
RIP – Introduction






A simple intradomain protocol
Straightforward implementation of Distance Vector
Routing
Each router advertises its distance vector every 30
seconds (or whenever its routing table changes) to
all of its neighbors
RIP always uses 1 as link metric
Maximum hop count is 15, with “16” equal to “”
Routes are timeout (set to 16) after 3 minutes if they
are not updated
RIP – History

Late 1960s :

Mid-1970s:


1982
1988

1993

1998
Distance Vector protocols were used in the
ARPANET
XNS (Xerox Network system) routing
protocol is the precursor of RIP in IP (and
Novell’s IPX RIP and Apple’s routing
protocol)
Release of routed for BSD Unix
RIPv1 (RFC 1058)
- classful routing
RIPv2 (RFC 1388)
- adds subnet masks with each route entry
- allows classless routing
Current version of RIPv2 (RFC 2453)
RIP – Message Format

Two Message Types



Request (sent by devices after initialization to
request a unicast copy of a neighbor’s routing
table
Response (sent by RIP speaking devices by
broadcasting every 30 seconds to IP
255.255.255.255)
Send via UDP/520 up to 25 routes per packet
that include IP network, metric, but no subnet
mask
RIP – Normal Operation

For every active RIP interface




Announce known RIP routes out RIP enabled interfaces
every 30s
Process received RIP annoucements by placing routes in
routing table if better than existing route and add 1 to the
hop count
Do not announce things learned on an interface out the
same interface (split horizon)
Only announce if reachable with hop count <- 15
RIP Timers
Router rip
timers basic update invalid hold down flush
 Update 30s (when to broadcast response)
 Invalid 180s (when haven’t heard annoucements for
180s, do not use)
 Holddown 180s (when neighbor increases metric for
a network, do not accept immediately
 Flush 240s (after invalid timer expires, mark as
unreachable metric 16 until time to flush)
RIP v1





RIPv1, defined in RFC 1058
Uses classful routing
Routing updates do not carry subnet
information
Lacking support for variable length subnet
masks
No Support for Router Authentication
RIPv1 Packet Format
IP header UDP header
RIP Message
1: RIPv1
2: for IP
0…0: request full routing table
Command Version
Set to 00...0
address family
Set to 00.00
32-bit address
Unused (Set to 00...0)
Address of destination
Cost (measured in hops)
One RIP message can
have up to 25 route entries
Unused (Set to 00...0)
metric (1-16)
Up to 24 more routes (each 20 bytes)
32 bits
one route entry
(20 bytes)
1: request
2: response
RIP v2





Developed in 1994
Included the ability to carry subnet information, thus
supporting Classless Inter-Domain Routing (CIDR)
15 hop count limit remained.
Rudimentary plain text authentication was added to
secure routing updates; later, MD5 authentication
was defined in RFC 2082.
RIPv2 is specified in RFC 2453
RIPv2 Packet Format
IP header UDP header
RIP Message
2: RIPv2
2: for IP
0…0: request full routing table
Command Version
Set to 00...0
address family
Set to 00.00
32-bit address
Unused (Set to 00...0)
Address of destination
Cost (measured in hops)
One RIP message can
have up to 25 route entries
Unused (Set to 00...0)
metric (1-16)
Up to 24 more routes (each 20 bytes)
32 bits
one route entry
(20 bytes)
1: request
2: response
RIP Security


Issue: Sending bogus routing updates to a router
RIPv1: No protection
RIPv2: Simple authentication scheme
2: plaintext
password
RIPv2 Message
IP header UDP header
Command Version
Set to 00.00
0xffff
Authentication Type
Password (Bytes 0 - 3)
Password (Bytes 4 - 7)
Password (Bytes 8- 11)
Password (Bytes 12 - 15)
Up to 24 more routes (each 20 bytes)
32 bits
Authetication

RIP Problems

RIP takes a long time to stabilize


Even for a small network, it takes several minutes
until the routing tables have settled after a change
RIP has all the problems of distance vector
algorithms, e.g., count-to-Infinity


RIP uses split horizon to avoid count-to-infinity
The maximum path in RIP is 15 hops
Thanks